feat: (frontend) queries teacher + test controller teacher
This commit is contained in:
parent
5e0f284131
commit
44c242fc57
11 changed files with 184 additions and 59 deletions
|
@ -14,11 +14,11 @@ export class StudentController extends BaseController {
|
|||
}
|
||||
|
||||
createStudent(data: any) {
|
||||
return this.post<{ student: any }>("/", data);
|
||||
return this.post("/", data);
|
||||
}
|
||||
|
||||
deleteStudent(username: string) {
|
||||
return this.delete<{ student: any }>(`/${username}`);
|
||||
return this.delete(`/${username}`);
|
||||
}
|
||||
|
||||
getClasses(username: string, full = true) {
|
||||
|
@ -46,10 +46,10 @@ export class StudentController extends BaseController {
|
|||
}
|
||||
|
||||
createJoinRequest(username: string, classId: string) {
|
||||
return this.post<any>(`/${username}/joinRequests/${classId}`);
|
||||
return this.post(`/${username}/joinRequests}`, classId);
|
||||
}
|
||||
|
||||
deleteJoinRequest(username: string, classId: string) {
|
||||
return this.delete<any>(`/${username}/joinRequests/${classId}`);
|
||||
return this.delete(`/${username}/joinRequests/${classId}`);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue