
Dit was nodig om ervoor te zorgen dat de gebouwde applicatie ook haar dependencies vindt.
17 lines
457 B
TypeScript
17 lines
457 B
TypeScript
import { Entity, ManyToOne, PrimaryKey, Property } from '@mikro-orm/core';
|
|
import { LearningObject } from './learning-object.entity.js';
|
|
|
|
@Entity()
|
|
export class Attachment {
|
|
@ManyToOne({ entity: () => LearningObject, primary: true })
|
|
learningObject!: LearningObject;
|
|
|
|
@PrimaryKey({ type: 'integer' })
|
|
sequenceNumber!: number;
|
|
|
|
@Property({ type: 'string' })
|
|
mimeType!: string;
|
|
|
|
@Property({ type: 'blob' })
|
|
content!: Buffer;
|
|
}
|