Flask User Api Template screenshot

Flask User Api Template

Author Avatar Theme by Beanwei
Updated: 22 Apr 2018
170 Stars

flask + Vue => 前后端分离, 提供一个可以复用的 用户注册登录,QQ邮箱接收验证码,Token验证,session/cookie 登录的 模板

Categories

Overview

This product analysis is based on a web application that combines Flask, Vue, Vuex, and iView. The application focuses on separating the front-end and back-end, providing a reusable template for user registration, login, token verification, and session/cookie management. The analysis will cover the key features, installation guide, and a summary of the project.

Features

  • User registration and login: Allows users to register and login to the application.
  • QQ email integration: Connects with QQ email service to send verification code emails during registration.
  • Token-based authentication: Generates and stores tokens locally upon successful login.
  • User logout: Allows users to log out and destroys the token.
  • Session/Cookie persistence: Currently in-progress feature to maintain sessions using session/cookie storage.
  • CAPTCHA for new logins: Requires users to fill in a CAPTCHA code generated by the Python backend and cached in Redis. Displays the CAPTCHA image on the frontend and verifies the entered code with the database.

Installation

To install the Flask + Vue + Vuex + iView web application, follow these steps:

  1. Clone the repository from the provided URL.
  2. Navigate to the project directory.
  3. Set up a virtual environment and activate it.
  4. Install the required dependencies using the package manager.
  5. Configure the database settings in the application.
  6. Start the Flask backend server.
  7. Navigate to the frontend directory.
  8. Install the Node.js dependencies.
  9. Start the Vue frontend server.
  10. Access the application in a web browser.

Summary

The Flask + Vue + Vuex + iView web application offers a comprehensive template for user registration, login, and authentication. It includes features such as QQ email integration, token-based authentication, and CAPTCHA verification. The project has implemented most of the required business logic for user management and can be further customized and developed based on specific requirements.