feat(backend): Question + Answer entities toegevoegd; kleine verbeteringen.
This commit is contained in:
parent
cdfe48d8c5
commit
2657e49ad6
6 changed files with 79 additions and 19 deletions
|
@ -1,5 +1,6 @@
|
|||
import {Embeddable, Embedded, Entity, Enum, OneToOne, PrimaryKey, Property} from "@mikro-orm/core";
|
||||
import {Embeddable, Embedded, Entity, Enum, ManyToMany, OneToOne, PrimaryKey, Property} from "@mikro-orm/core";
|
||||
import {Language} from "./language";
|
||||
import {Teacher} from "../users/teacher.entity";
|
||||
|
||||
@Entity()
|
||||
export class LearningPath {
|
||||
|
@ -9,6 +10,9 @@ export class LearningPath {
|
|||
@Enum({items: () => Language, primary: true})
|
||||
language!: Language;
|
||||
|
||||
@ManyToMany({entity: () => Teacher})
|
||||
admins!: Teacher[];
|
||||
|
||||
@Property({type: "string"})
|
||||
title!: string;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue