π The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.
Vue dockergolangkanbanknowledge-baseknowledge-managementmarkdownnote-takingnotesnotes-appnotionnuxtnuxtjsoffline-firstoidcpwaselfhostedssovuevuejswiki
Fix drag item doc to doc parent id
Smaug6739aea111fdee89
diff --git a/frontend/components/sidebar/SidebarItem.vue b/frontend/components/sidebar/SidebarItem.vueindex d517f542..b2914576 100644--- a/frontend/components/sidebar/SidebarItem.vue+++ b/frontend/components/sidebar/SidebarItem.vue@@ -54,7 +54,6 @@ const drop = async (event: DragEvent) => {const draggedItemId = event.dataTransfer!.getData('text/plain');let draggedItem = documentStore.getById(draggedItemId) || categoriesStore.getById(draggedItemId) || navigationItems.find((item) => item.id === draggedItemId);- console.log(draggedItem);if (!draggedItem) return;@@ -77,7 +76,7 @@ const drop = async (event: DragEvent) => {if (documentStore.getAllChildrensIds(draggedItem.id).includes(props.item.parent_id)) return; // Prevent moving parent to childif (draggedItem.id === props.item.id) return; // Prevent moving to the same documentdocumentStore.update(- { ...draggedItem, parent_id: props.item.id }+ { ...draggedItem, parent_id: props.item.id, category: props.item.data.category });}if (draggedItem.type === "category" && props.item.data.type === "category") { // Move category to category