GithubHelp home page GithubHelp logo

book_handling_frontend's Introduction

book_handling_frontend's People

Contributors

xichi avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

toulzx

book_handling_frontend's Issues

用户操作

需求分析

用户相关的操作

接口使用情况

  • 获取全部图书列表:/book/list,get方法;
  • 用户借阅图书:/book​/borrow,post方法,body传id(书本id);
  • 用户归还图书:/book/giveBack,post方法,body传 id(书本id);
  • 用户获取图书评论:/comment/get,get方法;
  • 用户评论图书:/comment/book,post方法,body传 id(评论id)、text;
  • 用户对对评论进行评论:/comment/subComment,post方法,body传 id(所评论的评论id)、text;

注意

  1. 如果用户未登陆却进行相应操作,记得提醒ta登陆。
  2. 网页可以是(图书列表页+详情页)的设计,也可以把所有操作都放在一个页面。看你自己的想法,不要忘记修改相应的路由(router.js)。

用户/管理员登录注册逻辑

需求描述:

  • 注册用户:username , email , password , studentId必填,并在成功注册后自动调用登录接口完成登录,并跳转到 首页;
  • 用户登录:email , password 必填,成功登录则自动跳转到 首页 ;
  • 管理员登录:email , password 必填,成功登录则自动跳转到 管理页;

接口使用情况:

注册:/user/register,post 方法,body 中传 username、email、password、studentId;
用户登录:/auth/user,post方法,body中传 email、password;
管理员登录:/auth/admin,同上

细节补充

登录后应将 token 存入 sessionStorage 中,并在需要时使用。(已实现,如需修改可查看store.js)

管理员操作

需求描述

实现管理员操作。

接口

管理员获取所有的借阅记录:​/admin​/getRecord,get方法;
管理员添加图书:/admin/addBook,post 方法,body 传 bookName, author, totalCount;
管理员编辑图书:/admin/editBook,post方法,body 传 bookName, author, totalCount, id;
管理员删除图书:/admin/editBook,post方法,body 传 id;

进阶

能够使用 Excel表格 一次性导入书籍,采取多次请求的方式完成(请求的并发或者串行)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.