mirror of
https://github.com/zadam/trilium.git
synced 2025-11-13 16:55:50 +01:00
WIP per-tab hoisting
This commit is contained in:
@@ -5,7 +5,7 @@ const searchService = require('../../services/search/services/search.js');
|
||||
const repository = require('../../services/repository');
|
||||
const log = require('../../services/log');
|
||||
const utils = require('../../services/utils');
|
||||
const optionService = require('../../services/options');
|
||||
const cls = require('../../services/cls');
|
||||
|
||||
function getAutocomplete(req) {
|
||||
const query = req.query.query.trim();
|
||||
@@ -35,7 +35,7 @@ function getRecentNotes(activeNoteId) {
|
||||
let extraCondition = '';
|
||||
const params = [activeNoteId];
|
||||
|
||||
const hoistedNoteId = optionService.getOption('hoistedNoteId');
|
||||
const hoistedNoteId = cls.getHoistedNoteId();
|
||||
if (hoistedNoteId !== 'root') {
|
||||
extraCondition = `AND recent_notes.notePath LIKE ?`;
|
||||
params.push(hoistedNoteId + '%');
|
||||
|
||||
@@ -84,7 +84,7 @@ function getTree(req) {
|
||||
)
|
||||
SELECT noteId FROM treeWithDescendantsAscendantsAndTemplates`, [subTreeNoteId, subTreeNoteId]);
|
||||
|
||||
noteIds.push(subTreeNoteId);console.log("noteIds", noteIds);
|
||||
noteIds.push(subTreeNoteId);
|
||||
|
||||
return getNotesAndBranchesAndAttributes(noteIds);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user