@crystaldesign/diva-backoffice 26.13.0-beta.32 → 26.13.0-beta.33
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
CHANGED
|
@@ -68958,6 +68958,32 @@ function OptionSetRefForm(_ref) {
|
|
|
68958
68958
|
read: "".concat(idmService, "/catalogs/").concat(catalogId, "/options?filter=featureNos==").concat(rowFeatureRef)
|
|
68959
68959
|
};
|
|
68960
68960
|
}, [catalogId, idmService, rowFeatureRef]);
|
|
68961
|
+
var _useDivaCore = useDivaCore(),
|
|
68962
|
+
jwt = _useDivaCore.state.jwt;
|
|
68963
|
+
var _useState = useState(false),
|
|
68964
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
68965
|
+
featureHasNoOptions = _useState2[0],
|
|
68966
|
+
setFeatureHasNoOptions = _useState2[1];
|
|
68967
|
+
useEffect(function () {
|
|
68968
|
+
var cancelled = false;
|
|
68969
|
+
// a new feature starts without the previous one's hint, also when its count cannot be read
|
|
68970
|
+
setFeatureHasNoOptions(false);
|
|
68971
|
+
// only a hint: if the count cannot be read, the form works as before without it
|
|
68972
|
+
fetch("".concat(optionsRead.read, "&skip=0&limit=1"), {
|
|
68973
|
+
headers: {
|
|
68974
|
+
Authorization: "Bearer ".concat(jwt)
|
|
68975
|
+
}
|
|
68976
|
+
}).then(function (res) {
|
|
68977
|
+
return res.ok ? res.json() : undefined;
|
|
68978
|
+
}).then(function (body) {
|
|
68979
|
+
if (!cancelled) setFeatureHasNoOptions((body === null || body === void 0 ? void 0 : body.total) === 0);
|
|
68980
|
+
})["catch"](function () {
|
|
68981
|
+
return undefined;
|
|
68982
|
+
});
|
|
68983
|
+
return function () {
|
|
68984
|
+
cancelled = true;
|
|
68985
|
+
};
|
|
68986
|
+
}, [optionsRead, jwt]);
|
|
68961
68987
|
var optionGroupsRead = useMemo(function () {
|
|
68962
68988
|
return {
|
|
68963
68989
|
read: "".concat(idmService, "/catalogs/").concat(catalogId, "/optiongroups")
|
|
@@ -69165,8 +69191,19 @@ function OptionSetRefForm(_ref) {
|
|
|
69165
69191
|
children: function children(_ref3) {
|
|
69166
69192
|
var getFieldValue = _ref3.getFieldValue;
|
|
69167
69193
|
var kind = getFieldValue('conditionKind');
|
|
69194
|
+
var picksOptions = kind === 'optionRefOp' || kind === 'optionList' || kind === 'optionInterval';
|
|
69168
69195
|
return /*#__PURE__*/jsxs(Fragment, {
|
|
69169
|
-
children: [
|
|
69196
|
+
children: [picksOptions && featureHasNoOptions && /*#__PURE__*/jsx(Alert, {
|
|
69197
|
+
type: "warning",
|
|
69198
|
+
showIcon: true,
|
|
69199
|
+
style: {
|
|
69200
|
+
marginBottom: 16
|
|
69201
|
+
},
|
|
69202
|
+
message: t("".concat(OPTIONS_SET_REF_I18N, ".hint.featureHasNoOptions"), {
|
|
69203
|
+
defaultValue: 'Feature {{featureNo}} hat noch keine Optionen. Lege zuerst unter „Options (OPV)“ Optionen für dieses Feature an, dann kannst du sie hier als Bedingung wählen.',
|
|
69204
|
+
featureNo: rowFeatureRef
|
|
69205
|
+
})
|
|
69206
|
+
}), kind === 'optionList' && /*#__PURE__*/jsx(Form$2.Item, {
|
|
69170
69207
|
name: "optionKeysSelected",
|
|
69171
69208
|
label: t('backoffice.idmCatalog.optionCombinations.optionsSetRef.label.optionKeysText'),
|
|
69172
69209
|
rules: requiredRules.multiSelect('optionKeysText'),
|
|
@@ -71912,48 +71949,51 @@ function PartlistPos(_ref) {
|
|
|
71912
71949
|
}
|
|
71913
71950
|
});
|
|
71914
71951
|
});
|
|
71952
|
+
// Inside the group, so it shows only while the group is open: a feature added to a closed group would land in a
|
|
71953
|
+
// hidden column and look as if nothing happened.
|
|
71954
|
+
var newFeatureColumn = {
|
|
71955
|
+
headerName: 'backoffice.idmCatalog.optionCombinations.label.newFeature',
|
|
71956
|
+
field: 'featureRefs',
|
|
71957
|
+
editable: false,
|
|
71958
|
+
filter: false,
|
|
71959
|
+
headerComponent: 'editColumnHeader',
|
|
71960
|
+
headerComponentParams: {
|
|
71961
|
+
onChange: addFeature,
|
|
71962
|
+
editorElement: 'lookup',
|
|
71963
|
+
editorElementProps: {
|
|
71964
|
+
nameField: 'featureRefsDisplayTexts',
|
|
71965
|
+
apiInterface: {
|
|
71966
|
+
read: apiConfig.idmService + '/catalogs/${catalogId}/allfeatures'
|
|
71967
|
+
},
|
|
71968
|
+
filter: function filter(_, lookupData) {
|
|
71969
|
+
var _partlist$featureRefs4;
|
|
71970
|
+
return !((_partlist$featureRefs4 = partlist.featureRefs) !== null && _partlist$featureRefs4 !== void 0 && _partlist$featureRefs4.includes(lookupData.featureNo));
|
|
71971
|
+
},
|
|
71972
|
+
lookupValue: 'featureText',
|
|
71973
|
+
lookupKey: 'featureNo',
|
|
71974
|
+
lookupKeyFilterType: {
|
|
71975
|
+
type: 'equals',
|
|
71976
|
+
filterType: 'number'
|
|
71977
|
+
},
|
|
71978
|
+
multiple: false,
|
|
71979
|
+
translated: true
|
|
71980
|
+
}
|
|
71981
|
+
}
|
|
71982
|
+
};
|
|
71915
71983
|
return conditionColumnGroup(t('backoffice.idmCatalog.partlistpos.label.conditions', {
|
|
71916
71984
|
defaultValue: 'Bedingungen'
|
|
71917
71985
|
}), t('backoffice.idmCatalog.optionCombinations.label.rule', {
|
|
71918
71986
|
defaultValue: 'Regel'
|
|
71919
|
-
}), features, columns);
|
|
71920
|
-
}, [columnContext, partlist, removeFeature, t]);
|
|
71987
|
+
}), features, [].concat(_toConsumableArray(columns), [newFeatureColumn]));
|
|
71988
|
+
}, [addFeature, apiConfig.idmService, columnContext, partlist, removeFeature, t]);
|
|
71921
71989
|
var configuration = useMemo(function () {
|
|
71922
71990
|
return {
|
|
71923
71991
|
type: 'dotnetSSM',
|
|
71924
71992
|
apiInterface: apiInterface,
|
|
71925
71993
|
dateFormat: 'DD.MM.YYYY, HH:mm:ss',
|
|
71926
|
-
colDef: [conditions
|
|
71927
|
-
headerName: 'backoffice.idmCatalog.optionCombinations.label.newFeature',
|
|
71928
|
-
field: 'featureRefs',
|
|
71929
|
-
editable: false,
|
|
71930
|
-
filter: false,
|
|
71931
|
-
headerComponent: 'editColumnHeader',
|
|
71932
|
-
headerComponentParams: {
|
|
71933
|
-
onChange: addFeature,
|
|
71934
|
-
editorElement: 'lookup',
|
|
71935
|
-
editorElementProps: {
|
|
71936
|
-
nameField: 'featureRefsDisplayTexts',
|
|
71937
|
-
apiInterface: {
|
|
71938
|
-
read: apiConfig.idmService + '/catalogs/${catalogId}/allfeatures'
|
|
71939
|
-
},
|
|
71940
|
-
filter: function filter(_, lookupData) {
|
|
71941
|
-
var _partlist$featureRefs4;
|
|
71942
|
-
return !((_partlist$featureRefs4 = partlist.featureRefs) !== null && _partlist$featureRefs4 !== void 0 && _partlist$featureRefs4.includes(lookupData.featureNo));
|
|
71943
|
-
},
|
|
71944
|
-
lookupValue: 'featureText',
|
|
71945
|
-
lookupKey: 'featureNo',
|
|
71946
|
-
lookupKeyFilterType: {
|
|
71947
|
-
type: 'equals',
|
|
71948
|
-
filterType: 'number'
|
|
71949
|
-
},
|
|
71950
|
-
multiple: false,
|
|
71951
|
-
translated: true
|
|
71952
|
-
}
|
|
71953
|
-
}
|
|
71954
|
-
}].concat(_toConsumableArray(partlistPosColumns(columnContext)))
|
|
71994
|
+
colDef: [conditions].concat(_toConsumableArray(partlistPosColumns(columnContext)))
|
|
71955
71995
|
};
|
|
71956
|
-
}, [
|
|
71996
|
+
}, [apiInterface, columnContext, conditions]);
|
|
71957
71997
|
return /*#__PURE__*/jsxs(Fragment, {
|
|
71958
71998
|
children: [/*#__PURE__*/jsx(Descriptions$1, {
|
|
71959
71999
|
title: /*#__PURE__*/jsx("div", {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OptionSetRefForm.d.ts","sourceRoot":"","sources":["../../../../../../../../src/ui/IDMCatalogEditor/Tables/OptionCombinations/OptionSetRefForm.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"OptionSetRefForm.d.ts","sourceRoot":"","sources":["../../../../../../../../src/ui/IDMCatalogEditor/Tables/OptionCombinations/OptionSetRefForm.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoD,MAAM,OAAO,CAAC;AAKzE,OAAO,EAGL,KAAK,QAAQ,EACb,KAAK,mBAAmB,EACzB,MAAM,sBAAsB,CAAC;AAE9B,MAAM,MAAM,aAAa,GAAG,mBAAmB,CAAC,MAAM,CAAC,CAAC;AAExD,MAAM,WAAW,sBAAsB;IACrC,aAAa,EAAE,aAAa,CAAC;IAC7B,QAAQ,EAAE,QAAQ,CAAC;IACnB,kBAAkB,EAAE,MAAM,EAAE,CAAC;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB;AAiBD,wBAAgB,qBAAqB,CAAC,CAAC,EAAE,mBAAmB,GAAG,sBAAsB,CAgEpF;AAUD,wBAAgB,yBAAyB,CAAC,CAAC,EAAE,sBAAsB,GAAG,mBAAmB,CAsExF;AAED,UAAU,qBAAqB;IAC7B,gFAAgF;IAChF,KAAK,CAAC,EAAE,mBAAmB,CAAC;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,IAAI,CAAC;IAC7C,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAID,wBAAgB,gBAAgB,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,qBAAqB,qBAyZxH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PartlistPos.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/PartlistPos.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuC,MAAM,OAAO,CAAC;AAE5D,OAAO,EAAE,SAAS,EAAqC,MAAM,0BAA0B,CAAC;AACxF,OAAO,
|
|
1
|
+
{"version":3,"file":"PartlistPos.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/IDMCatalogEditor/Tables/PartlistPos.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuC,MAAM,OAAO,CAAC;AAE5D,OAAO,EAAE,SAAS,EAAqC,MAAM,0BAA0B,CAAC;AACxF,OAAO,EAAc,oBAAoB,EAAsC,MAAM,4BAA4B,CAAC;AAMlH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAGpE,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,cAAc,EACd,OAAO,EACP,QAAQ,EACR,SAAS,EACT,KAAK,EACL,gBAAgB,EAChB,gCAAgC,EAChC,uBAA2B,EAC3B,gBAAgB,GACjB,EAAE;IACD,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,GAAG,CAAC;IACb,QAAQ,EAAE,GAAG,CAAC;IACd,SAAS,EAAE,SAAS,CAAC;IACrB,KAAK,CAAC,EAAE,oBAAoB,CAAC,GAAG,CAAC,CAAC;IAClC,gBAAgB,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,OAAO,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;IACzE,gHAAgH;IAChH,gCAAgC,CAAC,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9D,0FAA0F;IAC1F,uBAAuB,CAAC,EAAE,MAAM,CAAC;IACjC,iFAAiF;IACjF,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;CACrC,qBA+MA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crystaldesign/diva-backoffice",
|
|
3
|
-
"version": "26.13.0-beta.
|
|
3
|
+
"version": "26.13.0-beta.33",
|
|
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.13.0-beta.
|
|
20
|
-
"@crystaldesign/content-box": "26.13.0-beta.
|
|
21
|
-
"@crystaldesign/content-item": "26.13.0-beta.
|
|
22
|
-
"@crystaldesign/diva-agent": "26.13.0-beta.
|
|
23
|
-
"@crystaldesign/diva-core": "26.13.0-beta.
|
|
24
|
-
"@crystaldesign/diva-utils": "26.13.0-beta.
|
|
25
|
-
"@crystaldesign/mass-configurator": "26.13.0-beta.
|
|
26
|
-
"@crystaldesign/media-upload": "26.13.0-beta.
|
|
27
|
-
"@crystaldesign/rtf-editor": "26.13.0-beta.
|
|
28
|
-
"@crystaldesign/spreadsheet": "26.13.0-beta.
|
|
19
|
+
"@crystaldesign/classification": "26.13.0-beta.33",
|
|
20
|
+
"@crystaldesign/content-box": "26.13.0-beta.33",
|
|
21
|
+
"@crystaldesign/content-item": "26.13.0-beta.33",
|
|
22
|
+
"@crystaldesign/diva-agent": "26.13.0-beta.33",
|
|
23
|
+
"@crystaldesign/diva-core": "26.13.0-beta.33",
|
|
24
|
+
"@crystaldesign/diva-utils": "26.13.0-beta.33",
|
|
25
|
+
"@crystaldesign/mass-configurator": "26.13.0-beta.33",
|
|
26
|
+
"@crystaldesign/media-upload": "26.13.0-beta.33",
|
|
27
|
+
"@crystaldesign/rtf-editor": "26.13.0-beta.33",
|
|
28
|
+
"@crystaldesign/spreadsheet": "26.13.0-beta.33",
|
|
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": "0dc4a19c471089f3f69a33b5821f7ac5a63ca0ce"
|
|
67
67
|
}
|