Private
Public Access
1
0

Exclude current category from parent options when editing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Catherine Renelle
2026-02-13 18:46:32 -05:00
parent 0b4fa68236
commit 8f4d4eaabb
@@ -65,7 +65,7 @@ const showDeleteDialog = ref(false)
const deleteTarget = ref<CategoryTree | null>(null) const deleteTarget = ref<CategoryTree | null>(null)
const form = ref({ name: '', type: 'Expense', parentId: null as string | null, isActive: true }) const form = ref({ name: '', type: 'Expense', parentId: null as string | null, isActive: true })
const parentOptions = computed(() => allCategories.value.filter(c => !c.parentId)) const parentOptions = computed(() => allCategories.value.filter(c => !c.parentId && c.id !== editingCategory.value?.id))
onMounted(async () => { onMounted(async () => {
await reloadCategories() await reloadCategories()