cd server
npm install
or yarn install
cd server
npm run dev
or yarn dev
terminal console http://127.0.0.1:4900/api and Connected to mongodb success, backend run success
cd client
npm install
or yarn install
cd client
npm run start
or yarn start
terminal console Local: http://localhost:3000 , fronend run success
cd client
npm run build
or yarn build
method | api | desc |
---|---|---|
post | api/user/signup | user signup |
post | api/user/signin | user signin |
method | api | params | desc |
---|---|---|---|
get | api/book/search | keyword,page,size | get book list |
get | api/book/my | my book list | |
get | api/book/:id | id | get book detail |
post | api/book/ | category,ISBN,file,book_name,price,author,describe | add book |
delete | api/book/:id | id | delete book |
put | api/book/:id | id | update book |
method | api | params | desc |
---|---|---|---|
get | api/category/ | get category list | |
get | api/category/all | get category all list | |
post | api/category/ | name | add category |
put | api/category/:id | id, name | update category name, state |
method | api | params | desc |
---|---|---|---|
post | api/borrow/ | book information and user information | add borrow record |
delete | api/borrow/:id | id | delete borrow by id |
get | api/borrow/my | get borrow list | |
get | api/borrow/request | get requester list | |
get | api/borrow/:id | id | get borrow detail |
put | api/borrow/request/msg/:id | id,content | add message |
put | api/borrow/reply/msg/:id | id,content | replay requester message |
put | api/borrow/refuse/:id | id,content | refuse requester |
put | api/borrow/confirm/:id | id,content | confirm requester |
put | api/borrow/return/:id | id | return book |