xuhuajiao
2 years ago
10 changed files with 115 additions and 44 deletions
-
13.env.development
-
36src/api/bookshelf.js
-
BINsrc/assets/images/default-img.png
-
12src/assets/styles/index.scss
-
3src/main.js
-
12src/utils/request.js
-
42src/views/data.json
-
25src/views/index.vue
-
10src/views/module/bookListItem.vue
-
6vue.config.js
@ -0,0 +1,36 @@ |
|||||
|
import request from '@/utils/request' |
||||
|
// import qs from 'qs'
|
||||
|
|
||||
|
// 数字资源
|
||||
|
export function initNumberResoures(params) { |
||||
|
return request({ |
||||
|
url: '/dxhtsg/initNumberResoures', |
||||
|
method: 'get', |
||||
|
params: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 新书推荐
|
||||
|
export function FetchNewBookRecommend(params) { |
||||
|
return request({ |
||||
|
url: '/dxhtsg/newBookRecommend', |
||||
|
method: 'get', |
||||
|
params: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 通过isbn获取图书封面
|
||||
|
export function FetchCoverByISBN(params) { |
||||
|
return request({ |
||||
|
url: '/dxhtsg/getCoverByISBN', |
||||
|
method: 'get', |
||||
|
params: params, |
||||
|
responseType: 'blob' |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
export default { |
||||
|
FetchNewBookRecommend, |
||||
|
FetchCoverByISBN, |
||||
|
initNumberResoures |
||||
|
} |
After Width: 440 | Height: 526 | Size: 51 KiB |
@ -1,53 +1,53 @@ |
|||||
{ |
{ |
||||
"bookList":[ |
"bookList":[ |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定1", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定1", |
||||
"ranking": 1, |
"ranking": 1, |
||||
"num": 2000 |
"num": 2000 |
||||
}, |
}, |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定2", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定2", |
||||
"ranking": 2, |
"ranking": 2, |
||||
"num": 1200 |
"num": 1200 |
||||
}, |
}, |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定3", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定3", |
||||
"ranking": 3, |
"ranking": 3, |
||||
"num": 1100 |
"num": 1100 |
||||
} |
} |
||||
], |
], |
||||
"newList":[ |
"newList":[ |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定1", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定1", |
||||
"ranking": 1, |
"ranking": 1, |
||||
"num": 2000 |
"num": 2000 |
||||
}, |
}, |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定2", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定2", |
||||
"ranking": 2, |
"ranking": 2, |
||||
"num": 1200 |
"num": 1200 |
||||
}, |
}, |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定3", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定3", |
||||
"ranking": 3, |
"ranking": 3, |
||||
"num": 1100 |
"num": 1100 |
||||
}, |
}, |
||||
{ |
{ |
||||
"img":"https://qiniu.aiyxlib.com/bg.png", |
|
||||
"title": "大个子狗与小个子猫", |
|
||||
"author": "高小定4", |
|
||||
|
"cover":"https://qiniu.aiyxlib.com/bg.png", |
||||
|
"nbName": "大个子狗与小个子猫", |
||||
|
"nbAuthor": "高小定4", |
||||
"ranking": 4, |
"ranking": 4, |
||||
"num": 1100 |
"num": 1100 |
||||
} |
} |
||||
|
Write
Preview
Loading…
Cancel
Save
Reference in new issue