Initial commit

This commit is contained in:
2025-05-06 12:42:05 +00:00
commit 287f7e2a3d
12 changed files with 294 additions and 0 deletions
+31
View File
@@ -0,0 +1,31 @@
import { WordResponseDTO } from "./dto/wordresponse.dto";
import type { ConceptEvent } from "./events";
export class WordCreateEvent implements ConceptEvent {
type = "create";
constructor(public word: WordResponseDTO) {
this.word = new WordResponseDTO(word);
}
}
export class WordEditEvent implements ConceptEvent {
type = "edit";
constructor(public word: WordResponseDTO) {
this.word = new WordResponseDTO(word);
}
}
export class WordDeleteEvent implements ConceptEvent {
type = "delete";
constructor(public id: number) {}
}
export class WordEnableEvent implements ConceptEvent {
type = "enable";
constructor(public id: number) {}
}
export class WordDisableEvent implements ConceptEvent {
type = "disable";
constructor(public id: number) {}
}