feat: (BROKEN) kolossale bug in POST group aan het fixen

This commit is contained in:
Adriaan Jacquet 2025-03-13 16:39:59 +01:00
parent 1b66493821
commit 53c85eadb0
6 changed files with 36 additions and 13 deletions

View file

@ -1,4 +1,4 @@
import { Entity, ManyToMany, ManyToOne, PrimaryKey } from '@mikro-orm/core';
import { Collection, Entity, ManyToMany, ManyToOne, PrimaryKey } from '@mikro-orm/core';
import { Assignment } from './assignment.entity.js';
import { Student } from '../users/student.entity.js';
import { GroupRepository } from '../../data/assignments/group-repository.js';
@ -20,10 +20,8 @@ export class Group {
@PrimaryKey({ type: 'integer', autoincrement: true })
groupNumber?: number;
@ManyToMany({
entity: () => {
return Student;
},
@ManyToMany(() => {
return Student;
})
members!: Student[];
members!: Collection<Student>;
}