feat: verbinding student submissions
This commit is contained in:
parent
788ca54742
commit
d8b97f3aea
4 changed files with 42 additions and 5 deletions
|
@ -3,6 +3,7 @@ import {
|
|||
getStudentAssignments,
|
||||
getStudentClasses,
|
||||
getStudentGroups,
|
||||
getStudentSubmissions,
|
||||
StudentService,
|
||||
} from '../services/students.js';
|
||||
import { ClassDTO } from '../interfaces/class.js';
|
||||
|
@ -101,3 +102,16 @@ export async function getStudentGroupsHandler(
|
|||
groups: groups,
|
||||
});
|
||||
}
|
||||
|
||||
export async function getStudentSubmissionsHandler(
|
||||
req: Request,
|
||||
res: Response,
|
||||
): Promise<void> {
|
||||
const username = req.params.id;
|
||||
|
||||
const submissions = await getStudentSubmissions(username);
|
||||
|
||||
res.json({
|
||||
submissions: submissions,
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue