File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,7 +15,6 @@ const {
1515const { PositiveIdValidator } = require ( '../../validators/common' ) ;
1616
1717const { BookNotFound } = require ( '../../libs/err-code' ) ;
18- const { Book } = require ( '../../models/book' ) ;
1918const { BookDao } = require ( '../../dao/book' ) ;
2019
2120// book 的红图实例
@@ -93,14 +92,4 @@ bookApi.linDelete(
9392 }
9493) ;
9594
96- bookApi . get ( '/' , async ctx => {
97- const books = await Book . findAll ( ) ;
98- if ( books . length < 1 ) {
99- throw new NotFound ( {
100- msg : '没有找到相关书籍'
101- } ) ;
102- }
103- ctx . json ( books ) ;
104- } ) ;
105-
10695module . exports = { bookApi, [ disableLoading ] : false } ;
Original file line number Diff line number Diff line change 4343 "koa-bodyparser" : " ^4.2.1" ,
4444 "koa-mount" : " ^4.0.0" ,
4545 "koa-static" : " ^5.0.0" ,
46- "lin-mizar" : " ^0.2.0-beta.1 "
46+ "lin-mizar" : " ^0.2.0-beta.2 "
4747 }
4848}
You can’t perform that action at this time.
0 commit comments