From 41047e2b148da24568876fd8e78ef6da1dfefd83 Mon Sep 17 00:00:00 2001 From: Serhii Filonenko Date: Thu, 22 Jan 2026 13:18:01 +0200 Subject: [PATCH 1/3] HCK-14411: add alternate key config for attributes --- .../field_level/fieldLevelConfig.json | 926 +++++++++++++++++- 1 file changed, 906 insertions(+), 20 deletions(-) diff --git a/properties_pane/field_level/fieldLevelConfig.json b/properties_pane/field_level/fieldLevelConfig.json index 870c661..648cb52 100644 --- a/properties_pane/field_level/fieldLevelConfig.json +++ b/properties_pane/field_level/fieldLevelConfig.json @@ -159,6 +159,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -174,6 +181,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "dependencies", "foreignCollection", "foreignField", @@ -211,6 +301,89 @@ making sure that you maintain a proper JSON format. "step": 1, "typeDecorator": true }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "description", "dependencies", "comments" @@ -284,6 +457,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -299,6 +479,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, { "propertyName": "Precision", "propertyKeyword": "precision", @@ -400,6 +663,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -415,6 +685,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, { "propertyName": "Precision", "propertyKeyword": "precision", @@ -516,6 +869,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -531,26 +891,109 @@ making sure that you maintain a proper JSON format. ] } }, - "dependencies", - "foreignCollection", - "foreignField", - "relationshipType", - "default", - "unit", - "minimum", - "exclusiveMinimum", - "maximum", - "exclusiveMaximum", - "multipleOf", - "divisibleBy", - "enum", - "sample", - "comments" - ], - "float64": [ - "name", - "code", - "schemaId", + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "dependencies", + "foreignCollection", + "foreignField", + "relationshipType", + "default", + "unit", + "minimum", + "exclusiveMinimum", + "maximum", + "exclusiveMaximum", + "multipleOf", + "divisibleBy", + "enum", + "sample", + "comments" + ], + "float64": [ + "name", + "code", + "schemaId", "type", { "propertyName": "Type mode", @@ -647,6 +1090,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -662,6 +1112,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "dependencies", "comments" ], @@ -736,6 +1269,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -751,6 +1291,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "dependencies", "pattern", "default", @@ -772,6 +1395,89 @@ making sure that you maintain a proper JSON format. "propertyType": "select", "options": ["Nullable", "Required", "Repeated"] }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "description", "dependencies", "pattern", @@ -850,6 +1556,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -865,6 +1578,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "dependencies", "pattern", "default", @@ -942,6 +1738,13 @@ making sure that you maintain a proper JSON format. ] } ] + }, + { + "type": "not", + "values": { + "key": "unique", + "value": true + } } ] }, @@ -957,6 +1760,89 @@ making sure that you maintain a proper JSON format. ] } }, + { + "propertyName": "Unique", + "propertyKeyword": "compositeUniqueKey", + "propertyNameFull": "Composite Unique Key", + "propertyType": "checkbox", + "dependency": { + "key": "compositeUniqueKey", + "value": true + }, + "disabled": true + }, + { + "propertyName": "Unique", + "propertyKeyword": "unique", + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "and", + "values": [ + { + "type": "or", + "values": [ + { + "type": "or", + "values": [ + { + "key": "primaryKey", + "value": false + }, + { + "key": "primaryKey", + "exist": false + } + ] + }, + { + "key": "compositePrimaryKey", + "value": true + } + ] + }, + { + "type": "or", + "values": [ + { + "key": "compositeUniqueKey", + "value": false + }, + { + "key": "compositeUniqueKey", + "exist": false + } + ] + } + ] + } + }, + { + "propertyName": "Alternate Key", + "propertyKeyword": "alternateKey", + "defaultValue": false, + "enableForReference": true, + "propertyType": "checkbox", + "dependency": { + "type": "or", + "values": [ + { + "key": "unique", + "value": true + }, + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, + "disabledOnCondition": [ + { + "key": "compositeUniqueKey", + "value": true + } + ] + }, "dependencies", "pattern", "default", From 4ed59a68f07b9d78bfcc885cafcc9fd95af749d6 Mon Sep 17 00:00:00 2001 From: Serhii Filonenko Date: Thu, 22 Jan 2026 13:18:21 +0200 Subject: [PATCH 2/3] HCK-14411: add alternate key config for entities --- .../entity_level/entityLevelConfig.json | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/properties_pane/entity_level/entityLevelConfig.json b/properties_pane/entity_level/entityLevelConfig.json index 57f9a08..fb47ad9 100644 --- a/properties_pane/entity_level/entityLevelConfig.json +++ b/properties_pane/entity_level/entityLevelConfig.json @@ -807,6 +807,31 @@ making sure that you maintain a proper JSON format. "abbr": "pk" } ] + }, + { + "propertyName": "Unique key", + "propertyType": "group", + "propertyKeyword": "uniqueKey", + "propertyTooltip": "", + "structure": [ + { + "propertyName": "Key", + "propertyKeyword": "compositeUniqueKey", + "propertyType": "compositeKeySetter", + "abbr": "uk", + "setPrimaryKey": false, + "template": "collectiontree", + "isCompositeKey": true, + "disabledItemStrategy": "default" + }, + { + "propertyName": "Alternate key", + "propertyKeyword": "alternateKey", + "propertyTooltip": "", + "propertyType": "checkbox", + "setFieldPropertyBy": "compositeUniqueKey" + } + ] } ] } From fe3fdeca1720add700b08f8cce1f15c585e6a836 Mon Sep 17 00:00:00 2001 From: Serhii Filonenko Date: Thu, 22 Jan 2026 13:18:52 +0200 Subject: [PATCH 3/3] HCK-14411: add ERD abbreviation for alternate keys --- central_pane/style.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/central_pane/style.json b/central_pane/style.json index 87accda..55f153f 100644 --- a/central_pane/style.json +++ b/central_pane/style.json @@ -25,6 +25,15 @@ } ], "indexes", + { + "value": "AK", + "orderingNumbersBy": ["uniqueKey", "compositeUniqueKey"], + "dependency": { + "key": "alternateKey", + "value": true + }, + "width": 16 + }, "refType" ] }