mirror of
https://github.com/zadam/trilium.git
synced 2025-11-07 05:46:10 +01:00
refactoring of note detail API
This commit is contained in:
@@ -109,17 +109,12 @@ async function unprotectNoteAndSendToServer() {
|
||||
await appContext.getActiveTabContext().saveNote();
|
||||
|
||||
treeService.setProtected(activeNote.noteId, activeNote.isProtected);
|
||||
|
||||
await noteDetailService.reload();
|
||||
}
|
||||
|
||||
async function protectSubtree(noteId, protect) {
|
||||
await enterProtectedSession();
|
||||
|
||||
await server.put('notes/' + noteId + "/protect/" + (protect ? 1 : 0));
|
||||
|
||||
treeService.reload();
|
||||
noteDetailService.reload();
|
||||
}
|
||||
|
||||
function makeToast(message, protectingLabel, text) {
|
||||
|
||||
Reference in New Issue
Block a user