mirror of
https://github.com/zadam/trilium.git
synced 2025-11-11 15:55:52 +01:00
refactor(views): prepare for supporting subtrees
This commit is contained in:
@@ -256,6 +256,14 @@ class FNote {
|
||||
return this.children;
|
||||
}
|
||||
|
||||
async getSubtreeNoteIds() {
|
||||
let noteIds: (string | string[])[] = [];
|
||||
for (const child of await this.getChildNotes()) {
|
||||
noteIds.push(await child.getSubtreeNoteIds());
|
||||
}
|
||||
return noteIds.flat();
|
||||
}
|
||||
|
||||
async getChildNotes() {
|
||||
return await this.froca.getNotes(this.children);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user