学生管理
因相关表关系修改此部分目前无法使用
橙旭园
获取所有学生课程信息
Method and Url Structure
| Method |
Resource URL |
| GET |
/student/manage/ |
cURL Example
curl -X GET# 默认按上课时间倒序http://localhost:8000/server/student/manage/# 根据课程筛选# 注意:kind 需要 unicode 编码http://localhost:8000/server/student/manage/?kind=\u521b\u4f5c
- kind 参数
- 基础编程:
第一阶段:儿童编程-基础
- scratch:
scratch创作
- Python:
Python
- 奥赛:
信息学奥赛
- 其他:
other
JSON Response
{ "count": 1, "next": null, "previous": null, "results": [ { "pk": 1, "owner": "13263699826", "name": "我吃柠檬", "nickname": "柠檬", "teacher_info": { "owner": "17611237765" }, "room_info": { "status": "unfinish", "endtime": "2018-01-31T21:00:00", "starttime": "2018-01-31T19:50:00" }, "course_info": { "name": "橙旭园scratch创作(四)", "time": "2018-01-25T11:45:42.016166" } } ]}
根据电话搜索学生、老师
Method and Url Structure
| Method |
Resource URL |
| GET |
/student/search/?owenr= |
cURL Example
curl -X GEThttp://localhost:8000/server/student/search?owner=2222222
JSON Response
{ "count": 1, "next": null, "previous": null, "results": [ { "pk": 2, "owner": "1111111", "name": "买了个包", "nickname": "密密麻麻", "teacher_info": { "owner": "17611237765" }, "room_info": null, "course_info": { "name": "abced", "time": "2018-01-26T15:44:57.824667" } } ]}
获取学生教室列表、课程记录
Method and Url Structure
| Method |
Resource URL |
| GET |
/student/room/ |
| GET |
/student/record/ |
cURL Example
curl -X GEThttp://localhost:8000/server/student/room/?owner=13263699826# 课程记录http://localhost:8000/server/student/record/?owner=13263699826
JSON Response
{ "count": 3, "next": null, "previous": null, "results": [ { "pk": 4, "name": "MMSD", "schedule_info": { "endtime": "2018-01-31T21:00:00", "starttime": "2018-01-31T19:50:00" }, "status": "unfinish", "status_display": "未完成" }, { "pk": 2, "name": "f sa", "schedule_info": { "endtime": "2018-01-10T00:00:00", "starttime": "2018-01-10T19:53:00" }, "status": "finish", "status_display": "已完成" }, { "pk": 1, "name": "发顺丰", "schedule_info": { "endtime": "2018-01-08T12:00:00", "starttime": "2018-01-08T06:00:00" }, "status": "finish", "status_display": "已完成" } ]}# 课程记录{ "count": 2, "next": null, "previous": null, "results": [ { "course_name": "橙旭园scratch创作(四)", "create_time": "2018-01-25T11:45:42.016166" }, { "course_name": "第一阶段:儿童编程-基础套餐8岁及以上", "create_time": "2018-01-25T11:43:30.467804" } ]}
根据条件筛选
Method and Url Structure
| Method |
Resource URL |
| GET |
/student/sift/?kind= |
cURL Example
curl -X GEThttp://localhost:8000/server/student/sift/?kind=absent# 未续费(已购买课程的课时数和等于已结束的教室数)http://localhost:8000/server/student/sift/?kind=nopay
JSON Response
{ "count": 1, "next": null, "previous": null, "results": [ { "pk": 1, "owner": "13263699826", "name": "我吃柠檬", "nickname": "柠檬", "teacher_info": { "owner": "17611237765" }, "room_info": { "status": "unfinish", "endtime": "2018-01-31T21:00:00", "starttime": "2018-01-31T19:50:00" }, "course_info": { "name": "橙旭园scratch创作(四)", "time": "2018-01-25T11:45 - 列表项---:42.016166" } } ]}