Code Monkey home page Code Monkey logo

red-book-app's Introduction

技术方案

项目技术架构

前端:react-native

后端:Springboot + MySQL + redis

各模块方案

登录模块

  1. 用户在登录界面输入账号密码,点击登录按钮时发起请求。
  2. 请求前验证账号和密码字符是否大于6位,没超过则跳出错误提示。
  3. 发送请求前,密码先md5加密。
  4. 后端取得账号密码并对账号和密码进行查询,若无此账号或密码错误则返回错误消息。
  5. 后端验证成功则返回用户基本信息以及JWT Token,同时把数据都存入 Redis。
  6. 登出的时候会把redis的数据清空,如果redis的token没有或过期,前端就要重新登入。
  7. 登录成功后端返回JWT Token,前端本地存储,每次登入则带token。

注册模块

  1. 用户在注册界面输入账号,密码以及确认密码。点击注册按钮发起请求。
  2. 请求前验证确认密码是否跟密码一致,一致才发起请求。
  3. 后端判断用户是否存在,存在则返回错误。
  4. 注册成功则返回成功消息,前端跳转到登录界面。

Untitled Diagram (3).png

red-book-app's People

Contributors

franky0731 avatar gi3636 avatar

Watchers

 avatar

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.