feat: assignment permissies geupdate
This commit is contained in:
parent
cb4f6a512d
commit
9102268be1
3 changed files with 21 additions and 23 deletions
|
@ -22,6 +22,15 @@ export async function fetchGroup(classId: string, assignmentNumber: number, grou
|
|||
return group;
|
||||
}
|
||||
|
||||
export async function fetchAllGroups(classId: string, assignmentNumber: number): Promise<Group[]> {
|
||||
const assignment = await fetchAssignment(classId, assignmentNumber);
|
||||
|
||||
const groupRepository = getGroupRepository();
|
||||
const groups = await groupRepository.findAllGroupsForAssignment(assignment);
|
||||
|
||||
return groups;
|
||||
}
|
||||
|
||||
export async function getGroup(classId: string, assignmentNumber: number, groupNumber: number): Promise<GroupDTO> {
|
||||
const group = await fetchGroup(classId, assignmentNumber, groupNumber);
|
||||
return mapToGroupDTO(group);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue