@crystaldesign/diva-backoffice 26.14.0-beta.8 → 26.14.0-beta.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/esm/index.js +39 -10
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/Features.d.ts.map +1 -1
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/Options.d.ts.map +1 -1
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/measureUnitValidator.d.ts +9 -0
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/measureUnitValidator.d.ts.map +1 -1
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/measureUnits.d.ts +3 -0
- package/build/types/backoffice/src/ui/IDMCatalogEditor/Tables/measureUnits.d.ts.map +1 -0
- package/build/types/backoffice/src/ui/IDMFeaturesEditor/Tables/Features.d.ts.map +1 -1
- package/build/types/backoffice/src/ui/IDMOrganizationFeaturesEditor/Tables/Features.d.ts.map +1 -1
- package/build/types/backoffice/src/ui/IDMOrganizationOptionsEditor/Tables/Options.d.ts.map +1 -1
- package/package.json +12 -12
package/build/esm/index.js
CHANGED
|
@@ -67157,21 +67157,36 @@ var NOTIFICATION_CONFIG = {
|
|
|
67157
67157
|
placement: 'bottomRight'
|
|
67158
67158
|
};
|
|
67159
67159
|
|
|
67160
|
+
// blank counts as empty, like the service: a blank parameter writes no MEASURE, a blank unit is none
|
|
67161
|
+
var isBlank$3 = function isBlank(value) {
|
|
67162
|
+
return value === undefined || value === null || String(value).trim() === '';
|
|
67163
|
+
};
|
|
67164
|
+
|
|
67160
67165
|
/** IDM requires FEATURE_TYPE/MEASURE/MEASURE_UNIT once MEASURE is there, which a measure parameter writes. */
|
|
67161
67166
|
function measureUnitValidator(t) {
|
|
67162
|
-
// blank counts as empty on both sides, like the service: a blank parameter writes no MEASURE
|
|
67163
|
-
var isBlank = function isBlank(value) {
|
|
67164
|
-
return value === undefined || value === null || String(value).trim() === '';
|
|
67165
|
-
};
|
|
67166
67167
|
return function (_ref) {
|
|
67167
67168
|
var value = _ref.value,
|
|
67168
67169
|
data = _ref.data;
|
|
67169
|
-
return !isBlank(data === null || data === void 0 ? void 0 : data.measureParameter) && isBlank(value) ? t('backoffice.idmCatalog.features.validation.measureUnitRequired', {
|
|
67170
|
+
return !isBlank$3(data === null || data === void 0 ? void 0 : data.measureParameter) && isBlank$3(value) ? t('backoffice.idmCatalog.features.validation.measureUnitRequired', {
|
|
67170
67171
|
defaultValue: 'Die Maßeinheit ist Pflicht, wenn ein Maßparameter gesetzt ist.'
|
|
67171
67172
|
}) : undefined;
|
|
67172
67173
|
};
|
|
67173
67174
|
}
|
|
67174
67175
|
|
|
67176
|
+
/** IDM requires OPTION_MEASURE/MEASURE_UNIT: a measure value means nothing without its unit, and the service refuses it. */
|
|
67177
|
+
function optionMeasureUnitValidator(t) {
|
|
67178
|
+
return function (_ref2) {
|
|
67179
|
+
var value = _ref2.value,
|
|
67180
|
+
data = _ref2.data;
|
|
67181
|
+
return !isBlank$3(data === null || data === void 0 ? void 0 : data.measureValue) && isBlank$3(value) ? t('backoffice.idmCatalog.options.validation.measureUnitRequired', {
|
|
67182
|
+
defaultValue: 'Die Maßeinheit ist Pflicht, wenn ein Maßwert gesetzt ist.'
|
|
67183
|
+
}) : undefined;
|
|
67184
|
+
};
|
|
67185
|
+
}
|
|
67186
|
+
|
|
67187
|
+
/** The UN/ECE codes of the IDM 4.1 code list measure_unit, which option and feature units must use; the service refuses others. */
|
|
67188
|
+
var IDM_MEASURE_UNITS = ['MMT', 'CMT', 'DMT', 'MTR', 'KTM', 'INH', 'FOT', 'YRD', 'MMK', 'CMK', 'DMK', 'MTK', 'INK', 'FTK', 'YDK', 'MGM', 'GRM', 'KGM', 'TNE', 'LBR', 'MMQ', 'CMQ', 'DMQ', 'MTQ', 'INQ', 'FTQ', 'YDQ', 'HLT', 'LTR', 'MLT', 'H87'];
|
|
67189
|
+
|
|
67175
67190
|
function _createForOfIteratorHelper$p(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$p(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
|
|
67176
67191
|
function _unsupportedIterableToArray$p(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$p(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$p(r, a) : void 0; } }
|
|
67177
67192
|
function _arrayLikeToArray$p(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
@@ -67589,6 +67604,10 @@ var Features$2 = /*#__PURE__*/forwardRef(function Features(_ref, ref) {
|
|
|
67589
67604
|
}, {
|
|
67590
67605
|
field: 'measureUnit',
|
|
67591
67606
|
headerName: 'backoffice.idmCatalog.features.label.measureUnit',
|
|
67607
|
+
cellDataType: 'enum',
|
|
67608
|
+
customParams: {
|
|
67609
|
+
enumData: IDM_MEASURE_UNITS
|
|
67610
|
+
},
|
|
67592
67611
|
cellValueValidator: measureUnitValidator(t),
|
|
67593
67612
|
editable: true
|
|
67594
67613
|
}, {
|
|
@@ -67697,7 +67716,11 @@ function Features$1(_ref) {
|
|
|
67697
67716
|
}
|
|
67698
67717
|
}, {
|
|
67699
67718
|
field: 'measureUnit',
|
|
67700
|
-
headerName: 'backoffice.idmCatalog.features.label.measureUnit'
|
|
67719
|
+
headerName: 'backoffice.idmCatalog.features.label.measureUnit',
|
|
67720
|
+
cellDataType: 'enum',
|
|
67721
|
+
customParams: {
|
|
67722
|
+
enumData: IDM_MEASURE_UNITS
|
|
67723
|
+
}
|
|
67701
67724
|
}, {
|
|
67702
67725
|
field: 'measureParameter',
|
|
67703
67726
|
headerName: 'backoffice.idmCatalog.features.label.measureParameter'
|
|
@@ -68078,8 +68101,9 @@ var Options$1 = /*#__PURE__*/forwardRef(function Options(_ref, ref) {
|
|
|
68078
68101
|
headerName: 'backoffice.idmCatalog.options.label.measureUnit',
|
|
68079
68102
|
field: 'measureUnit',
|
|
68080
68103
|
cellDataType: 'enum',
|
|
68104
|
+
cellValueValidator: optionMeasureUnitValidator(t),
|
|
68081
68105
|
customParams: {
|
|
68082
|
-
enumData:
|
|
68106
|
+
enumData: IDM_MEASURE_UNITS
|
|
68083
68107
|
}
|
|
68084
68108
|
}]
|
|
68085
68109
|
}, {
|
|
@@ -98532,7 +98556,11 @@ function Features(_ref) {
|
|
|
98532
98556
|
}
|
|
98533
98557
|
}, {
|
|
98534
98558
|
field: 'measureUnit',
|
|
98535
|
-
headerName: 'backoffice.idmCatalog.features.label.measureUnit'
|
|
98559
|
+
headerName: 'backoffice.idmCatalog.features.label.measureUnit',
|
|
98560
|
+
cellDataType: 'enum',
|
|
98561
|
+
customParams: {
|
|
98562
|
+
enumData: IDM_MEASURE_UNITS
|
|
98563
|
+
}
|
|
98536
98564
|
}, {
|
|
98537
98565
|
field: 'measureParameter',
|
|
98538
98566
|
headerName: 'backoffice.idmCatalog.features.label.measureParameter'
|
|
@@ -98792,8 +98820,9 @@ function Options(_ref) {
|
|
|
98792
98820
|
headerName: 'backoffice.idmCatalog.options.label.measureUnit',
|
|
98793
98821
|
field: 'measureUnit',
|
|
98794
98822
|
cellDataType: 'enum',
|
|
98823
|
+
cellValueValidator: optionMeasureUnitValidator(t),
|
|
98795
98824
|
customParams: {
|
|
98796
|
-
enumData:
|
|
98825
|
+
enumData: IDM_MEASURE_UNITS
|
|
98797
98826
|
}
|
|
98798
98827
|
}]
|
|
98799
98828
|
}, {
|
|
@@ -98828,7 +98857,7 @@ function Options(_ref) {
|
|
|
98828
98857
|
defaultValue: '${organizationId}'
|
|
98829
98858
|
}]
|
|
98830
98859
|
};
|
|
98831
|
-
}, []);
|
|
98860
|
+
}, [t]);
|
|
98832
98861
|
return /*#__PURE__*/jsx(Spreadsheet, {
|
|
98833
98862
|
gridId: 'crud-grid_global_features',
|
|
98834
98863
|
applicationData: applicationData,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2D,MAAM,OAAO,CAAC;AAIhF,OAAO,EAAE,SAAS,EAA+B,MAAM,0BAA0B,CAAC;AAClF,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACvF,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2D,MAAM,OAAO,CAAC;AAIhF,OAAO,EAAE,SAAS,EAA+B,MAAM,0BAA0B,CAAC;AAClF,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACvF,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAkBvC,QAAA,MAAM,QAAQ;oBAGM,MAAM;qBACL,WAAW;eACjB,SAAS;YACZ,oBAAoB,CAAC,GAAG,CAAC;6CAkUnC,CAAC;AAEH,eAAe,QAAQ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAEnD,OAAO,EAAE,SAAS,EAAkB,MAAM,0BAA0B,CAAC;AACrE,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACvF,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAEnD,OAAO,EAAE,SAAS,EAAkB,MAAM,0BAA0B,CAAC;AACrE,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACvF,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAKvC,QAAA,MAAM,OAAO;oBAGO,MAAM;qBACL,WAAW;eACjB,SAAS;YACZ,oBAAoB,CAAC,GAAG,CAAC;6CA8TnC,CAAC;AAEH,eAAe,OAAO,CAAC"}
|
|
@@ -7,4 +7,13 @@ export declare function measureUnitValidator(t: (key: string, options: {
|
|
|
7
7
|
measureParameter?: string | null;
|
|
8
8
|
} | undefined;
|
|
9
9
|
}) => string | undefined;
|
|
10
|
+
/** IDM requires OPTION_MEASURE/MEASURE_UNIT: a measure value means nothing without its unit, and the service refuses it. */
|
|
11
|
+
export declare function optionMeasureUnitValidator(t: (key: string, options: {
|
|
12
|
+
defaultValue: string;
|
|
13
|
+
}) => string): ({ value, data }: {
|
|
14
|
+
value: unknown;
|
|
15
|
+
data: {
|
|
16
|
+
measureValue?: number | null;
|
|
17
|
+
} | undefined;
|
|
18
|
+
}) => string | undefined;
|
|
10
19
|
//# sourceMappingURL=measureUnitValidator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"measureUnitValidator.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/measureUnitValidator.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"measureUnitValidator.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/measureUnitValidator.ts"],"names":[],"mappings":"AAGA,8GAA8G;AAC9G,wBAAgB,oBAAoB,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE;IAAE,YAAY,EAAE,MAAM,CAAA;CAAE,KAAK,MAAM,qBACvE;IAAE,KAAK,EAAE,OAAO,CAAC;IAAC,IAAI,EAAE;QAAE,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,GAAG,SAAS,CAAA;CAAE,wBAMpG;AAED,4HAA4H;AAC5H,wBAAgB,0BAA0B,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE;IAAE,YAAY,EAAE,MAAM,CAAA;CAAE,KAAK,MAAM,qBAC7E;IAAE,KAAK,EAAE,OAAO,CAAC;IAAC,IAAI,EAAE;QAAE,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,GAAG,SAAS,CAAA;CAAE,wBAMhG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"measureUnits.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/measureUnits.ts"],"names":[],"mappings":"AAAA,mIAAmI;AACnI,eAAO,MAAM,iBAAiB,UAgC7B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMFeaturesEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMFeaturesEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAQvC,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,qBA+FpE"}
|
package/build/types/backoffice/src/ui/IDMOrganizationFeaturesEditor/Tables/Features.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMOrganizationFeaturesEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Features.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMOrganizationFeaturesEditor/Tables/Features.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAOvC,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,qBAkIpE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMOrganizationOptionsEditor/Tables/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMOrganizationOptionsEditor/Tables/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAQvC,MAAM,CAAC,OAAO,UAAU,OAAO,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,qBA4NnE"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crystaldesign/diva-backoffice",
|
|
3
|
-
"version": "26.14.0-beta.
|
|
3
|
+
"version": "26.14.0-beta.9",
|
|
4
4
|
"description": "Ant Design backoffice shell (configuration modules), the Diva Data Engine component hosting the IDM and enricher editors, and the Produkt Onboarding component hosting the Assortment Manager.",
|
|
5
5
|
"license": "COMMERCIAL",
|
|
6
6
|
"devDependencies": {
|
|
@@ -16,16 +16,16 @@
|
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"@ant-design/icons": "6.3.4",
|
|
18
18
|
"@babel/runtime": "7.24.7",
|
|
19
|
-
"@crystaldesign/classification": "26.14.0-beta.
|
|
20
|
-
"@crystaldesign/content-box": "26.14.0-beta.
|
|
21
|
-
"@crystaldesign/content-item": "26.14.0-beta.
|
|
22
|
-
"@crystaldesign/diva-agent": "26.14.0-beta.
|
|
23
|
-
"@crystaldesign/diva-core": "26.14.0-beta.
|
|
24
|
-
"@crystaldesign/diva-utils": "26.14.0-beta.
|
|
25
|
-
"@crystaldesign/mass-configurator": "26.14.0-beta.
|
|
26
|
-
"@crystaldesign/media-upload": "26.14.0-beta.
|
|
27
|
-
"@crystaldesign/rtf-editor": "26.14.0-beta.
|
|
28
|
-
"@crystaldesign/spreadsheet": "26.14.0-beta.
|
|
19
|
+
"@crystaldesign/classification": "26.14.0-beta.9",
|
|
20
|
+
"@crystaldesign/content-box": "26.14.0-beta.9",
|
|
21
|
+
"@crystaldesign/content-item": "26.14.0-beta.9",
|
|
22
|
+
"@crystaldesign/diva-agent": "26.14.0-beta.9",
|
|
23
|
+
"@crystaldesign/diva-core": "26.14.0-beta.9",
|
|
24
|
+
"@crystaldesign/diva-utils": "26.14.0-beta.9",
|
|
25
|
+
"@crystaldesign/mass-configurator": "26.14.0-beta.9",
|
|
26
|
+
"@crystaldesign/media-upload": "26.14.0-beta.9",
|
|
27
|
+
"@crystaldesign/rtf-editor": "26.14.0-beta.9",
|
|
28
|
+
"@crystaldesign/spreadsheet": "26.14.0-beta.9",
|
|
29
29
|
"@dnd-kit/core": "^6.1.0",
|
|
30
30
|
"@dnd-kit/sortable": "^8.0.0",
|
|
31
31
|
"@dnd-kit/utilities": "^3.2.2",
|
|
@@ -63,5 +63,5 @@
|
|
|
63
63
|
"suiteName": "diva-backoffice",
|
|
64
64
|
"outputDirectory": "./test-reports"
|
|
65
65
|
},
|
|
66
|
-
"gitHead": "
|
|
66
|
+
"gitHead": "2b5401d0465ca846fff016a99231157dacd84a6a"
|
|
67
67
|
}
|