merge: fixed merge conflicts on local branch
This commit is contained in:
commit
7f7df53d79
4 changed files with 19 additions and 19 deletions
|
@ -44,4 +44,4 @@ export class AssignmentController extends BaseController {
|
|||
getGroups(assignmentNumber: number, full = true) {
|
||||
return this.get<GroupsResponse>(`/${assignmentNumber}/groups`, { full });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,31 +10,31 @@ export class ClassController extends BaseController {
|
|||
super("class");
|
||||
}
|
||||
|
||||
getAll(full = true) {
|
||||
async getAll(full = true) {
|
||||
return this.get<{ classes: any[] }>(`/`, { full });
|
||||
}
|
||||
|
||||
getById(id: string) {
|
||||
async getById(id: string) {
|
||||
return this.get<{ class: any }>(`/${id}`);
|
||||
}
|
||||
|
||||
createClass(data: any) {
|
||||
async createClass(data: any) {
|
||||
return this.post<{ class: any }>(`/`, data);
|
||||
}
|
||||
|
||||
deleteClass(id: string) {
|
||||
async deleteClass(id: string) {
|
||||
return this.delete<{ class: any }>(`/${id}`);
|
||||
}
|
||||
|
||||
getStudents(id: string, full = true) {
|
||||
async getStudents(id: string, full = true) {
|
||||
return this.get<{ students: any[] }>(`/${id}/students`, { full });
|
||||
}
|
||||
|
||||
getTeacherInvitations(id: string, full = true) {
|
||||
async getTeacherInvitations(id: string, full = true) {
|
||||
return this.get<{ invitations: any[] }>(`/${id}/teacher-invitations`, { full });
|
||||
}
|
||||
|
||||
getAssignments(id: string, full = true) {
|
||||
async getAssignments(id: string, full = true) {
|
||||
return this.get<{ assignments: any[] }>(`/${id}/assignments`, { full });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,27 +10,27 @@ export class GroupController extends BaseController {
|
|||
super(`class/${classid}/assignments/${assignmentNumber}/groups`);
|
||||
}
|
||||
|
||||
getAll(full = true) {
|
||||
async getAll(full = true) {
|
||||
return this.get<{ groups: any[] }>(`/`, { full });
|
||||
}
|
||||
|
||||
getByNumber(num: number) {
|
||||
async getByNumber(num: number) {
|
||||
return this.get<{ group: any }>(`/${num}`);
|
||||
}
|
||||
|
||||
createGroup(data: any) {
|
||||
async createGroup(data: any) {
|
||||
return this.post<{ group: any }>(`/`, data);
|
||||
}
|
||||
|
||||
deleteClass(num: number) {
|
||||
async deleteClass(num: number) {
|
||||
return this.delete<{ group: any }>(`/${num}`);
|
||||
}
|
||||
|
||||
getSubmissions(groupNumber: number, full = true) {
|
||||
async getSubmissions(groupNumber: number, full = true) {
|
||||
return this.get<{ groups: any[] }>(`/${groupNumber}/submissions`, { full });
|
||||
}
|
||||
|
||||
getQuestions(groupNumber: number, full = true) {
|
||||
async getQuestions(groupNumber: number, full = true) {
|
||||
return this.get<{ questions: any[] }>(`/${groupNumber}/questions`, { full });
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,19 +5,19 @@ export class SubmissionController extends BaseController {
|
|||
super(`class/${classid}/assignments/${assignmentNumber}/groups/${groupNumber}`);
|
||||
}
|
||||
|
||||
getAll(full = true) {
|
||||
async getAll(full = true) {
|
||||
return this.get<any>(`/`, { full });
|
||||
}
|
||||
|
||||
getByNumber(submissionNumber: number) {
|
||||
async getByNumber(submissionNumber: number) {
|
||||
return this.get<any>(`/${submissionNumber}`);
|
||||
}
|
||||
|
||||
createSubmission(data: any) {
|
||||
async createSubmission(data: any) {
|
||||
return this.post<any>(`/`, data);
|
||||
}
|
||||
|
||||
deleteSubmission(submissionNumber: number) {
|
||||
async deleteSubmission(submissionNumber: number) {
|
||||
return this.delete<any>(`/${submissionNumber}`);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue