This commit is contained in:
msj
2026-09-22 17:20:17 +08:00
parent de67f868cb
commit 4849e73771
2 changed files with 7 additions and 1 deletions
+1 -1
View File
@@ -52,7 +52,7 @@ def update_students(stu_id:int
raise HTTPException(status_code=404, detail='学生不存在或已被删除,更新失败')
return {'code':200,'totals':r,'detail':'更新成功'}
@StudentAPI.delete('/students/{stu_id}',response_model= StugetResponse,summary='学生信息删除接口',description='删除学生信息')
@StudentAPI.delete('/students/{stu_id}',response_model= StudelResponse,summary='学生信息删除接口',description='删除学生信息')
def del_students(stu_id:int
,db=Depends(get_db)):
rows=delete_student_dao( stu_id=stu_id,db=db )
+6
View File
@@ -99,4 +99,10 @@ class StuPageResponse(BaseModel):
totals: int
data: List[StugetResponse]
class StudelResponse(BaseModel):
code: int = 200
detail: str = "ok"
totals: int