mirror of
https://github.com/zadam/trilium.git
synced 2025-11-15 09:45:52 +01:00
clean up tree service WIP
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import treeService from '../services/tree.js';
|
||||
import searchNotesService from '../services/search_notes.js';
|
||||
import noteAutocompleteService from '../services/note_autocomplete.js';
|
||||
import utils from "../services/utils.js";
|
||||
import appContext from "../services/app_context.js";
|
||||
|
||||
const $dialog = $("#jump-to-note-dialog");
|
||||
const $autoComplete = $("#jump-to-note-autocomplete");
|
||||
@@ -22,7 +22,7 @@ export async function showDialog() {
|
||||
return false;
|
||||
}
|
||||
|
||||
treeService.activateNote(suggestion.path);
|
||||
appContext.getActiveTabContext().setNote(suggestion.path);
|
||||
});
|
||||
|
||||
noteAutocompleteService.showRecentNotes($autoComplete);
|
||||
|
||||
@@ -3,6 +3,7 @@ import utils from '../services/utils.js';
|
||||
import server from '../services/server.js';
|
||||
import treeService from "../services/tree.js";
|
||||
import treeCache from "../services/tree_cache.js";
|
||||
import appContext from "../services/app_context.js";
|
||||
|
||||
const $dialog = $("#recent-changes-dialog");
|
||||
const $content = $("#recent-changes-content");
|
||||
@@ -54,7 +55,7 @@ export async function showDialog() {
|
||||
|
||||
await treeCache.reloadNotes([change.noteId]);
|
||||
|
||||
treeService.activateNote(change.noteId);
|
||||
appContext.getActiveTabContext().setNote(change.noteId);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user