summaryrefslogtreecommitdiffstats
path: root/catalog-ui
diff options
context:
space:
mode:
authorMichaelMorris <michael.morris@est.tech>2021-12-03 11:41:08 +0000
committerVasyl Razinkov <vasyl.razinkov@est.tech>2021-12-20 22:36:20 +0000
commit52a039956575a575b804d6bf72039feaabecdfc3 (patch)
tree87a59b6fe27e67d0929400435ff6e9a9699c3910 /catalog-ui
parent1588ce476208ad7270a2fa4c3385c4dc397907b7 (diff)
Fix set value of custom data type
Signed-off-by: MichaelMorris <michael.morris@est.tech> Issue-ID: SDC-3799 Change-Id: I68c7e67080edcc912cc882198192802c96a27f9b
Diffstat (limited to 'catalog-ui')
-rw-r--r--catalog-ui/src/app/ng2/pages/properties-assignment/properties-assignment.page.component.ts2
-rw-r--r--catalog-ui/src/app/ng2/pages/properties-assignment/services/properties.utils.ts6
2 files changed, 4 insertions, 4 deletions
diff --git a/catalog-ui/src/app/ng2/pages/properties-assignment/properties-assignment.page.component.ts b/catalog-ui/src/app/ng2/pages/properties-assignment/properties-assignment.page.component.ts
index e0a1cbf8ff..786aa8d566 100644
--- a/catalog-ui/src/app/ng2/pages/properties-assignment/properties-assignment.page.component.ts
+++ b/catalog-ui/src/app/ng2/pages/properties-assignment/properties-assignment.page.component.ts
@@ -355,7 +355,7 @@ export class PropertiesAssignmentComponent {
* Entry point handling response from server
*/
processInstancePropertiesResponse = (instanceBePropertiesMap: InstanceBePropertiesMap, originTypeIsVF: boolean) => {
- this.instanceFePropertiesMap = this.propertiesUtils.convertPropertiesMapToFEAndCreateChildren(instanceBePropertiesMap, originTypeIsVF, this.inputs); //create flattened children, disable declared props, and init values
+ this.instanceFePropertiesMap = this.propertiesUtils.convertPropertiesMapToFEAndCreateChildren(instanceBePropertiesMap, originTypeIsVF, this.inputs, this.component.model); //create flattened children, disable declared props, and init values
this.checkedPropertiesCount = 0;
this.checkedChildPropertiesCount = 0;
};
diff --git a/catalog-ui/src/app/ng2/pages/properties-assignment/services/properties.utils.ts b/catalog-ui/src/app/ng2/pages/properties-assignment/services/properties.utils.ts
index 544eb8173d..34d2a53afd 100644
--- a/catalog-ui/src/app/ng2/pages/properties-assignment/services/properties.utils.ts
+++ b/catalog-ui/src/app/ng2/pages/properties-assignment/services/properties.utils.ts
@@ -38,13 +38,13 @@ export class PropertiesUtils {
* 3. Initialize valueObj (which also creates any new list/map flattened children as needed)
* Returns InstanceFePropertiesMap
*/
- public convertPropertiesMapToFEAndCreateChildren = (instancePropertiesMap:InstanceBePropertiesMap, isVF:boolean, inputs?:Array<InputFEModel>): InstanceFePropertiesMap => {
+ public convertPropertiesMapToFEAndCreateChildren = (instancePropertiesMap:InstanceBePropertiesMap, isVF:boolean, inputs?:Array<InputFEModel>, model?:string): InstanceFePropertiesMap => {
let instanceFePropertiesMap:InstanceFePropertiesMap = new InstanceFePropertiesMap();
angular.forEach(instancePropertiesMap, (properties:Array<PropertyBEModel>, instanceId:string) => {
let propertyFeArray: Array<PropertyFEModel> = [];
_.forEach(properties, (property: PropertyBEModel) => {
-
- if (this.dataTypeService.getDataTypeByTypeName(property.type)) { // if type not exist in data types remove property from list
+
+ if (this.dataTypeService.getDataTypeByModelAndTypeName(model, property.type)) { // if type not exist in data types remove property from list
let newFEProp: PropertyFEModel = new PropertyFEModel(property); //Convert property to FE