mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-21 02:35:23 -04:00
feat(note): add version attribute
This attribute was defined in the dev docs, but never implemented. Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
6944094b9b
commit
50c8f39c0c
3 changed files with 11 additions and 0 deletions
|
@ -89,6 +89,11 @@ export class Note {
|
|||
@JoinTable()
|
||||
tags: Promise<Tag[]>;
|
||||
|
||||
@Column({
|
||||
default: 2,
|
||||
})
|
||||
version: number;
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
||||
private constructor() {}
|
||||
|
||||
|
@ -113,6 +118,7 @@ export class Note {
|
|||
newNote.description = null;
|
||||
newNote.title = null;
|
||||
newNote.tags = Promise.resolve([]);
|
||||
newNote.version = 2;
|
||||
return newNote;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue