mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
for title/content search does not make sense to search for protected notes
This commit is contained in:
parent
c48dbb0913
commit
ee15db0ae1
@ -113,6 +113,11 @@ module.exports = function(filters, selectedColumns = 'notes.*') {
|
|||||||
condition = "NOT(" + condition + ")";
|
condition = "NOT(" + condition + ")";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (['text', 'title', 'content'].includes(filter.name)) {
|
||||||
|
// for title/content search does not make sense to search for protected notes
|
||||||
|
condition = `(${condition} AND notes.isProtected = 0)`;
|
||||||
|
}
|
||||||
|
|
||||||
where += condition;
|
where += condition;
|
||||||
}
|
}
|
||||||
else if ([">", ">=", "<", "<="].includes(filter.operator)) {
|
else if ([">", ">=", "<", "<="].includes(filter.operator)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user