Request
{
"name": 1612941,
"password_hash": awgyu223
}
Response
{
"state_code":0, // 0-成功,-1-用户名不存在,1-密码不正确
"id": 139179
}
Request
{
"id_user": 1612841
}
Response
{
"name": "xrx",
"student_number": 1612941,
"rank_score": 238,
"email": 1612941@mail.nankai.edu.cn
}
Request
{
"id_user": 1612941
}
Response
[{
courses: [{
"name": "数据结构",
"start_time": ”2019-4-1 14:00:00”,
"end_time": ”2019-4-2 14:00:00”,
"description":"数据结构课"
}]
}]
Request
{
"id_course": 123
}
Response
{
lab: [{
"name":123,
"start_time": ”2019-4-1 14:00:00”,
"end_time": ”2019-4-2 14:00:00”,
}]
}
Request
{
"id_course": 123
}
Response
{
lecture: [{
"name":二叉树,
"start_time": ”2019-4-1 14:00:00”,
"end_time": ”2019-4-2 14:00:00”,
}]
}
Request
{
"id_lab": 123
}
Response
{
"name": "二叉树",
"description": "实现搜索二叉树",
"start_time": ”2019-4-1 14:00:00”,
"end_time": ”2019-4-1 14:00:00”,
"report_required":true,
"problem_weight": 0.2,
"attachment_weight": 0.8,
[{
"id_problem": 123,
"name": "搜索二叉树",
"score":100/100
}] // 实验课问题
}
Request
{
"id_user":123,
"id_lab":123,
"file"//本地路径地址
}
{
state_code // 0-成功,-1-上传失败
}
Request
{
"id_lecture": 123
}
Response
{
"name": "数据结构",
"description": "数据结构课程",
"start_time": ”2019-4-1 14:00:00”,
"end_time": ”2020-4-1 14:00:00”,
[{
"name": "PPT1",
"path": "https://www.yuque.com/docs/share/e2db0e32-8463-4eac-b532-04bc6709eaa5",
"size": 23MB
}] // 课程资源
[{
"id_problem": 123,
"name": "Traveller",
"score":100/100
}] // 主讲课问题
}
Request
{
"id_course_resource"
}
Response
[{
"name": "课件"
"path": "https://www.yuque.com/docs/share/e2db0e32-8463-4eac-b532-04bc6709eaa5"
}]
Request
{
"id_user": 1612841,
information: {
"name": "xrx",
"email": 1612941@mail.nankai.edu.cn,
"password": 123456
}
}
Response
{
state_code: 0/-1
}
Request
{
"id_course": 123
}
Response
[{
"message": []
}]
Request
{
"id_student": 1612941
}
Response
[{
problem: [{
"created_at": 2019-4-1 14:00:00
"runtime": 300ms,
"memory": 648KB,
"score": 20/100,
"language": C++,
"code":"#include<iostream>\r\nint main(){cout<<123;\r\nreturn 0;}"
}]
}]
Request
{
"id": id // 考试id
}
Response
[{
“name”:“2019-2020年第2学期 算法导论考试”,
“start_time”:”2019-4-1 14:00:00”
“end_time”:”2019-4-1 15:00:00”
“description”:”请同学们不要作弊,祝考试顺利”
“created_at”:“2019-3-31 14:00:00”
“modified_at”:”2019-4-1 9:00:00”
exam_problem:[
{
“id_problem”:1,
“name”:”滔滔摘苹果”
“type”:”A”,
“weight”:0.3,
“case_number”:10
}
]
}]
Request
{
"problem_id": id, // 题目id
}
Response
{
“name”:“Traveler",
“start_time”:”2019-4-1 14:00:00”,
“end_time”:”2019-4-1 15:00:00”,
“description”:”旅行者问题”,
"runtime_limit": 1000ms,
"memory_limit": 64000KB
}
Request
{
"user_id": 1,
"problem_id": 2,
"code": "#include<iostream>\r\nint main(){cout<<123;\r\nreturn 0;}"
}
{
"runtime": 300ms,
"memory": 648KB
}
Request
{
"user_id": 1,
"problem_id": 2
}
{
"created_at": 2019-4-1 14:00:00
"runtime": 300ms,
"memory": 648KB,
"score": 20/100,
"language": C++,
"code":"#include<iostream>\r\nint main(){cout<<123;\r\nreturn 0;}"
}
原文:https://www.cnblogs.com/cs-sunday/p/10869128.html