Skip to content

Commit 0e1c3ad

Browse files
committed
修复了接口问题
1 parent 31e3727 commit 0e1c3ad

File tree

7 files changed

+16
-14
lines changed

7 files changed

+16
-14
lines changed

src/components/theme-cover/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ export default memo(function HYThemeCover(props) {
2929
<div className="cover-bottom text-nowrap">
3030
{info.name}
3131
</div>
32-
<div className="cover-source">
32+
{/* <div className="cover-source">
3333
by {info.copywriter || info.creator.nickname}
34-
</div>
34+
</div> */}
3535
</ThemeCoverWrapper>
3636
)
3737
})

src/pages/discover/c-pages/album/store/actionCreators.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ export const getTopAlbumsAction = (page) => {
3333
getTopAlbums(30, (page-1) * 30).then(res => {
3434
dispatch(changeTopAlbumAction(res));
3535
dispatch(changeTopTotalAction(res.total));
36+
37+
console.log(res)
3638
})
3739
}
3840
}

src/pages/discover/c-pages/recommend/c-cpns/ranking-list/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ export default memo(function HYRankingList() {
2222

2323
// hooks
2424
useEffect(() => {
25-
dispatch(getTopData(0));
26-
dispatch(getTopData(2));
27-
dispatch(getTopData(3));
25+
dispatch(getTopData(19723756));
26+
dispatch(getTopData(3779629));
27+
dispatch(getTopData(2884035));
2828
}, [dispatch])
2929

3030
return (

src/pages/discover/c-pages/recommend/store/actionCreators.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,13 @@ export const getTopData = (idx) => {
7272
return dispatch => {
7373
getTopList(idx).then(res => {
7474
switch (idx) {
75-
case 0:
75+
case 19723756:
7676
dispatch(changeNewListAction(res));
7777
break;
78-
case 2:
78+
case 3779629:
7979
dispatch(changeOriginListAction(res));
8080
break;
81-
case 3:
81+
case 2884035:
8282
dispatch(changeUpListAction(res));
8383
break;
8484
default:

src/services/album.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export function getHotAlbums() {
88

99
export function getTopAlbums(limit, offset) {
1010
return request({
11-
url: "/top/album",
11+
url: "/album/new",
1212
params: {
1313
limit,
1414
offset

src/services/axios.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default function request(option) {
44
return new Promise((resolve, reject) => {
55
// 1.创建axios的实例
66
const instance = originAxios.create({
7-
baseURL: 'http://123.207.32.32:9001/',
7+
baseURL: 'http://123.207.32.32:9002/',
88
timeout: 10000
99
});
1010

src/services/recommend.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,19 @@ export function getHotRecommend() {
1414

1515
export function getNewAlbum(limit, offset) {
1616
return request({
17-
url: "/top/album",
17+
url: "/album/new",
1818
params: {
1919
limit,
2020
offset
2121
}
2222
})
2323
}
2424

25-
export function getTopList(idx) {
25+
export function getTopList(id) {
2626
return request({
27-
url: "/top/list",
27+
url: "/playlist/detail",
2828
params: {
29-
idx
29+
id
3030
}
3131
})
3232
}

0 commit comments

Comments
 (0)