From db7c4875fb9336088b9a74f34f6f539950cdb344 Mon Sep 17 00:00:00 2001 From: JvD_Ericsson Date: Thu, 31 Aug 2023 14:45:18 +0100 Subject: Implicit attributes in get_attribute list Issue-ID: SDC-4612 Signed-off-by: JvD_Ericsson Change-Id: Id2f3e1f88470e0337a84868f2a66bc53e131e55b --- .../tosca-get-function/tosca-get-function.component.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'catalog-ui/src/app') diff --git a/catalog-ui/src/app/ng2/pages/properties-assignment/tosca-function/tosca-get-function/tosca-get-function.component.ts b/catalog-ui/src/app/ng2/pages/properties-assignment/tosca-function/tosca-get-function/tosca-get-function.component.ts index 5f5c2b60ee..67df3e46e1 100644 --- a/catalog-ui/src/app/ng2/pages/properties-assignment/tosca-function/tosca-get-function/tosca-get-function.component.ts +++ b/catalog-ui/src/app/ng2/pages/properties-assignment/tosca-function/tosca-get-function/tosca-get-function.component.ts @@ -409,8 +409,10 @@ export class ToscaGetFunctionComponent implements OnInit, OnChanges { } private addPropertyToDropdown(propertyDropdownValue: PropertyDropdownValue, propertyList: Array): void { - propertyList.push(propertyDropdownValue); - propertyList.sort((a, b) => a.propertyLabel.localeCompare(b.propertyLabel)); + if (!propertyList.find(prop => prop.propertyName === propertyDropdownValue.propertyName)) { + propertyList.push(propertyDropdownValue); + propertyList.sort((a, b) => a.propertyLabel.localeCompare(b.propertyLabel)); + } } private addPropertiesToDropdown(properties: Array, propertyList: Array): void { -- cgit 1.2.3-korg