From 2727bbc7161372cc6165f210c9de08e7f20f1e0a Mon Sep 17 00:00:00 2001
From: shamoon <4887959+shamoon@users.noreply.github.com>
Date: Fri, 6 Feb 2026 22:26:05 -0800
Subject: [PATCH] Oops broke the buttons
---
.../document-attributes.component.html | 10 +++++----
.../document-attributes.component.ts | 22 ++++++-------------
2 files changed, 13 insertions(+), 19 deletions(-)
diff --git a/src-ui/src/app/components/manage/document-attributes/document-attributes.component.html b/src-ui/src/app/components/manage/document-attributes/document-attributes.component.html
index 92d497566..d8e30d189 100644
--- a/src-ui/src/app/components/manage/document-attributes/document-attributes.component.html
+++ b/src-ui/src/app/components/manage/document-attributes/document-attributes.component.html
@@ -68,11 +68,13 @@
{{ section.label }}
-
-
-
}
-
+
+
+
diff --git a/src-ui/src/app/components/manage/document-attributes/document-attributes.component.ts b/src-ui/src/app/components/manage/document-attributes/document-attributes.component.ts
index 77bae777d..780b81369 100644
--- a/src-ui/src/app/components/manage/document-attributes/document-attributes.component.ts
+++ b/src-ui/src/app/components/manage/document-attributes/document-attributes.component.ts
@@ -4,10 +4,8 @@ import {
inject,
OnDestroy,
OnInit,
- QueryList,
Type,
ViewChild,
- ViewChildren,
} from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import {
@@ -129,10 +127,8 @@ export class DocumentAttributesComponent implements OnInit, OnDestroy {
},
]
- @ViewChildren(ManagementListComponent)
- private attributeLists?: QueryList>
-
- @ViewChild(CustomFieldsComponent) private customFields?: CustomFieldsComponent
+ @ViewChild('activeOutlet', { read: NgComponentOutlet })
+ private activeOutlet?: NgComponentOutlet
activeNavID: number = null
@@ -154,18 +150,14 @@ export class DocumentAttributesComponent implements OnInit, OnDestroy {
get activeAttributeList(): ManagementListComponent | null {
if (this.activeSection?.kind !== 'attributeList') return null
- const permissionType = this.activeSection.permissionType
- return (
- this.attributeLists?.find(
- (list) => list.permissionType === permissionType
- ) ?? null
- )
+ const instance = this.activeOutlet?.componentInstance
+ return instance instanceof ManagementListComponent ? instance : null
}
get activeCustomFields(): CustomFieldsComponent | null {
- return this.activeSection?.kind === 'customFields'
- ? (this.customFields ?? null)
- : null
+ if (this.activeSection?.kind !== 'customFields') return null
+ const instance = this.activeOutlet?.componentInstance
+ return instance instanceof CustomFieldsComponent ? instance : null
}
get activeTabLabel(): string {