diff options
Diffstat (limited to 'catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts')
-rw-r--r-- | catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts b/catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts index 426ed4063e..e851bafc1d 100644 --- a/catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts +++ b/catalog-ui/src/app/ng2/pages/workspace/attributes/attribute-modal.component.ts @@ -32,6 +32,7 @@ export class AttributeModalComponent implements OnInit { // The current effective default value pattern public defaultValuePattern: string; public defaultValueErrorMessage: string; + public isEdit: boolean; // Attribute being Edited public attributeToEdit: AttributeModel; @@ -41,6 +42,11 @@ export class AttributeModalComponent implements OnInit { } ngOnInit() { + // Disable editing the name of existing attributes + if (this.attributeToEdit && this.attributeToEdit.name) { + this.isEdit = true; + } + this.revalidateDefaultValue(); } |