Skip to content

πŸ“š The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.

Fix command center: only documents

Smaug6739d8e60a551dd1
diff --git a/frontend/app/components/CommandCenter/AdvancedSearchTab.vue b/frontend/app/components/CommandCenter/AdvancedSearchTab.vue
index 6e632b69..8d39bfdb 100644
--- a/frontend/app/components/CommandCenter/AdvancedSearchTab.vue
+++ b/frontend/app/components/CommandCenter/AdvancedSearchTab.vue
@@ -146,6 +146,7 @@ const filteredDocuments = computed(() => {
fromDate: dateFrom.value ? new Date(dateFrom.value) : undefined,
toDate: dateTo.value ? new Date(dateTo.value) : undefined,
tags: selectedTags.value,
+ role: 3,
});
});
diff --git a/frontend/app/components/CommandCenter/QuickSearchTab.vue b/frontend/app/components/CommandCenter/QuickSearchTab.vue
index 74ccbdd8..fa3344bf 100644
--- a/frontend/app/components/CommandCenter/QuickSearchTab.vue
+++ b/frontend/app/components/CommandCenter/QuickSearchTab.vue
@@ -41,7 +41,7 @@ const filteredActions = computed(() => filterByTokens(quickActions, a => `${a.ti
const filteredDocuments = computed<SearchResult[]>(() =>
documentStore
- .search({ query: props.searchQuery })
+ .search({ query: props.searchQuery, role: 3 })
.slice(0, 5)
.map(d => ({
id: d.id,
diff --git a/frontend/app/stores/nodes.store.ts b/frontend/app/stores/nodes.store.ts
index 0053c4be..2276fad5 100644
--- a/frontend/app/stores/nodes.store.ts
+++ b/frontend/app/stores/nodes.store.ts
@@ -12,6 +12,7 @@ export interface SearchOptions {
sortBy?: 'created' | 'modified' | 'name';
sortType?: 'ascending' | 'descending';
matchMode?: 'includes' | 'starts' | 'exact';
+ role?: 1 | 2 | 3 | 4;
}
export const useNodesStore = defineStore('nodes', {
@@ -93,6 +94,8 @@ export const useNodesStore = defineStore('nodes', {
const hasTags = tags && tags.length > 0;
const filtered = nodes.filter(node => {
+ // --- Filter by role ---
+ if (options.role && node.role !== options.role) return false;
// --- Filter by text search ---
if (hasQuery) {
const content = `${node.name ?? ''} ${node.description ?? ''} ${node.tags ?? ''}`.toLowerCase();