Files
whale-web/task02.md
Tomo Wang 24837acd07 task02
2021-04-27 21:13:14 +08:00

32 lines
1013 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 前言
本节课程,你将熟悉开发需求,并根据需求设计接口文档并编写接口规范。
# 用户管理
通过上节课程你已大概了解Django中现有的接口与Model及后端DB呈现并能看到用户相关的接口包括
* 注册 - register
* 登录 - login
* 登出 - logout
* 个人信息 - me
本节课程你需要扩展用户相关属性,并定义用户管理相关接口。
用户属性界面:
![user profile](./images/task02-user-profile.png)
需要基于现有的用户属性,扩充表单中要求的额外属性,如头像、学校、专业等。
1. 编辑[openapi.yaml](./openapi.yaml)中`components.schemas.User`
2. 新增用户增删改查接口文档
# 赛事管理
通过上节课程,你已了解`articles`相关接口并补充了其对应的OpenAPI接口规范文档。本节课你将需要根据
赛事管理的需求设计赛事管理相关的接口。
1. 确定赛事相关属性
2. 编写对应schema
3. 编写增删改查接口文档