@crystaldesign/web-planner-logic 26.8.0-beta.9 → 26.9.0-beta.2
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/cjs/{DivaBoxPlanner-83179ff7.js → DivaBoxPlanner-c8851567.js} +29 -31
- package/build/cjs/{DivaStandardPlanner-feb90e57.js → DivaStandardPlanner-7bc436a9.js} +3 -3
- package/build/cjs/{DoorPlanner-2874145e.js → DoorPlanner-66d87428.js} +1 -1
- package/build/cjs/{Host3DSignalR-f60b2a47.js → Host3DSignalR-86c47fd9.js} +1 -1
- package/build/cjs/{LiviqueWWSHandler-8b2204b4.js → LiviqueWWSHandler-e0237503.js} +1 -1
- package/build/cjs/{PfisterWWSHandler-0f04739e.js → PfisterWWSHandler-91a53f99.js} +10 -1
- package/build/cjs/{PlannerHandler2D-ad4ffcc7.js → PlannerHandler2D-21891681.js} +24 -9
- package/build/cjs/{SeriousBasketHandler-7b5f6ce7.js → SeriousBasketHandler-39f6c012.js} +1 -1
- package/build/cjs/{ShelfPlanner-7deeff65.js → ShelfPlanner-9323783f.js} +1 -1
- package/build/cjs/{StandardWWSHandler-b4b0af49.js → StandardWWSHandler-87d4c9ca.js} +1 -1
- package/build/cjs/{index-0ac66aff.js → index-89322318.js} +479 -295
- package/build/cjs/index.js +1 -1
- package/build/esm/{DivaBoxPlanner-ecfa33bb.js → DivaBoxPlanner-05a7aba4.js} +29 -31
- package/build/esm/{DivaStandardPlanner-bf34f32f.js → DivaStandardPlanner-c5615a1d.js} +3 -3
- package/build/esm/{DoorPlanner-236986bd.js → DoorPlanner-dc53eaca.js} +1 -1
- package/build/esm/{Host3DSignalR-38ceb160.js → Host3DSignalR-e94ff645.js} +1 -1
- package/build/esm/{LiviqueWWSHandler-981c5546.js → LiviqueWWSHandler-35286ba2.js} +1 -1
- package/build/esm/{PfisterWWSHandler-fbf0592e.js → PfisterWWSHandler-4ac1baf9.js} +10 -1
- package/build/esm/{PlannerHandler2D-71ec7606.js → PlannerHandler2D-d863886b.js} +24 -9
- package/build/esm/{SeriousBasketHandler-a61c2401.js → SeriousBasketHandler-fd07c5d0.js} +1 -1
- package/build/esm/{ShelfPlanner-aa0f9a5f.js → ShelfPlanner-2a545c7c.js} +1 -1
- package/build/esm/{StandardWWSHandler-82743246.js → StandardWWSHandler-21793a92.js} +1 -1
- package/build/esm/{index-e4533e4a.js → index-176318a8.js} +479 -295
- package/build/esm/index.js +1 -1
- package/build/types/web-planner-logic/src/index.d.ts +1 -1
- package/build/types/web-planner-logic/src/index.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/API/Checkout.d.ts +10 -2
- package/build/types/web-planner-logic/src/interface/API/Checkout.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/AdditionalModelInfos.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/AdditionalModelInfos.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/Articles/ArticleDataType.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/Articles/ArticleDataType.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/Articles/CatalogArticleDataType.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/Articles/CatalogArticleDataType.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/Articles/PartListArticleToLoadType.d.ts +1 -1
- package/build/types/web-planner-logic/src/interface/Articles/PartListArticleToLoadType.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/DivaCatalogDataType.d.ts +4 -0
- package/build/types/web-planner-logic/src/interface/DivaCatalogDataType.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/FunctionTypes/index.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/FunctionTypes/index.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/IDM/ArticleApi.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/IDM/ArticleApi.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/IDM/Feature.d.ts +4 -0
- package/build/types/web-planner-logic/src/interface/IDM/Feature.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/interface/OptionTypes/CatalogOptionDataTypes.d.ts +1 -0
- package/build/types/web-planner-logic/src/interface/OptionTypes/CatalogOptionDataTypes.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts +2 -0
- package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Article/DivaArticleHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Article/Engine/DivaArticleEngine.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Article/Engine/IDMArticleEngine.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Basket/PfisterWWSHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/ConfigTree/DivaConfigTreeHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/DivaApiHandler.d.ts +13 -0
- package/build/types/web-planner-logic/src/logic/DivaApiHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/DivaCatalogHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/DivaWebPlanner.d.ts +1 -0
- package/build/types/web-planner-logic/src/logic/DivaWebPlanner.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/BoxPlannerGrid.d.ts +1 -0
- package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/BoxPlannerGrid.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/ConstructionRulesHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/logic/Planner/PlannerUtils/DockingPointHandler.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Articles/Article/CatalogArticleData.d.ts +1 -0
- package/build/types/web-planner-logic/src/model/Articles/Article/CatalogArticleData.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Articles/Article/IDMCatalogArticle.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Catalog/CatalogData.d.ts +5 -0
- package/build/types/web-planner-logic/src/model/Catalog/CatalogData.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Catalog/DivaCatalogData.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Catalog/IDMCatalogData.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Options/ArticleOptionValueData.d.ts +2 -0
- package/build/types/web-planner-logic/src/model/Options/ArticleOptionValueData.d.ts.map +1 -1
- package/build/types/web-planner-logic/src/model/Options/CatalogOptionValueData.d.ts +8 -0
- package/build/types/web-planner-logic/src/model/Options/CatalogOptionValueData.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -75,6 +75,7 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
75
75
|
_defineProperty(this, "actions", void 0);
|
|
76
76
|
_defineProperty(this, "state", void 0);
|
|
77
77
|
_defineProperty(this, "i18n", void 0);
|
|
78
|
+
_defineProperty(this, "enricherErrorModalShown", false);
|
|
78
79
|
_defineProperty(this, "getSessionGuid", void 0);
|
|
79
80
|
_defineProperty(this, "useEkPrices", false);
|
|
80
81
|
_defineProperty(this, "smSupplierNr", undefined);
|
|
@@ -215,10 +216,12 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
215
216
|
case 38:
|
|
216
217
|
_context.prev = 38;
|
|
217
218
|
_context.t5 = _context["catch"](5);
|
|
219
|
+
// Check if this is a rate limiting error (429)
|
|
220
|
+
this.notifyEnricherError(url, dontLogError);
|
|
218
221
|
throw Error('fetch failed! ' + url + ' Error: ' + _context.t5, {
|
|
219
222
|
cause: _context.t5 === null || _context.t5 === void 0 || (_e$response = _context.t5.response) === null || _e$response === void 0 || (_e$response = _e$response.data) === null || _e$response === void 0 ? void 0 : _e$response.error
|
|
220
223
|
});
|
|
221
|
-
case
|
|
224
|
+
case 42:
|
|
222
225
|
case "end":
|
|
223
226
|
return _context.stop();
|
|
224
227
|
}
|
|
@@ -229,11 +232,57 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
229
232
|
}
|
|
230
233
|
return fetchData;
|
|
231
234
|
}()
|
|
235
|
+
/**
|
|
236
|
+
* Surface critical failures to the user. A hard failure of any enricher call (catalog / serie /
|
|
237
|
+
* items / decisions / features ...) leaves the planner unable to load, so give the user actionable
|
|
238
|
+
* feedback instead of a silently broken UI. Optional enricher calls (e.g. the catalog mask) pass
|
|
239
|
+
* `dontLogError` and are skipped. Only one modal is shown at a time to avoid stacking on parallel failures.
|
|
240
|
+
*/
|
|
241
|
+
}, {
|
|
242
|
+
key: "notifyEnricherError",
|
|
243
|
+
value: function notifyEnricherError(url, dontLogError) {
|
|
244
|
+
var _this$apiConfig,
|
|
245
|
+
_this$apiConfig2,
|
|
246
|
+
_this$apiConfig3,
|
|
247
|
+
_this$apiConfig4,
|
|
248
|
+
_this$apiConfig5,
|
|
249
|
+
_this$actions,
|
|
250
|
+
_this$i18n,
|
|
251
|
+
_translate$t,
|
|
252
|
+
_translate$t2,
|
|
253
|
+
_translate$t3,
|
|
254
|
+
_this = this;
|
|
255
|
+
if (dontLogError || this.enricherErrorModalShown) return;
|
|
256
|
+
var services = [(_this$apiConfig = this.apiConfig) === null || _this$apiConfig === void 0 ? void 0 : _this$apiConfig.enricherService, (_this$apiConfig2 = this.apiConfig) === null || _this$apiConfig2 === void 0 ? void 0 : _this$apiConfig2.idmService, (_this$apiConfig3 = this.apiConfig) === null || _this$apiConfig3 === void 0 ? void 0 : _this$apiConfig3.api2["default"], (_this$apiConfig4 = this.apiConfig) === null || _this$apiConfig4 === void 0 ? void 0 : _this$apiConfig4.api2.web, (_this$apiConfig5 = this.apiConfig) === null || _this$apiConfig5 === void 0 ? void 0 : _this$apiConfig5.api2.ek];
|
|
257
|
+
if (!services.some(function (service) {
|
|
258
|
+
return service && url.startsWith(service);
|
|
259
|
+
})) return;
|
|
260
|
+
if (!((_this$actions = this.actions) !== null && _this$actions !== void 0 && _this$actions.openModal)) return;
|
|
261
|
+
this.enricherErrorModalShown = true;
|
|
262
|
+
var translate = (_this$i18n = this.i18n) === null || _this$i18n === void 0 ? void 0 : _this$i18n.call(this);
|
|
263
|
+
this.actions.openModal({
|
|
264
|
+
title: (_translate$t = translate === null || translate === void 0 ? void 0 : translate.t('modals.error_accured')) !== null && _translate$t !== void 0 ? _translate$t : 'An error occured. Please try again later.',
|
|
265
|
+
accept: (_translate$t2 = translate === null || translate === void 0 ? void 0 : translate.t('modals.reload_page')) !== null && _translate$t2 !== void 0 ? _translate$t2 : 'Reload',
|
|
266
|
+
reject: (_translate$t3 = translate === null || translate === void 0 ? void 0 : translate.t('modals.close')) !== null && _translate$t3 !== void 0 ? _translate$t3 : 'Close',
|
|
267
|
+
callback: function callback(accepted) {
|
|
268
|
+
_this.enricherErrorModalShown = false;
|
|
269
|
+
if (accepted === true) {
|
|
270
|
+
if (_this.getApplicationEnvironment() === 'WEB' && typeof window !== 'undefined') window.location.reload();
|
|
271
|
+
} else if (accepted === false) {
|
|
272
|
+
var _this$actions2, _this$actions3;
|
|
273
|
+
(_this$actions2 = _this.actions) === null || _this$actions2 === void 0 || _this$actions2.onEvent({
|
|
274
|
+
type: 'onWebPlanerClose'
|
|
275
|
+
});
|
|
276
|
+
(_this$actions3 = _this.actions) === null || _this$actions3 === void 0 || _this$actions3.closeComponentInFullscreen();
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
});
|
|
280
|
+
}
|
|
232
281
|
}, {
|
|
233
282
|
key: "getDataWithoutCache",
|
|
234
283
|
value: function () {
|
|
235
284
|
var _getDataWithoutCache = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2(queryString, init, useWebServiceApi) {
|
|
236
|
-
var _this$
|
|
285
|
+
var _this$apiConfig6, _this$apiConfig7, api2Url;
|
|
237
286
|
return _regeneratorRuntime.wrap(function _callee2$(_context2) {
|
|
238
287
|
while (1) switch (_context2.prev = _context2.next) {
|
|
239
288
|
case 0:
|
|
@@ -275,8 +324,8 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
275
324
|
_context2.next = 24;
|
|
276
325
|
break;
|
|
277
326
|
case 14:
|
|
278
|
-
api2Url = (_this$
|
|
279
|
-
if (this.getApplicationEnvironment() == 'WEB' && (_this$
|
|
327
|
+
api2Url = (_this$apiConfig6 = this.apiConfig) === null || _this$apiConfig6 === void 0 ? void 0 : _this$apiConfig6.api2["default"];
|
|
328
|
+
if (this.getApplicationEnvironment() == 'WEB' && (_this$apiConfig7 = this.apiConfig) !== null && _this$apiConfig7 !== void 0 && _this$apiConfig7.api2.web) {
|
|
280
329
|
api2Url = this.apiConfig.api2.web;
|
|
281
330
|
}
|
|
282
331
|
_context2.t0 = _objectSpread$q;
|
|
@@ -311,7 +360,7 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
311
360
|
value: function () {
|
|
312
361
|
var _getDataCache = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3(queryString, cacheMD5, accountSessionGuid, useWebServiceApi, method, data, dontLogError) {
|
|
313
362
|
var _this$divaWebConfigDa, _this$divaWebConfigDa2;
|
|
314
|
-
var myQS, url, init, addSession, cacheHit, _this$
|
|
363
|
+
var myQS, url, init, addSession, cacheHit, _this$apiConfig8, _this$apiConfig9, api2Url, resolvedSessionGuid, result, _this$divaWebConfigDa3;
|
|
315
364
|
return _regeneratorRuntime.wrap(function _callee3$(_context3) {
|
|
316
365
|
while (1) switch (_context3.prev = _context3.next) {
|
|
317
366
|
case 0:
|
|
@@ -379,8 +428,8 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
379
428
|
_context3.next = 35;
|
|
380
429
|
break;
|
|
381
430
|
case 25:
|
|
382
|
-
api2Url = (_this$
|
|
383
|
-
if (this.getApplicationEnvironment() == 'WEB' && (_this$
|
|
431
|
+
api2Url = (_this$apiConfig8 = this.apiConfig) === null || _this$apiConfig8 === void 0 ? void 0 : _this$apiConfig8.api2["default"];
|
|
432
|
+
if (this.getApplicationEnvironment() == 'WEB' && (_this$apiConfig9 = this.apiConfig) !== null && _this$apiConfig9 !== void 0 && _this$apiConfig9.api2.web) {
|
|
384
433
|
api2Url = this.apiConfig.api2.web;
|
|
385
434
|
}
|
|
386
435
|
this.apiCallCount += 1;
|
|
@@ -466,6 +515,10 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
466
515
|
}
|
|
467
516
|
return saveAsProduct;
|
|
468
517
|
}()
|
|
518
|
+
/**
|
|
519
|
+
* to run service on localhost
|
|
520
|
+
* diva3dRenderGroup :MYCCMEDIA
|
|
521
|
+
*/
|
|
469
522
|
}, {
|
|
470
523
|
key: "initalizeWebConfigData",
|
|
471
524
|
value: function initalizeWebConfigData(plannerConfig) {
|
|
@@ -540,38 +593,38 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
540
593
|
}, {
|
|
541
594
|
key: "getReportServiceUrl",
|
|
542
595
|
value: function getReportServiceUrl() {
|
|
543
|
-
var _this$apiConfig$repor, _this$
|
|
544
|
-
return (_this$apiConfig$repor = (_this$
|
|
596
|
+
var _this$apiConfig$repor, _this$apiConfig10;
|
|
597
|
+
return (_this$apiConfig$repor = (_this$apiConfig10 = this.apiConfig) === null || _this$apiConfig10 === void 0 ? void 0 : _this$apiConfig10.reportService) !== null && _this$apiConfig$repor !== void 0 ? _this$apiConfig$repor : '';
|
|
545
598
|
}
|
|
546
599
|
}, {
|
|
547
600
|
key: "getDivaSupportServiceUrl",
|
|
548
601
|
value: function getDivaSupportServiceUrl() {
|
|
549
|
-
var _this$apiConfig$suppo, _this$
|
|
550
|
-
return (_this$apiConfig$suppo = (_this$
|
|
602
|
+
var _this$apiConfig$suppo, _this$apiConfig11;
|
|
603
|
+
return (_this$apiConfig$suppo = (_this$apiConfig11 = this.apiConfig) === null || _this$apiConfig11 === void 0 ? void 0 : _this$apiConfig11.supportService) !== null && _this$apiConfig$suppo !== void 0 ? _this$apiConfig$suppo : '';
|
|
551
604
|
}
|
|
552
605
|
}, {
|
|
553
606
|
key: "getDivaMediaServiceUrl",
|
|
554
607
|
value: function getDivaMediaServiceUrl() {
|
|
555
|
-
var _this$apiConfig$media, _this$
|
|
556
|
-
return (_this$apiConfig$media = (_this$
|
|
608
|
+
var _this$apiConfig$media, _this$apiConfig12;
|
|
609
|
+
return (_this$apiConfig$media = (_this$apiConfig12 = this.apiConfig) === null || _this$apiConfig12 === void 0 ? void 0 : _this$apiConfig12.mediaService) !== null && _this$apiConfig$media !== void 0 ? _this$apiConfig$media : '';
|
|
557
610
|
}
|
|
558
611
|
}, {
|
|
559
612
|
key: "getDivaAiServiceUrl",
|
|
560
613
|
value: function getDivaAiServiceUrl() {
|
|
561
|
-
var _this$apiConfig$aiSer, _this$
|
|
562
|
-
return (_this$apiConfig$aiSer = (_this$
|
|
614
|
+
var _this$apiConfig$aiSer, _this$apiConfig13;
|
|
615
|
+
return (_this$apiConfig$aiSer = (_this$apiConfig13 = this.apiConfig) === null || _this$apiConfig13 === void 0 ? void 0 : _this$apiConfig13.aiService) !== null && _this$apiConfig$aiSer !== void 0 ? _this$apiConfig$aiSer : '';
|
|
563
616
|
}
|
|
564
617
|
}, {
|
|
565
618
|
key: "getConstructorServiceUrl",
|
|
566
619
|
value: function getConstructorServiceUrl() {
|
|
567
|
-
var _this$apiConfig$const, _this$
|
|
568
|
-
return (_this$apiConfig$const = (_this$
|
|
620
|
+
var _this$apiConfig$const, _this$apiConfig14;
|
|
621
|
+
return (_this$apiConfig$const = (_this$apiConfig14 = this.apiConfig) === null || _this$apiConfig14 === void 0 ? void 0 : _this$apiConfig14.constructorService) !== null && _this$apiConfig$const !== void 0 ? _this$apiConfig$const : '';
|
|
569
622
|
}
|
|
570
623
|
}, {
|
|
571
624
|
key: "getDivaBasketServiceUrl",
|
|
572
625
|
value: function getDivaBasketServiceUrl() {
|
|
573
|
-
var _this$apiConfig$baske, _this$
|
|
574
|
-
return (_this$apiConfig$baske = (_this$
|
|
626
|
+
var _this$apiConfig$baske, _this$apiConfig15;
|
|
627
|
+
return (_this$apiConfig$baske = (_this$apiConfig15 = this.apiConfig) === null || _this$apiConfig15 === void 0 ? void 0 : _this$apiConfig15.basketService) !== null && _this$apiConfig$baske !== void 0 ? _this$apiConfig$baske : '';
|
|
575
628
|
}
|
|
576
629
|
}, {
|
|
577
630
|
key: "getLoadProductBasketParams",
|
|
@@ -582,8 +635,8 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
582
635
|
}, {
|
|
583
636
|
key: "get3DServerUrl",
|
|
584
637
|
value: function get3DServerUrl() {
|
|
585
|
-
var _this$apiConfig$host, _this$
|
|
586
|
-
return (_this$apiConfig$host = (_this$
|
|
638
|
+
var _this$apiConfig$host, _this$apiConfig16;
|
|
639
|
+
return (_this$apiConfig$host = (_this$apiConfig16 = this.apiConfig) === null || _this$apiConfig16 === void 0 ? void 0 : _this$apiConfig16.host3d) !== null && _this$apiConfig$host !== void 0 ? _this$apiConfig$host : '';
|
|
587
640
|
}
|
|
588
641
|
}, {
|
|
589
642
|
key: "doCheckForProductsPrice",
|
|
@@ -652,9 +705,9 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
652
705
|
}, {
|
|
653
706
|
key: "getBaseUrl",
|
|
654
707
|
value: function getBaseUrl() {
|
|
655
|
-
var _this$
|
|
656
|
-
var url = (_this$
|
|
657
|
-
if (this.getApplicationEnvironment() == 'WEB' && (_this$
|
|
708
|
+
var _this$apiConfig17, _this$apiConfig18;
|
|
709
|
+
var url = (_this$apiConfig17 = this.apiConfig) === null || _this$apiConfig17 === void 0 ? void 0 : _this$apiConfig17.api2["default"];
|
|
710
|
+
if (this.getApplicationEnvironment() == 'WEB' && (_this$apiConfig18 = this.apiConfig) !== null && _this$apiConfig18 !== void 0 && _this$apiConfig18.api2.web) {
|
|
658
711
|
url = this.apiConfig.api2.web;
|
|
659
712
|
}
|
|
660
713
|
if (!url) throw new Error('No API2 defined');
|
|
@@ -770,14 +823,14 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
770
823
|
}, {
|
|
771
824
|
key: "getI18n",
|
|
772
825
|
value: function getI18n() {
|
|
773
|
-
var _this$
|
|
774
|
-
return (_this$
|
|
826
|
+
var _this$i18n2;
|
|
827
|
+
return (_this$i18n2 = this.i18n) === null || _this$i18n2 === void 0 ? void 0 : _this$i18n2.call(this);
|
|
775
828
|
}
|
|
776
829
|
}, {
|
|
777
830
|
key: "setAccountSessionGuid",
|
|
778
831
|
value: function () {
|
|
779
832
|
var _setAccountSessionGuid = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee5(_ref) {
|
|
780
|
-
var os, accountGuid, catalogGuid, response, _this$
|
|
833
|
+
var os, accountGuid, catalogGuid, response, _this$actions4, _this$state$navigatio, _this$state;
|
|
781
834
|
return _regeneratorRuntime.wrap(function _callee5$(_context5) {
|
|
782
835
|
while (1) switch (_context5.prev = _context5.next) {
|
|
783
836
|
case 0:
|
|
@@ -816,7 +869,7 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
816
869
|
break;
|
|
817
870
|
case 16:
|
|
818
871
|
if (this.applicationEnvironment == 'SELLER') {
|
|
819
|
-
(_this$
|
|
872
|
+
(_this$actions4 = this.actions) === null || _this$actions4 === void 0 || _this$actions4.openComponent((_this$state$navigatio = (_this$state = this.state) === null || _this$state === void 0 || (_this$state = _this$state.navigationConfiguration) === null || _this$state === void 0 ? void 0 : _this$state.logoAction) !== null && _this$state$navigatio !== void 0 ? _this$state$navigatio : {
|
|
820
873
|
type: 'SELLER',
|
|
821
874
|
parameters: {
|
|
822
875
|
module: 'Collections'
|
|
@@ -915,39 +968,39 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
915
968
|
}, {
|
|
916
969
|
key: "apiUrl",
|
|
917
970
|
value: function apiUrl(queryString, useWebServiceApi) {
|
|
918
|
-
var _this$
|
|
971
|
+
var _this$apiConfig29, _this$apiConfig30, _this$apiConfig31;
|
|
919
972
|
if (useWebServiceApi == 'catalog') {
|
|
920
|
-
var _this$
|
|
921
|
-
if (!((_this$
|
|
922
|
-
return ((_this$
|
|
973
|
+
var _this$apiConfig19, _this$apiConfig20;
|
|
974
|
+
if (!((_this$apiConfig19 = this.apiConfig) !== null && _this$apiConfig19 !== void 0 && _this$apiConfig19.catalogService)) throw new Error('No catalog Service defined');
|
|
975
|
+
return ((_this$apiConfig20 = this.apiConfig) === null || _this$apiConfig20 === void 0 ? void 0 : _this$apiConfig20.catalogService) + queryString;
|
|
923
976
|
}
|
|
924
977
|
if (useWebServiceApi == 'basket') {
|
|
925
|
-
var _this$
|
|
926
|
-
if (!((_this$
|
|
927
|
-
return ((_this$
|
|
978
|
+
var _this$apiConfig21, _this$apiConfig22;
|
|
979
|
+
if (!((_this$apiConfig21 = this.apiConfig) !== null && _this$apiConfig21 !== void 0 && _this$apiConfig21.basketService)) throw new Error('No basket Service defined');
|
|
980
|
+
return ((_this$apiConfig22 = this.apiConfig) === null || _this$apiConfig22 === void 0 ? void 0 : _this$apiConfig22.basketService) + queryString;
|
|
928
981
|
}
|
|
929
982
|
if (useWebServiceApi == 'report') {
|
|
930
|
-
var _this$
|
|
931
|
-
if (!((_this$
|
|
932
|
-
return ((_this$
|
|
983
|
+
var _this$apiConfig23, _this$apiConfig24;
|
|
984
|
+
if (!((_this$apiConfig23 = this.apiConfig) !== null && _this$apiConfig23 !== void 0 && _this$apiConfig23.reportService)) throw new Error('No report Service defined');
|
|
985
|
+
return ((_this$apiConfig24 = this.apiConfig) === null || _this$apiConfig24 === void 0 ? void 0 : _this$apiConfig24.reportService) + queryString;
|
|
933
986
|
}
|
|
934
987
|
if (useWebServiceApi == 'enricher') {
|
|
935
|
-
var _this$
|
|
988
|
+
var _this$apiConfig27, _this$apiConfig28;
|
|
936
989
|
if (this.useIDMService) {
|
|
937
|
-
var _this$
|
|
938
|
-
if (!((_this$
|
|
939
|
-
return ((_this$
|
|
990
|
+
var _this$apiConfig25, _this$apiConfig26;
|
|
991
|
+
if (!((_this$apiConfig25 = this.apiConfig) !== null && _this$apiConfig25 !== void 0 && _this$apiConfig25.idmService)) throw new Error('No report Service defined');
|
|
992
|
+
return ((_this$apiConfig26 = this.apiConfig) === null || _this$apiConfig26 === void 0 ? void 0 : _this$apiConfig26.idmService) + queryString;
|
|
940
993
|
}
|
|
941
|
-
if (!((_this$
|
|
942
|
-
return ((_this$
|
|
994
|
+
if (!((_this$apiConfig27 = this.apiConfig) !== null && _this$apiConfig27 !== void 0 && _this$apiConfig27.enricherService)) throw new Error('No report Service defined');
|
|
995
|
+
return ((_this$apiConfig28 = this.apiConfig) === null || _this$apiConfig28 === void 0 ? void 0 : _this$apiConfig28.enricherService) + queryString;
|
|
943
996
|
}
|
|
944
|
-
var url = (_this$
|
|
945
|
-
if (this.getApplicationEnvironment() == 'WEB' && (_this$
|
|
997
|
+
var url = (_this$apiConfig29 = this.apiConfig) === null || _this$apiConfig29 === void 0 ? void 0 : _this$apiConfig29.api2["default"];
|
|
998
|
+
if (this.getApplicationEnvironment() == 'WEB' && (_this$apiConfig30 = this.apiConfig) !== null && _this$apiConfig30 !== void 0 && _this$apiConfig30.api2.web) {
|
|
946
999
|
url = this.apiConfig.api2.web;
|
|
947
1000
|
}
|
|
948
|
-
if (this.useEkPrices && (_this$
|
|
949
|
-
var _this$
|
|
950
|
-
url = (_this$
|
|
1001
|
+
if (this.useEkPrices && (_this$apiConfig31 = this.apiConfig) !== null && _this$apiConfig31 !== void 0 && _this$apiConfig31.api2.ek) {
|
|
1002
|
+
var _this$apiConfig32;
|
|
1003
|
+
url = (_this$apiConfig32 = this.apiConfig) === null || _this$apiConfig32 === void 0 ? void 0 : _this$apiConfig32.api2.ek;
|
|
951
1004
|
}
|
|
952
1005
|
if (!url) throw new Error('No API2 defined');
|
|
953
1006
|
return url + '?' + queryString;
|
|
@@ -1139,7 +1192,14 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
1139
1192
|
}, {
|
|
1140
1193
|
key: "getIDMItems",
|
|
1141
1194
|
value: function getIDMItems(packageId, serieId, serieNo, typeNos) {
|
|
1142
|
-
|
|
1195
|
+
var base = this.idmPrefix + (this.isSeller ? '/packages/' : '/catalogs/') + packageId + '/series/' + (this.useIDMService ? serieId : serieNo) + '/items';
|
|
1196
|
+
|
|
1197
|
+
// The seller/configurator endpoint is purpose-built: a dedicated typeNos param instead of a generic filter,
|
|
1198
|
+
// and a fixed field set server-side instead of an explicit fields= list.
|
|
1199
|
+
if (this.isSeller) {
|
|
1200
|
+
return base + (typeNos !== null && typeNos !== void 0 && typeNos.length ? '?typeNos=' + typeNos.join(';') : '');
|
|
1201
|
+
}
|
|
1202
|
+
return base + (typeNos !== null && typeNos !== void 0 && typeNos.length ? '?filter=' + typeNos.map(function (t) {
|
|
1143
1203
|
return encodeURIComponent('typeNo==' + t);
|
|
1144
1204
|
}).join(' || ') : '?fields=properties;serieNo;featureClassRefNo;priceTypeRef;itemIdentification;catalogPage;weightBrutto;weightNetto;volume;minimumDeliveryTime;widthBasicShapeNominalValue;widthBasicShapeFrom;widthBasicShapeTo;widthBasicShapeStepSize;heightBasicShapeNominalValue;heightBasicShapeFrom;heightBasicShapeTo;heightBasicShapeStepSize;depthBasicShapeNominalValue;depthBasicShapeFrom;depthBasicShapeTo;depthBasicShapeStepSize;typeKey;eClassNo;detailInfoRefs;detailInfos;partListExclusive;partListRef;decisionRefs;typeNo;sequenceNo;edpNumber;eanNumber;shortText;fullText;planningAdvice;salesNumber;avrFilter;avlFilter');
|
|
1145
1205
|
}
|
|
@@ -1153,6 +1213,11 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
1153
1213
|
value: function getIDMDecisions(packageId, decisions) {
|
|
1154
1214
|
return this.idmPrefix + (this.isSeller ? '/packages/' : '/catalogs/') + packageId + '/decisions' + '?decisionNos=' + decisions.join(';') + (this.smSupplierNr ? '&supplierNo=' + this.smSupplierNr : '');
|
|
1155
1215
|
}
|
|
1216
|
+
}, {
|
|
1217
|
+
key: "getIDMDecisionsQueryUrl",
|
|
1218
|
+
value: function getIDMDecisionsQueryUrl(packageId) {
|
|
1219
|
+
return this.idmPrefix + (this.isSeller ? '/packages/' : '/catalogs/') + packageId + '/decisions/query' + (this.smSupplierNr ? '?supplierNo=' + this.smSupplierNr : '');
|
|
1220
|
+
}
|
|
1156
1221
|
}, {
|
|
1157
1222
|
key: "getIDMDetailInfos",
|
|
1158
1223
|
value: function getIDMDetailInfos(packageId, detailinfos) {
|
|
@@ -1163,14 +1228,26 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
1163
1228
|
}, {
|
|
1164
1229
|
key: "getIDMFeatureClass",
|
|
1165
1230
|
value: function getIDMFeatureClass(packageId, featureclasses) {
|
|
1166
|
-
|
|
1231
|
+
var base = this.idmPrefix + (this.isSeller ? '/packages/' : '/catalogs/') + packageId + '/featureclasses';
|
|
1232
|
+
|
|
1233
|
+
// The seller/configurator endpoint is purpose-built: a dedicated featureClassNos param instead of a generic filter.
|
|
1234
|
+
if (this.isSeller) {
|
|
1235
|
+
return base + '?featureClassNos=' + featureclasses.join(';');
|
|
1236
|
+
}
|
|
1237
|
+
return base + '?filter=' + featureclasses.map(function (f) {
|
|
1167
1238
|
return encodeURIComponent('featureClassNo==' + f);
|
|
1168
1239
|
}).join(' || ');
|
|
1169
1240
|
}
|
|
1170
1241
|
}, {
|
|
1171
1242
|
key: "getIDMPriceFeatureGroups",
|
|
1172
1243
|
value: function getIDMPriceFeatureGroups(packageId, pricefeaturegroups) {
|
|
1173
|
-
|
|
1244
|
+
var base = this.idmPrefix + (this.isSeller ? '/packages/' : '/catalogs/') + packageId + '/pricefeaturegroups';
|
|
1245
|
+
|
|
1246
|
+
// The seller/configurator endpoint is purpose-built: a dedicated priceFeatureGroupNos param instead of a generic filter.
|
|
1247
|
+
if (this.isSeller) {
|
|
1248
|
+
return base + '?priceFeatureGroupNos=' + pricefeaturegroups.join(';');
|
|
1249
|
+
}
|
|
1250
|
+
return base + '?filter=' + pricefeaturegroups.map(function (p) {
|
|
1174
1251
|
return encodeURIComponent('priceFeatureGroupNo==' + p);
|
|
1175
1252
|
}).join(' || ');
|
|
1176
1253
|
}
|
|
@@ -1494,12 +1571,12 @@ var DivaApiHandler = /*#__PURE__*/function () {
|
|
|
1494
1571
|
key: "getDimensionbyId",
|
|
1495
1572
|
value: function () {
|
|
1496
1573
|
var _getDimensionbyId = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee15(id, iln, catalogCodex, plannedOptions) {
|
|
1497
|
-
var _this$
|
|
1574
|
+
var _this$apiConfig33;
|
|
1498
1575
|
var fullUrl, res, headers;
|
|
1499
1576
|
return _regeneratorRuntime.wrap(function _callee15$(_context15) {
|
|
1500
1577
|
while (1) switch (_context15.prev = _context15.next) {
|
|
1501
1578
|
case 0:
|
|
1502
|
-
fullUrl = this.getConstructorServiceUrl() + '/dimension/' + id + '?iln=' + iln + '&catalogCodex=' + catalogCodex + '&debug=' + ((_this$
|
|
1579
|
+
fullUrl = this.getConstructorServiceUrl() + '/dimension/' + id + '?iln=' + iln + '&catalogCodex=' + catalogCodex + '&debug=' + ((_this$apiConfig33 = this.apiConfig) === null || _this$apiConfig33 === void 0 ? void 0 : _this$apiConfig33.useDebugUrl);
|
|
1503
1580
|
headers = {};
|
|
1504
1581
|
if (this.jwt) headers = {
|
|
1505
1582
|
Authorization: 'Bearer ' + this.jwt
|
|
@@ -16505,6 +16582,11 @@ var OptionValueCatalogData = /*#__PURE__*/function () {
|
|
|
16505
16582
|
get: function get() {
|
|
16506
16583
|
return this.opv.material;
|
|
16507
16584
|
}
|
|
16585
|
+
}, {
|
|
16586
|
+
key: "properties",
|
|
16587
|
+
get: function get() {
|
|
16588
|
+
return this.opv.property;
|
|
16589
|
+
}
|
|
16508
16590
|
}, {
|
|
16509
16591
|
key: "isOPVG",
|
|
16510
16592
|
get: function get() {
|
|
@@ -16666,6 +16748,29 @@ var OptionValueCatalogData = /*#__PURE__*/function () {
|
|
|
16666
16748
|
get: function get() {
|
|
16667
16749
|
return this.opv.hiddenByMask;
|
|
16668
16750
|
}
|
|
16751
|
+
}, {
|
|
16752
|
+
key: "hiddenInFeatureNos",
|
|
16753
|
+
get: function get() {
|
|
16754
|
+
return this.opv.hiddenInFeatureNos;
|
|
16755
|
+
}
|
|
16756
|
+
/**
|
|
16757
|
+
* Whether this option value is hidden specifically within the given feature (OPT).
|
|
16758
|
+
* Used for enricher "eoption" exclusions that hide an option value in a single feature only,
|
|
16759
|
+
* without affecting the same option value where it appears in other features.
|
|
16760
|
+
*/
|
|
16761
|
+
}, {
|
|
16762
|
+
key: "isHiddenInFeature",
|
|
16763
|
+
value: function isHiddenInFeature(optCodex) {
|
|
16764
|
+
var featureNos = this.opv.hiddenInFeatureNos;
|
|
16765
|
+
if (!(featureNos !== null && featureNos !== void 0 && featureNos.length)) return false;
|
|
16766
|
+
var strip = function strip(codex) {
|
|
16767
|
+
return codex.startsWith('OPT') ? codex.substring(3) : codex;
|
|
16768
|
+
};
|
|
16769
|
+
var target = strip(optCodex);
|
|
16770
|
+
return featureNos.some(function (featureNo) {
|
|
16771
|
+
return strip(featureNo) === target;
|
|
16772
|
+
});
|
|
16773
|
+
}
|
|
16669
16774
|
}, {
|
|
16670
16775
|
key: "setName",
|
|
16671
16776
|
get: function get() {
|
|
@@ -16871,6 +16976,9 @@ var CatalogArticleData = /*#__PURE__*/function () {
|
|
|
16871
16976
|
case 'ACCESSOIRE_POS_PRIO':
|
|
16872
16977
|
this._catalogArticle.accPosPrio = Number(prop.Value);
|
|
16873
16978
|
break;
|
|
16979
|
+
case 'ADD_AS_ZKAT':
|
|
16980
|
+
this._catalogArticle.addAsZKAT = prop.Value === 'true' || prop.Value === '1';
|
|
16981
|
+
break;
|
|
16874
16982
|
case 'HEIGHTGRIDUSED':
|
|
16875
16983
|
this._catalogArticle.heightGridUsed = Number(prop.Value);
|
|
16876
16984
|
break;
|
|
@@ -16943,6 +17051,12 @@ var CatalogArticleData = /*#__PURE__*/function () {
|
|
|
16943
17051
|
case 'OPTIONS_FOR_PRINT':
|
|
16944
17052
|
this.catalogArticle.optionsForPrint = prop.Value.split(';');
|
|
16945
17053
|
break;
|
|
17054
|
+
case 'TABGROUP':
|
|
17055
|
+
if (!this._catalogArticle.tabGroup) this._catalogArticle.tabGroup = prop.Value;
|
|
17056
|
+
break;
|
|
17057
|
+
case 'TABGROUP_OPTIONS':
|
|
17058
|
+
if (!this._catalogArticle.tabGroupOption) this._catalogArticle.tabGroupOption = prop.Value;
|
|
17059
|
+
break;
|
|
16946
17060
|
default:
|
|
16947
17061
|
if (_key.includes('__')) break;
|
|
16948
17062
|
var values = prop.Value.split(';');
|
|
@@ -17332,6 +17446,11 @@ var CatalogArticleData = /*#__PURE__*/function () {
|
|
|
17332
17446
|
get: function get() {
|
|
17333
17447
|
return this._catalogArticle.accPosPrio;
|
|
17334
17448
|
}
|
|
17449
|
+
}, {
|
|
17450
|
+
key: "addAsZKAT",
|
|
17451
|
+
get: function get() {
|
|
17452
|
+
return this._catalogArticle.addAsZKAT;
|
|
17453
|
+
}
|
|
17335
17454
|
}, {
|
|
17336
17455
|
key: "overwriteParentWidth",
|
|
17337
17456
|
get: function get() {
|
|
@@ -17913,7 +18032,7 @@ function initCatalogOptionValues(catalogData, jsonOptions) {
|
|
|
17913
18032
|
return optionValues;
|
|
17914
18033
|
}
|
|
17915
18034
|
function getCatalogOptionValueDataType(codex, jsonOPV, catalogData) {
|
|
17916
|
-
var _catalogData$catalogM9, _catalogData$catalogM10, _catalogData$catalogM11, _optionvalues$codex, _catalogData$catalogM12, _catalogData$catalogM13, _jsonOPV$Metadatas, _mask$name$catalogDat, _mask$name, _mask$name2, _mask$groupname$catal, _mask$groupname, _mask$groupname2, _jsonOPV$MeasureStep, _jsonOPV$Value;
|
|
18035
|
+
var _catalogData$catalogM9, _catalogData$catalogM10, _catalogData$catalogM11, _optionvalues$codex, _catalogData$catalogM12, _catalogData$catalogM13, _jsonOPV$Metadatas, _mask$name$catalogDat, _mask$name, _mask$name2, _mask$groupname$catal, _mask$groupname, _mask$groupname2, _mask$hiddenInFeature, _jsonOPV$MeasureStep, _jsonOPV$Value;
|
|
17917
18036
|
var optionvalues = (_catalogData$catalogM9 = (_catalogData$catalogM10 = catalogData.catalogMask) === null || _catalogData$catalogM10 === void 0 ? void 0 : _catalogData$catalogM10.optionvalues) !== null && _catalogData$catalogM9 !== void 0 ? _catalogData$catalogM9 : (_catalogData$catalogM11 = catalogData.catalogMask) === null || _catalogData$catalogM11 === void 0 ? void 0 : _catalogData$catalogM11.optionValues;
|
|
17918
18037
|
var mask = (_optionvalues$codex = optionvalues === null || optionvalues === void 0 ? void 0 : optionvalues[codex]) !== null && _optionvalues$codex !== void 0 ? _optionvalues$codex : codex.startsWith('OPV') ? optionvalues === null || optionvalues === void 0 ? void 0 : optionvalues[codex.substring(3)] : undefined;
|
|
17919
18038
|
var maskProperties = getPropertiesForOptionKey((_catalogData$catalogM12 = (_catalogData$catalogM13 = catalogData.catalogMask) === null || _catalogData$catalogM13 === void 0 ? void 0 : _catalogData$catalogM13.properties) !== null && _catalogData$catalogM12 !== void 0 ? _catalogData$catalogM12 : [], undefined, codex, catalogData.api.getLanguage());
|
|
@@ -17932,7 +18051,8 @@ function getCatalogOptionValueDataType(codex, jsonOPV, catalogData) {
|
|
|
17932
18051
|
groupName: (_mask$groupname$catal = mask === null || mask === void 0 || (_mask$groupname = mask.groupname) === null || _mask$groupname === void 0 ? void 0 : _mask$groupname[catalogData.api.getLanguage()]) !== null && _mask$groupname$catal !== void 0 ? _mask$groupname$catal : jsonOPV.GroupName && jsonOPV.GroupName != '' ? jsonOPV.GroupName : undefined,
|
|
17933
18052
|
origGroupName: jsonOPV.GroupName && jsonOPV.GroupName != '' ? jsonOPV.GroupName : undefined,
|
|
17934
18053
|
groupName_locales: (_mask$groupname2 = mask === null || mask === void 0 ? void 0 : mask.groupname) !== null && _mask$groupname2 !== void 0 ? _mask$groupname2 : jsonOPV.GroupName_locales,
|
|
17935
|
-
hiddenByMask: mask === null || mask === void 0 ? void 0 : mask.hidden,
|
|
18054
|
+
hiddenByMask: (mask === null || mask === void 0 ? void 0 : mask.hidden) && !(mask !== null && mask !== void 0 && (_mask$hiddenInFeature = mask.hiddenInFeatureNos) !== null && _mask$hiddenInFeature !== void 0 && _mask$hiddenInFeature.length),
|
|
18055
|
+
hiddenInFeatureNos: mask !== null && mask !== void 0 && mask.hidden ? mask === null || mask === void 0 ? void 0 : mask.hiddenInFeatureNos : undefined,
|
|
17936
18056
|
textureName: jsonOPV.TextureName && jsonOPV.TextureName != '' ? jsonOPV.TextureName : jsonOPV.PFTFile && jsonOPV.PFTFile != '' ? jsonOPV.PFTFile : undefined,
|
|
17937
18057
|
material: jsonOPV.Material && jsonOPV.Material != '' ? jsonOPV.Material : undefined,
|
|
17938
18058
|
isOPVG: jsonOPV.IsOPVG && jsonOPV.IsOPVG == '1' ? true : false,
|
|
@@ -17979,18 +18099,18 @@ function getCatalogOptionValueDataType(codex, jsonOPV, catalogData) {
|
|
|
17979
18099
|
}
|
|
17980
18100
|
function initCatalogPlannerArticleView$1(catalogData, catPlanArticle, catalogProps, plannerPaletteViewInfo) {
|
|
17981
18101
|
//Hier muss es dann reingespeichert werden catalogPlannerArticlesView;
|
|
17982
|
-
var getFilterType = function getFilterType(hasArticleRelation,
|
|
18102
|
+
var getFilterType = function getFilterType(hasArticleRelation, hasAVL, hasAVR, catalogProps) {
|
|
17983
18103
|
var ret;
|
|
17984
18104
|
if (hasArticleRelation) {
|
|
17985
18105
|
if (!catalogProps.showAllItemsInPlanner && !catalogProps.showAccOnDpOnly) plannerPaletteViewInfo.filterType['Accessoire'] = true;
|
|
17986
18106
|
ret = 'Accessoire';
|
|
17987
|
-
} else if (
|
|
18107
|
+
} else if (hasAVL && hasAVR) {
|
|
17988
18108
|
if (!catalogProps.showAllItemsInPlanner) plannerPaletteViewInfo.filterType['DockLR'] = true;
|
|
17989
18109
|
ret = 'DockLR';
|
|
17990
|
-
} else if (
|
|
18110
|
+
} else if (hasAVL) {
|
|
17991
18111
|
if (!catalogProps.showAllItemsInPlanner) plannerPaletteViewInfo.filterType['DockR'] = true;
|
|
17992
18112
|
ret = 'DockR';
|
|
17993
|
-
} else if (
|
|
18113
|
+
} else if (hasAVR) {
|
|
17994
18114
|
if (!catalogProps.showAllItemsInPlanner) plannerPaletteViewInfo.filterType['DockL'] = true;
|
|
17995
18115
|
ret = 'DockL';
|
|
17996
18116
|
} else {
|
|
@@ -18084,12 +18204,9 @@ function initCatalogPlannerArticleView$1(catalogData, catPlanArticle, catalogPro
|
|
|
18084
18204
|
if (catalogProps.diva3dPlanerShowArticleAsSvg && topSvg.SVG) {
|
|
18085
18205
|
image = getSVGUrl(topSvg.SVG, mediaUrl);
|
|
18086
18206
|
}
|
|
18087
|
-
|
|
18088
|
-
|
|
18089
|
-
|
|
18090
|
-
if (topSvg.HasAVR && catPlanArticle.avrFilter.length == 0) {
|
|
18091
|
-
catPlanArticle.avrFilter = ['ALWAYS_DOCKABLE'];
|
|
18092
|
-
}
|
|
18207
|
+
|
|
18208
|
+
// An empty AVL/AVR filter means "no connector restriction" and is treated as a match by the
|
|
18209
|
+
// docking/palette comparison (see checkDPFilterDoMatch / checkDPAV*FilterDoMatch). No sentinel needed.
|
|
18093
18210
|
|
|
18094
18211
|
//Wäre für Rofl Benz gedacht um die Information zu speichern welche Artikel in welcher Ausrichtung ausmultipliziert werden
|
|
18095
18212
|
if (topSvg.JsFormula.includes('202_LI')) {
|
|
@@ -18097,7 +18214,7 @@ function initCatalogPlannerArticleView$1(catalogData, catPlanArticle, catalogPro
|
|
|
18097
18214
|
} else if (topSvg.JsFormula.includes('202_RE')) {
|
|
18098
18215
|
elementName = elementName + ' (Rechts)';
|
|
18099
18216
|
}
|
|
18100
|
-
var filterType = getFilterType(catPlanArticle.isArticleRelation, topSvg.HasAVL
|
|
18217
|
+
var filterType = getFilterType(catPlanArticle.isArticleRelation, !!topSvg.HasAVL, !!topSvg.HasAVR, catalogProps);
|
|
18101
18218
|
catPlanArticle.filterType = filterType;
|
|
18102
18219
|
//ausmultiplizierte Elemente (über meherere SVGs)
|
|
18103
18220
|
var catPlanArtView = {
|
|
@@ -18150,7 +18267,7 @@ function initCatalogPlannerArticleView$1(catalogData, catPlanArticle, catalogPro
|
|
|
18150
18267
|
}
|
|
18151
18268
|
if (!catPlanArticle.hasTopSvgsWithFormula || catPlanArticle.topSvgsWithFormula.length == 1) {
|
|
18152
18269
|
var _catalogArticle$artic2;
|
|
18153
|
-
var _filterType = getFilterType(catPlanArticle.isArticleRelation, catPlanArticle.topHasAVL
|
|
18270
|
+
var _filterType = getFilterType(catPlanArticle.isArticleRelation, !!catPlanArticle.topHasAVL, !!catPlanArticle.topHasAVR, catalogProps);
|
|
18154
18271
|
catPlanArticle.filterType = _filterType;
|
|
18155
18272
|
//Artikelbild ist abh�ngig von DIVA3DPlanerShowArticleAsSvg das SVG des Elements
|
|
18156
18273
|
if (catalogProps.diva3dPlanerShowArticleAsSvg && (catPlanArticle.hasTopSvg || catPlanArticle.hasTopSvgsWithFormula)) {
|
|
@@ -18588,6 +18705,11 @@ var ArticleOptionValueData = /*#__PURE__*/function () {
|
|
|
18588
18705
|
get: function get() {
|
|
18589
18706
|
return this.opv.catalogOPV.value;
|
|
18590
18707
|
}
|
|
18708
|
+
}, {
|
|
18709
|
+
key: "properties",
|
|
18710
|
+
get: function get() {
|
|
18711
|
+
return this.opv.catalogOPV.properties;
|
|
18712
|
+
}
|
|
18591
18713
|
}, {
|
|
18592
18714
|
key: "metaData",
|
|
18593
18715
|
get: function get() {
|
|
@@ -18677,6 +18799,11 @@ var ArticleOptionValueData = /*#__PURE__*/function () {
|
|
|
18677
18799
|
get: function get() {
|
|
18678
18800
|
return this.opv.catalogOPV.hiddenByMask;
|
|
18679
18801
|
}
|
|
18802
|
+
}, {
|
|
18803
|
+
key: "isHiddenInFeature",
|
|
18804
|
+
value: function isHiddenInFeature(optCodex) {
|
|
18805
|
+
return this.opv.catalogOPV.isHiddenInFeature(optCodex);
|
|
18806
|
+
}
|
|
18680
18807
|
}, {
|
|
18681
18808
|
key: "isPIMFlatValue",
|
|
18682
18809
|
get: function get() {
|
|
@@ -19693,7 +19820,15 @@ function _loadMoreFromIDMArticles() {
|
|
|
19693
19820
|
}).map(function (a) {
|
|
19694
19821
|
return a.featureClassRefNo;
|
|
19695
19822
|
})));
|
|
19696
|
-
promises = [set.api.getDataCache(set.api.getIDMFeatureClass(set.CatalogData.accountGuid, toLoadFeatureClassRefNo), undefined, undefined, 'enricher'), toLoadPFGroups.length ? set.api.getDataCache(set.api.getIDMPriceFeatureGroups(set.CatalogData.accountGuid, toLoadPFGroups), undefined, undefined, 'enricher') : undefined, toLoadDecisionIds.length ?
|
|
19823
|
+
promises = [set.api.getDataCache(set.api.getIDMFeatureClass(set.CatalogData.accountGuid, toLoadFeatureClassRefNo), undefined, undefined, 'enricher'), toLoadPFGroups.length ? set.api.getDataCache(set.api.getIDMPriceFeatureGroups(set.CatalogData.accountGuid, toLoadPFGroups), undefined, undefined, 'enricher') : undefined, toLoadDecisionIds.length ? function () {
|
|
19824
|
+
var getUrl = set.api.getIDMDecisions(set.CatalogData.accountGuid, toLoadDecisionIds);
|
|
19825
|
+
if (getUrl.length > 2000) {
|
|
19826
|
+
return set.api.getDataCache(set.api.getIDMDecisionsQueryUrl(set.CatalogData.accountGuid), undefined, undefined, 'enricher', 'POST', {
|
|
19827
|
+
decisionNos: toLoadDecisionIds.join(';')
|
|
19828
|
+
});
|
|
19829
|
+
}
|
|
19830
|
+
return set.api.getDataCache(getUrl, undefined, undefined, 'enricher');
|
|
19831
|
+
}() : undefined];
|
|
19697
19832
|
_context5.next = 16;
|
|
19698
19833
|
return Promise.all(promises);
|
|
19699
19834
|
case 16:
|
|
@@ -19728,7 +19863,7 @@ function _loadMoreFromIDMArticles() {
|
|
|
19728
19863
|
catalogArticleData = catalogArticleDatas[_i6];
|
|
19729
19864
|
catalogArticleData.articleIDMDecisions = sortDecisions(set.CatalogData.getDecisionsByNo(_toConsumableArray(new Set([].concat(_toConsumableArray(set.CatalogData.globalDecisions.map(function (g) {
|
|
19730
19865
|
return g.decisionNo;
|
|
19731
|
-
})), _toConsumableArray((_catalogArticleData$d2 = catalogArticleData.decisionsRefs) !== null && _catalogArticleData$d2 !== void 0 ? _catalogArticleData$d2 : []))))));
|
|
19866
|
+
})), _toConsumableArray(set.CatalogData.serieDecisionRefs), _toConsumableArray((_catalogArticleData$d2 = catalogArticleData.decisionsRefs) !== null && _catalogArticleData$d2 !== void 0 ? _catalogArticleData$d2 : []))))));
|
|
19732
19867
|
}
|
|
19733
19868
|
featureClasses.map(function (fc) {
|
|
19734
19869
|
return set.CatalogData.loadedFeatureClasses.push(fc);
|
|
@@ -19897,7 +20032,7 @@ var getToLoadDecisionIds = function getToLoadDecisionIds(catalogArticleDatas, se
|
|
|
19897
20032
|
}
|
|
19898
20033
|
var neededDecisionsIds = _toConsumableArray(new Set([].concat(_toConsumableArray(set.CatalogData.globalDecisions.map(function (g) {
|
|
19899
20034
|
return g.decisionNo;
|
|
19900
|
-
})), _toConsumableArray(allArticleDecisions))));
|
|
20035
|
+
})), _toConsumableArray(set.CatalogData.serieDecisionRefs), _toConsumableArray(allArticleDecisions))));
|
|
19901
20036
|
var toLoadDecisionIds = [];
|
|
19902
20037
|
for (var _i = 0; _i < neededDecisionsIds.length; _i++) {
|
|
19903
20038
|
var found = set.CatalogData.getDecisionByNo(neededDecisionsIds[_i]);
|
|
@@ -19960,15 +20095,14 @@ var getPriceFeatureGroups = function getPriceFeatureGroups(catalogArticleDatas,
|
|
|
19960
20095
|
};
|
|
19961
20096
|
var initializeDecision = function initializeDecision(decision, idmOptionGroups) {
|
|
19962
20097
|
var _decision$optionCombi;
|
|
20098
|
+
// optionCombinations already arrive sorted by sequence from the backend.
|
|
19963
20099
|
var optionCombinations = (_decision$optionCombi = decision.optionCombinations) === null || _decision$optionCombi === void 0 ? void 0 : _decision$optionCombi.map(function (c) {
|
|
19964
20100
|
return _objectSpread$p(_objectSpread$p({}, c), {}, {
|
|
19965
20101
|
projectOptionsSetRefs: parseOptionSetRef(c.projectOptionsSetRefs, idmOptionGroups)
|
|
19966
20102
|
});
|
|
19967
20103
|
});
|
|
19968
20104
|
return _objectSpread$p(_objectSpread$p({}, decision), {}, {
|
|
19969
|
-
optionCombinations: optionCombinations
|
|
19970
|
-
return a.sequence - b.sequence;
|
|
19971
|
-
})
|
|
20105
|
+
optionCombinations: optionCombinations
|
|
19972
20106
|
});
|
|
19973
20107
|
};
|
|
19974
20108
|
var initializePriceFeatureGroups = function initializePriceFeatureGroups(priceFeatureGroup, idmOptionGroups) {
|
|
@@ -20067,7 +20201,7 @@ var initFeature = function initFeature(feature, catalogArticleData, set) {
|
|
|
20067
20201
|
catalogArticleData.articleOptions[newArticleFeature.codex] = newArticleFeature;
|
|
20068
20202
|
};
|
|
20069
20203
|
function getCatalogFeatureType(feature, catalogArticleData, set) {
|
|
20070
|
-
var _set$CatalogData$cata, _set$CatalogData$cata2, _set$CatalogData$cata3, _feature$detailInfos,
|
|
20204
|
+
var _set$CatalogData$cata, _set$CatalogData$cata2, _set$CatalogData$cata3, _feature$detailInfos, _optionMask$hidden;
|
|
20071
20205
|
var featureClass = set.CatalogData.getFeatureClass(catalogArticleData.featureClassRefNo);
|
|
20072
20206
|
var optionMask = (_set$CatalogData$cata = set.CatalogData.catalogMask) === null || _set$CatalogData$cata === void 0 || (_set$CatalogData$cata = _set$CatalogData$cata.options) === null || _set$CatalogData$cata === void 0 ? void 0 : _set$CatalogData$cata[feature.featureNo];
|
|
20073
20207
|
var maskProperties = getPropertiesForFeatureNo((_set$CatalogData$cata2 = (_set$CatalogData$cata3 = set.CatalogData.catalogMask) === null || _set$CatalogData$cata3 === void 0 ? void 0 : _set$CatalogData$cata3.properties) !== null && _set$CatalogData$cata2 !== void 0 ? _set$CatalogData$cata2 : [], undefined, feature.featureNo, set.CatalogData.api.getLanguage());
|
|
@@ -20084,17 +20218,9 @@ function getCatalogFeatureType(feature, catalogArticleData, set) {
|
|
|
20084
20218
|
headerPosVariationType: feature.headerPosVariationType,
|
|
20085
20219
|
measureKey: feature.measureParameter,
|
|
20086
20220
|
sequenceNo: feature.sequenceNo,
|
|
20087
|
-
sendToPIM:
|
|
20088
|
-
|
|
20089
|
-
|
|
20090
|
-
isMultiselect: !!(properties !== null && properties !== void 0 && (_properties$find2 = properties.find(function (p) {
|
|
20091
|
-
return p.Codex == 'Multiselect';
|
|
20092
|
-
})) !== null && _properties$find2 !== void 0 && _properties$find2.Value),
|
|
20093
|
-
layout: (_ref = properties === null || properties === void 0 || (_properties$find3 = properties.find(function (p) {
|
|
20094
|
-
return p.Codex == 'LAYOUT';
|
|
20095
|
-
})) === null || _properties$find3 === void 0 ? void 0 : _properties$find3.Value) !== null && _ref !== void 0 ? _ref : (_feature$options$ = feature.options[0]) !== null && _feature$options$ !== void 0 && (_feature$options$ = _feature$options$.detailInfos) !== null && _feature$options$ !== void 0 && _feature$options$.find(function (d) {
|
|
20096
|
-
return d.functionType == 'OPV';
|
|
20097
|
-
}) ? 'IMAGE' : 'TEXT',
|
|
20221
|
+
sendToPIM: feature.sendToPim,
|
|
20222
|
+
isMultiselect: feature.isMultiselect,
|
|
20223
|
+
layout: feature.layout,
|
|
20098
20224
|
invisible: (_optionMask$hidden = optionMask === null || optionMask === void 0 ? void 0 : optionMask.hidden) !== null && _optionMask$hidden !== void 0 ? _optionMask$hidden : !!(featureClass !== null && featureClass !== void 0 && featureClass.featureRefs[feature.featureNo]),
|
|
20099
20225
|
property: properties,
|
|
20100
20226
|
propertyObj: {}
|
|
@@ -20158,12 +20284,9 @@ function getCatalogOptionType(option, set) {
|
|
|
20158
20284
|
origName: name,
|
|
20159
20285
|
name_locales: option.optionText,
|
|
20160
20286
|
property: properties,
|
|
20161
|
-
|
|
20162
|
-
|
|
20163
|
-
|
|
20164
|
-
images: (_option$detailInfos2 = option.detailInfos) === null || _option$detailInfos2 === void 0 || (_option$detailInfos2 = _option$detailInfos2.filter(function (d) {
|
|
20165
|
-
return d.functionType == 'OPV';
|
|
20166
|
-
})) === null || _option$detailInfos2 === void 0 ? void 0 : _option$detailInfos2.map(function (o) {
|
|
20287
|
+
// detailInfos is already limited to "OPV" entries by the backend.
|
|
20288
|
+
image: getLowResUrl((_option$detailInfos = option.detailInfos) === null || _option$detailInfos === void 0 || (_option$detailInfos = _option$detailInfos[0]) === null || _option$detailInfos === void 0 ? void 0 : _option$detailInfos.url),
|
|
20289
|
+
images: (_option$detailInfos2 = option.detailInfos) === null || _option$detailInfos2 === void 0 ? void 0 : _option$detailInfos2.map(function (o) {
|
|
20167
20290
|
var _getLowResUrl, _option$detailInfoRef, _option$detailInfoRef2;
|
|
20168
20291
|
return {
|
|
20169
20292
|
detailInfoNo: o.detailInfoNo,
|
|
@@ -20173,7 +20296,7 @@ function getCatalogOptionType(option, set) {
|
|
|
20173
20296
|
})) !== null && _option$detailInfoRef !== void 0 ? _option$detailInfoRef : []
|
|
20174
20297
|
};
|
|
20175
20298
|
}),
|
|
20176
|
-
hexColor:
|
|
20299
|
+
hexColor: option.materialColorHex,
|
|
20177
20300
|
description: DivaUtils.getLocals(option.optionCommentText, set.api.getLanguageLowercase()),
|
|
20178
20301
|
description_locales: option.optionCommentText,
|
|
20179
20302
|
isTexture: false,
|
|
@@ -20244,20 +20367,12 @@ function getArticleOption(set, option, catalogOption, feature, catalogArticleDat
|
|
|
20244
20367
|
};
|
|
20245
20368
|
return opv;
|
|
20246
20369
|
}
|
|
20247
|
-
function componentToHex(c) {
|
|
20248
|
-
var hex = c.toString(16);
|
|
20249
|
-
return hex.length == 1 ? '0' + hex : hex;
|
|
20250
|
-
}
|
|
20251
|
-
function rgbToHex(r, g, b) {
|
|
20252
|
-
if (r === undefined || g === undefined || b === undefined) return undefined;
|
|
20253
|
-
return '#' + componentToHex(r) + componentToHex(g) + componentToHex(b);
|
|
20254
|
-
}
|
|
20255
20370
|
|
|
20256
20371
|
function ownKeys$o(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
20257
20372
|
function _objectSpread$o(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$o(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$o(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
20258
20373
|
var LOG$k = DivaUtils.initLog('Planner', 'WEB-PLANNER-LOGIC');
|
|
20259
20374
|
function initIDMCatalogData(serie, orderSet, api) {
|
|
20260
|
-
var _serie$decisions, _serie$decisions2;
|
|
20375
|
+
var _serie$decisions, _serie$decisions2, _serie$decisionRefs;
|
|
20261
20376
|
var catalog = serie.catalogData;
|
|
20262
20377
|
var catalogData = {
|
|
20263
20378
|
accountGuid: orderSet.AccountGUID,
|
|
@@ -20283,6 +20398,7 @@ function initIDMCatalogData(serie, orderSet, api) {
|
|
|
20283
20398
|
loadedDecisions: _toConsumableArray(((_serie$decisions2 = serie.decisions) !== null && _serie$decisions2 !== void 0 ? _serie$decisions2 : []).map(function (d) {
|
|
20284
20399
|
return initializeDecision(d, catalog.optionGroups);
|
|
20285
20400
|
})),
|
|
20401
|
+
serieDecisionRefs: (_serie$decisionRefs = serie.decisionRefs) !== null && _serie$decisionRefs !== void 0 ? _serie$decisionRefs : [],
|
|
20286
20402
|
//TODO zu klären mit Philipp
|
|
20287
20403
|
//brandName: '',
|
|
20288
20404
|
//additionalCatalogPrice: json.AdditionalCatalogPrice,
|
|
@@ -20322,9 +20438,12 @@ function initIDMArticles(jsonItems, catalogData) {
|
|
|
20322
20438
|
}
|
|
20323
20439
|
}
|
|
20324
20440
|
function getCatalogArticle(article, catalogData) {
|
|
20325
|
-
var _catalogData$catalogM, _article$typeKey, _article$salesNumber,
|
|
20441
|
+
var _catalogData$catalogM, _article$typeKey, _article$salesNumber, _articleMask$name, _articleMask$properti, _article$depthBasicSh, _article$depthBasicSh2, _article$depthBasicSh3, _article$widthBasicSh, _article$widthBasicSh2, _article$widthBasicSh3, _article$heightBasicS, _article$heightBasicS2, _article$heightBasicS3, _article$weightNetto, _article$detailInfos, _article$detailInfos2, _article$detailInfos3, _articleMask$groupnam, _articleMask$groupnam2;
|
|
20326
20442
|
var articleMask = (_catalogData$catalogM = catalogData.catalogMask) === null || _catalogData$catalogM === void 0 || (_catalogData$catalogM = _catalogData$catalogM.articles) === null || _catalogData$catalogM === void 0 ? void 0 : _catalogData$catalogM[article.typeNo];
|
|
20327
20443
|
var lang = catalogData.api.getLanguageLowercase();
|
|
20444
|
+
// empty locale objects ({} or only empty strings) are truthy, so ?? alone doesn't fall back
|
|
20445
|
+
var fullText = hasLocaleText(article.fullText) ? article.fullText : article.shortText;
|
|
20446
|
+
var shortText = hasLocaleText(article.shortText) ? article.shortText : article.fullText;
|
|
20328
20447
|
var featureProperties = convertProperties(article.properties, lang, 'featureNos');
|
|
20329
20448
|
var optionProperties = convertProperties(article.properties, lang, 'optionKeys');
|
|
20330
20449
|
return {
|
|
@@ -20347,14 +20466,14 @@ function getCatalogArticle(article, catalogData) {
|
|
|
20347
20466
|
hasArticleRelations: false,
|
|
20348
20467
|
hasPartlistArticle: !!article.partListRef,
|
|
20349
20468
|
hasType1Dependencies: false,
|
|
20350
|
-
name: DivaUtils.getLocals((
|
|
20351
|
-
longDescription: DivaUtils.getLocals(
|
|
20352
|
-
longDescription_locales:
|
|
20469
|
+
name: DivaUtils.getLocals((_articleMask$name = articleMask === null || articleMask === void 0 ? void 0 : articleMask.name) !== null && _articleMask$name !== void 0 ? _articleMask$name : fullText, lang),
|
|
20470
|
+
longDescription: DivaUtils.getLocals(fullText, lang),
|
|
20471
|
+
longDescription_locales: fullText,
|
|
20353
20472
|
isHidden: !!(articleMask !== null && articleMask !== void 0 && articleMask.hidden),
|
|
20354
|
-
origName: DivaUtils.getLocals(
|
|
20355
|
-
shortName: DivaUtils.getLocals(
|
|
20356
|
-
origShortName: DivaUtils.getLocals(
|
|
20357
|
-
shortName_locales:
|
|
20473
|
+
origName: DivaUtils.getLocals(fullText, lang),
|
|
20474
|
+
shortName: DivaUtils.getLocals(shortText, lang),
|
|
20475
|
+
origShortName: DivaUtils.getLocals(shortText, lang),
|
|
20476
|
+
shortName_locales: shortText,
|
|
20358
20477
|
properties: [].concat(_toConsumableArray(convertProperties(article.properties, lang)), _toConsumableArray((_articleMask$properti = articleMask === null || articleMask === void 0 ? void 0 : articleMask.properties) !== null && _articleMask$properti !== void 0 ? _articleMask$properti : [])),
|
|
20359
20478
|
optionProperties: optionProperties,
|
|
20360
20479
|
featureProperties: featureProperties,
|
|
@@ -20414,6 +20533,11 @@ function getCatalogArticle(article, catalogData) {
|
|
|
20414
20533
|
modelName3D: jsonArticle.ModelName3D && jsonArticle.ModelName3D != '' ? jsonArticle.ModelName3D : undefined,
|
|
20415
20534
|
*/
|
|
20416
20535
|
|
|
20536
|
+
function hasLocaleText(locales) {
|
|
20537
|
+
return !!locales && Object.values(locales).some(function (v) {
|
|
20538
|
+
return !!(v !== null && v !== void 0 && v.trim());
|
|
20539
|
+
});
|
|
20540
|
+
}
|
|
20417
20541
|
function getLowResUrl(url) {
|
|
20418
20542
|
return url === null || url === void 0 ? void 0 : url.replace('.jpg', '_low.jpg').replace('.jpeg', '_low.jpeg').replace('.png', '_low.png');
|
|
20419
20543
|
}
|
|
@@ -20654,6 +20778,8 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
20654
20778
|
//
|
|
20655
20779
|
ignoreLayerAVNAVS: false,
|
|
20656
20780
|
//
|
|
20781
|
+
ignoreDockingNumber: false,
|
|
20782
|
+
// ignoriert die Nummern-Regel beim Andocken (z.B. AVU1 darf an AVO2). Die Nummer dient dann nur der Identifikation, nicht als Zuordnungsschlüssel.
|
|
20657
20783
|
checkCollisionForDifferentLayers: [],
|
|
20658
20784
|
//
|
|
20659
20785
|
|
|
@@ -20706,6 +20832,9 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
20706
20832
|
// ergänzt einen Übersetzbaren string am Ende des Names
|
|
20707
20833
|
dontShowAccStep: false,
|
|
20708
20834
|
useTypeNrAsArticleNrEKText: false,
|
|
20835
|
+
hideSubPosArticleCodexEKText: false,
|
|
20836
|
+
addPosInvisibilityToOL: false,
|
|
20837
|
+
// PosInvisibility wird nur in die Orderlines übernommen wenn der MetaTag ADD_POS_INVISIBILITY_TO_OL == 1 ist
|
|
20709
20838
|
addNewLineBeforRuleDesc: false,
|
|
20710
20839
|
// für Kirchner neue zeile im Checkout vor der Klanner und der RuleCes von den Partlistarticles
|
|
20711
20840
|
useEdoArticlesOnOpvs: [],
|
|
@@ -20953,6 +21082,12 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
20953
21082
|
get: function get() {
|
|
20954
21083
|
return this.catalogData.globalDecisions;
|
|
20955
21084
|
}
|
|
21085
|
+
}, {
|
|
21086
|
+
key: "serieDecisionRefs",
|
|
21087
|
+
get: function get() {
|
|
21088
|
+
var _this$catalogData$ser;
|
|
21089
|
+
return (_this$catalogData$ser = this.catalogData.serieDecisionRefs) !== null && _this$catalogData$ser !== void 0 ? _this$catalogData$ser : [];
|
|
21090
|
+
}
|
|
20956
21091
|
}, {
|
|
20957
21092
|
key: "loadedFeatureClasses",
|
|
20958
21093
|
get: function get() {
|
|
@@ -21415,6 +21550,11 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
21415
21550
|
get: function get() {
|
|
21416
21551
|
return this.catalogProps.useTypeNrAsArticleNrEKText;
|
|
21417
21552
|
}
|
|
21553
|
+
}, {
|
|
21554
|
+
key: "hideSubPosArticleCodexEKText",
|
|
21555
|
+
get: function get() {
|
|
21556
|
+
return this.catalogProps.hideSubPosArticleCodexEKText;
|
|
21557
|
+
}
|
|
21418
21558
|
}, {
|
|
21419
21559
|
key: "hasAlternateRenderings",
|
|
21420
21560
|
get: function get() {
|
|
@@ -21697,6 +21837,11 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
21697
21837
|
get: function get() {
|
|
21698
21838
|
return this.catalogProps.dontShowAccStep;
|
|
21699
21839
|
}
|
|
21840
|
+
}, {
|
|
21841
|
+
key: "addPosInvisibilityToOL",
|
|
21842
|
+
get: function get() {
|
|
21843
|
+
return this.catalogProps.addPosInvisibilityToOL;
|
|
21844
|
+
}
|
|
21700
21845
|
|
|
21701
21846
|
//Planner configurations
|
|
21702
21847
|
}, {
|
|
@@ -21706,6 +21851,7 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
21706
21851
|
ignoreLayerAVC: this.catalogProps.ignoreLayerAVC,
|
|
21707
21852
|
ignoreLayerAVOAVU: this.catalogProps.ignoreLayerAVOAVU,
|
|
21708
21853
|
ignoreLayerAVNAVS: this.catalogProps.ignoreLayerAVNAVS,
|
|
21854
|
+
ignoreDockingNumber: this.catalogProps.ignoreDockingNumber,
|
|
21709
21855
|
showAccOnDpOnly: this.catalogProps.showAccOnDpOnly,
|
|
21710
21856
|
dockAccOnAvoOnly: this.catalogProps.dockAccOnAvoOnly,
|
|
21711
21857
|
hideAccessoriesInPlanner: this.catalogProps.accessorieStepAsPlanner,
|
|
@@ -21865,6 +22011,9 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
21865
22011
|
case 'IGNORELAYERAVNAVS':
|
|
21866
22012
|
_this4.catalogProps.ignoreLayerAVNAVS = item.Value == '1';
|
|
21867
22013
|
break;
|
|
22014
|
+
case 'IGNOREDOCKINGNUMBER':
|
|
22015
|
+
_this4.catalogProps.ignoreDockingNumber = item.Value == '1';
|
|
22016
|
+
break;
|
|
21868
22017
|
case 'CHECK_COLLISION_DIFFERENT_LAYERS':
|
|
21869
22018
|
_this4.catalogProps.checkCollisionForDifferentLayers = item.Value.split(';').map(function (t) {
|
|
21870
22019
|
return parseInt(t);
|
|
@@ -21983,6 +22132,12 @@ var DivaCatalogData = /*#__PURE__*/function () {
|
|
|
21983
22132
|
case 'USE_TYPENR_AS_ARTICLENR_EKTEXT':
|
|
21984
22133
|
_this4.catalogProps.useTypeNrAsArticleNrEKText = '1' == item.Value;
|
|
21985
22134
|
break;
|
|
22135
|
+
case 'HIDE_SUBPOS_ARTICLECODEX_EKTEXT':
|
|
22136
|
+
_this4.catalogProps.hideSubPosArticleCodexEKText = '1' == item.Value;
|
|
22137
|
+
break;
|
|
22138
|
+
case 'ADD_POS_INVISIBILITY_TO_OL':
|
|
22139
|
+
_this4.catalogProps.addPosInvisibilityToOL = '1' == item.Value;
|
|
22140
|
+
break;
|
|
21986
22141
|
case 'ADD_NEW_LINE_BEFOR_RULEDESC':
|
|
21987
22142
|
_this4.catalogProps.addNewLineBeforRuleDesc = '1' == item.Value;
|
|
21988
22143
|
break;
|
|
@@ -22321,11 +22476,12 @@ var DivaCatalogHandler = /*#__PURE__*/function () {
|
|
|
22321
22476
|
key: "loadDivaCatalog",
|
|
22322
22477
|
value: function () {
|
|
22323
22478
|
var _loadDivaCatalog = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2(state, catalogCodex, orderSet) {
|
|
22479
|
+
var _orderSet$OrderLines;
|
|
22324
22480
|
var promises, _yield$Promise$all, _yield$Promise$all2, catalogApiData, catalogArticleListData, catalogArticlePlannerListData, additionalModelInfos, mask, _state$catalogMask, catalogData;
|
|
22325
22481
|
return _regeneratorRuntime.wrap(function _callee2$(_context2) {
|
|
22326
22482
|
while (1) switch (_context2.prev = _context2.next) {
|
|
22327
22483
|
case 0:
|
|
22328
|
-
promises = [state.api.getDataCache(state.api.getCatalogDataQS(catalogCodex), state.api.getCatalogDataCacheKey(catalogCodex), orderSet.AccountSessionGUID), state.api.getDataCache(state.api.getJsonArticleListQS(catalogCodex), state.api.getJsonArticleListCacheKey(catalogCodex), orderSet.AccountSessionGUID), state.api.getDataCache(state.api.getJsonPlannerElementsQS(catalogCodex), state.api.getJsonPlannerElementsCacheKey(catalogCodex), orderSet.AccountSessionGUID)].concat([this.loadAdditionalModelInfos(state, orderSet.AccountGUID, orderSet.CatalogGUID)], _toConsumableArray(state.onlyRunLogic ? [] : _toConsumableArray(new Map(orderSet.OrderLines.filter(function (ol) {
|
|
22484
|
+
promises = [state.api.getDataCache(state.api.getCatalogDataQS(catalogCodex), state.api.getCatalogDataCacheKey(catalogCodex), orderSet.AccountSessionGUID), state.api.getDataCache(state.api.getJsonArticleListQS(catalogCodex), state.api.getJsonArticleListCacheKey(catalogCodex), orderSet.AccountSessionGUID), state.api.getDataCache(state.api.getJsonPlannerElementsQS(catalogCodex), state.api.getJsonPlannerElementsCacheKey(catalogCodex), orderSet.AccountSessionGUID)].concat([this.loadAdditionalModelInfos(state, orderSet.AccountGUID, orderSet.CatalogGUID)], _toConsumableArray(state.onlyRunLogic ? [] : _toConsumableArray(new Map(((_orderSet$OrderLines = orderSet.OrderLines) !== null && _orderSet$OrderLines !== void 0 ? _orderSet$OrderLines : []).filter(function (ol) {
|
|
22329
22485
|
var _ol$VariantBasketData;
|
|
22330
22486
|
return ((_ol$VariantBasketData = ol.VariantBasketDatas) === null || _ol$VariantBasketData === void 0 ? void 0 : _ol$VariantBasketData.length) && ol.ArticleType === 'OPTIONTREE';
|
|
22331
22487
|
}).map(function (os) {
|
|
@@ -22356,7 +22512,8 @@ var DivaCatalogHandler = /*#__PURE__*/function () {
|
|
|
22356
22512
|
break;
|
|
22357
22513
|
}
|
|
22358
22514
|
_context2.next = 16;
|
|
22359
|
-
return state.api.getDataCache(state.api.getCatalogMaskQS(catalogApiData.GUID, state.api.OrganizationId), undefined, undefined, 'enricher'
|
|
22515
|
+
return state.api.getDataCache(state.api.getCatalogMaskQS(catalogApiData.GUID, state.api.OrganizationId), undefined, undefined, 'enricher', undefined, undefined, true // optional call - failure is swallowed below, so don't surface the enricher error modal
|
|
22516
|
+
);
|
|
22360
22517
|
case 16:
|
|
22361
22518
|
mask = _context2.sent;
|
|
22362
22519
|
case 17:
|
|
@@ -23342,7 +23499,7 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23342
23499
|
var _step3$value = _slicedToArray(_step3.value, 2),
|
|
23343
23500
|
opvCodex = _step3$value[0],
|
|
23344
23501
|
tmpOPV = _step3$value[1];
|
|
23345
|
-
if (tmpOPV.hiddenByMask) continue;
|
|
23502
|
+
if (tmpOPV.hiddenByMask || tmpOPV.isHiddenInFeature(OP)) continue;
|
|
23346
23503
|
visibleItems[OP + '#' + opvCodex] = tmpOPV;
|
|
23347
23504
|
if (!ops.getConstructionRulesIsDisablingByOPVCodex(opvCodex)) {
|
|
23348
23505
|
if (setDefaultOPV && setDefaultOPV == opvCodex) {
|
|
@@ -23376,7 +23533,7 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23376
23533
|
var _step4$value = _slicedToArray(_step4.value, 2),
|
|
23377
23534
|
_opvCodex = _step4$value[0],
|
|
23378
23535
|
_tmpOPV = _step4$value[1];
|
|
23379
|
-
if (!_tmpOPV.hiddenByMask && this.checkItemVisibility(_tmpOPV, ops)) {
|
|
23536
|
+
if (!_tmpOPV.hiddenByMask && !_tmpOPV.isHiddenInFeature(OP) && this.checkItemVisibility(_tmpOPV, ops)) {
|
|
23380
23537
|
visibleOptionValues.set(_tmpOPV.codex, _tmpOPV);
|
|
23381
23538
|
visibleItems[OP + '#' + _opvCodex] = _tmpOPV;
|
|
23382
23539
|
if (!ops.getConstructionRulesIsDisablingByOPVCodex(_opvCodex)) {
|
|
@@ -23408,6 +23565,8 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23408
23565
|
this.updateArtOPV(null, OP, ops);
|
|
23409
23566
|
} else {
|
|
23410
23567
|
var myItem = null;
|
|
23568
|
+
// Freetext value inherited from a parent global option (see block below); forwarded to updateArtOPV.
|
|
23569
|
+
var inheritedFreeText = undefined;
|
|
23411
23570
|
|
|
23412
23571
|
//sonst myItem aus dem aktuellen Wert OPV Codex bestimmen
|
|
23413
23572
|
if (myItem == null && ops.val) {
|
|
@@ -23423,7 +23582,11 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23423
23582
|
myItem = null;
|
|
23424
23583
|
}
|
|
23425
23584
|
}
|
|
23426
|
-
|
|
23585
|
+
|
|
23586
|
+
// myItem == null: inherit the parent global option's OPV. ops.isFreeText: also re-sync the
|
|
23587
|
+
// freetext value on every update (the OPV codex alone stays constant for a slider, so without
|
|
23588
|
+
// this the accessoire keeps a stale/fabricated value after a reload).
|
|
23589
|
+
if ((myItem == null || ops.isFreeText) && (this.article.accessoireParentArticle || this.article.partListParentArticle)) {
|
|
23427
23590
|
//Global Option des Parents suchen und ersetzten
|
|
23428
23591
|
var parentGlobalOptions = this.article.getGlobalOptions();
|
|
23429
23592
|
if (parentGlobalOptions) {
|
|
@@ -23437,7 +23600,10 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23437
23600
|
var foundItem = _this.article.checkOptionAndOptionValue(OP, _ops.valCodex);
|
|
23438
23601
|
if ((foundItem === null || foundItem === void 0 ? void 0 : foundItem.opv) instanceof ArticleOptionValueData) {
|
|
23439
23602
|
if (_ops.visibleOptionValues.get(foundItem.opv.codex) || _ops.visibleOptionValues.get(foundItem.opv.parentCodex)) {
|
|
23440
|
-
myItem = foundItem.opv;
|
|
23603
|
+
if (myItem == null) myItem = foundItem.opv;
|
|
23604
|
+
// Freetext options (e.g. width slider) hold their value in the parent's freeText,
|
|
23605
|
+
// not in the OPV codex. Inherit it so the accessoire gets the actual measure.
|
|
23606
|
+
if (foundItem.opv.isFreeText && _ops.freeText != undefined) inheritedFreeText = _ops.freeText;
|
|
23441
23607
|
}
|
|
23442
23608
|
}
|
|
23443
23609
|
}
|
|
@@ -23468,7 +23634,7 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23468
23634
|
myItem = firstVisibleItem;
|
|
23469
23635
|
}
|
|
23470
23636
|
//jetzt OPV Wert zuweisen
|
|
23471
|
-
this.updateArtOPV(myItem, OP, ops);
|
|
23637
|
+
this.updateArtOPV(myItem, OP, ops, inheritedFreeText);
|
|
23472
23638
|
}
|
|
23473
23639
|
var maxPriceGroup = myOpt.useMaxPriceOfGroup;
|
|
23474
23640
|
if (maxPriceGroup) {
|
|
@@ -23531,45 +23697,19 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23531
23697
|
value: function updateIDMSpecificFeature(ops) {
|
|
23532
23698
|
var _ops$option$idmVarian, _ops$option$idmVarian2, _ops$option$idmVarian3, _ops$option$idmVarian4, _ops$option$idmVarian5;
|
|
23533
23699
|
if (!this.article.parentHasSameOption(ops.optionCodex)) return;
|
|
23700
|
+
var toConnectorCodex = function toConnectorCodex(value) {
|
|
23701
|
+
var prefix = 'OPV' + ops.optionCodex.substring(3) + '_';
|
|
23702
|
+
if (value.codex.startsWith(prefix)) return value.codex.substring(prefix.length);
|
|
23703
|
+
if (value.codex.startsWith('OPV')) return value.codex.substring(3);
|
|
23704
|
+
return value.codex;
|
|
23705
|
+
};
|
|
23534
23706
|
if ([90, 1090].includes((_ops$option$idmVarian = ops.option.idmVariantenArt) !== null && _ops$option$idmVarian !== void 0 ? _ops$option$idmVarian : 0)) {
|
|
23535
23707
|
//R (Anschlusstyp R) - AVR
|
|
23536
|
-
|
|
23537
|
-
visibleOPVs = ops.visibleOptionValues;
|
|
23538
|
-
var _iterator5 = _createForOfIteratorHelper$c(visibleOPVs),
|
|
23539
|
-
_step5;
|
|
23540
|
-
try {
|
|
23541
|
-
for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
|
|
23542
|
-
var _step5$value = _slicedToArray(_step5.value, 2),
|
|
23543
|
-
key = _step5$value[0],
|
|
23544
|
-
value = _step5$value[1];
|
|
23545
|
-
newAVRFilter.push(value.codex.substring(3));
|
|
23546
|
-
}
|
|
23547
|
-
} catch (err) {
|
|
23548
|
-
_iterator5.e(err);
|
|
23549
|
-
} finally {
|
|
23550
|
-
_iterator5.f();
|
|
23551
|
-
}
|
|
23552
|
-
this.article.newPossibleAVRFilters = newAVRFilter;
|
|
23708
|
+
this.article.newPossibleAVRFilters = Array.from(ops.visibleOptionValues.values()).map(toConnectorCodex);
|
|
23553
23709
|
}
|
|
23554
23710
|
if ([89, 1089].includes((_ops$option$idmVarian2 = ops.option.idmVariantenArt) !== null && _ops$option$idmVarian2 !== void 0 ? _ops$option$idmVarian2 : 0)) {
|
|
23555
23711
|
//L (Anschlusstyp L) - AVL
|
|
23556
|
-
|
|
23557
|
-
_visibleOPVs = ops.visibleOptionValues;
|
|
23558
|
-
var _iterator6 = _createForOfIteratorHelper$c(_visibleOPVs),
|
|
23559
|
-
_step6;
|
|
23560
|
-
try {
|
|
23561
|
-
for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
|
|
23562
|
-
var _step6$value = _slicedToArray(_step6.value, 2),
|
|
23563
|
-
_key = _step6$value[0],
|
|
23564
|
-
_value = _step6$value[1];
|
|
23565
|
-
newAVLFilter.push(_value.codex.substring(3));
|
|
23566
|
-
}
|
|
23567
|
-
} catch (err) {
|
|
23568
|
-
_iterator6.e(err);
|
|
23569
|
-
} finally {
|
|
23570
|
-
_iterator6.f();
|
|
23571
|
-
}
|
|
23572
|
-
this.article.newPossibleAVLFilters = newAVLFilter;
|
|
23712
|
+
this.article.newPossibleAVLFilters = Array.from(ops.visibleOptionValues.values()).map(toConnectorCodex);
|
|
23573
23713
|
}
|
|
23574
23714
|
//beim article abspeichern. Das Planungselement kann es sich per Funktion von dort dann holen
|
|
23575
23715
|
if ([97, 1097].includes((_ops$option$idmVarian3 = ops.option.idmVariantenArt) !== null && _ops$option$idmVarian3 !== void 0 ? _ops$option$idmVarian3 : 0)) {
|
|
@@ -23798,18 +23938,18 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23798
23938
|
myDecisions[_i].disableHistory = [];
|
|
23799
23939
|
myDecisions[_i].activeCombination = undefined;
|
|
23800
23940
|
}
|
|
23801
|
-
var
|
|
23802
|
-
|
|
23941
|
+
var _iterator5 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
23942
|
+
_step5;
|
|
23803
23943
|
try {
|
|
23804
|
-
for (
|
|
23805
|
-
var ops =
|
|
23944
|
+
for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
|
|
23945
|
+
var ops = _step5.value;
|
|
23806
23946
|
ops.updateVisibleOptionValues(ops.option.articleOptionValues);
|
|
23807
23947
|
ops.definedBySetFeatureFixed = false;
|
|
23808
23948
|
}
|
|
23809
23949
|
} catch (err) {
|
|
23810
|
-
|
|
23950
|
+
_iterator5.e(err);
|
|
23811
23951
|
} finally {
|
|
23812
|
-
|
|
23952
|
+
_iterator5.f();
|
|
23813
23953
|
}
|
|
23814
23954
|
this.catalogDecisionsByNumber = new Map(this.article.catalogArticle.articleDecisions.map(function (d) {
|
|
23815
23955
|
return [d.Number, d];
|
|
@@ -23940,11 +24080,11 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23940
24080
|
key: "updateIDMSpecificFeatures",
|
|
23941
24081
|
value: function updateIDMSpecificFeatures() {
|
|
23942
24082
|
//updaten idm planner specific options
|
|
23943
|
-
var
|
|
23944
|
-
|
|
24083
|
+
var _iterator6 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
24084
|
+
_step6;
|
|
23945
24085
|
try {
|
|
23946
|
-
for (
|
|
23947
|
-
var ops =
|
|
24086
|
+
for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
|
|
24087
|
+
var ops = _step6.value;
|
|
23948
24088
|
//when an option has no decisions the first visible optionValue has to be selected per default
|
|
23949
24089
|
if (ops.val === undefined && ops.visibleCount && !this.article.CatalogData.useDiomexConfigLogic) {
|
|
23950
24090
|
this.assignOptionValue(ops.optionCodex, ops.visibleOPVKeys[0]);
|
|
@@ -23965,9 +24105,9 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
23965
24105
|
}
|
|
23966
24106
|
}
|
|
23967
24107
|
} catch (err) {
|
|
23968
|
-
|
|
24108
|
+
_iterator6.e(err);
|
|
23969
24109
|
} finally {
|
|
23970
|
-
|
|
24110
|
+
_iterator6.f();
|
|
23971
24111
|
}
|
|
23972
24112
|
}
|
|
23973
24113
|
}, {
|
|
@@ -24201,21 +24341,21 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24201
24341
|
var negatedValues = new Set(myDoc.Row[OPT].map(function (v) {
|
|
24202
24342
|
return v.slice(1);
|
|
24203
24343
|
})); // remove the '!' from the value
|
|
24204
|
-
var
|
|
24205
|
-
|
|
24344
|
+
var _iterator7 = _createForOfIteratorHelper$c(ops.visibleOptionValues),
|
|
24345
|
+
_step7;
|
|
24206
24346
|
try {
|
|
24207
|
-
for (
|
|
24208
|
-
var
|
|
24209
|
-
opvKey =
|
|
24210
|
-
_opv =
|
|
24347
|
+
for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {
|
|
24348
|
+
var _step7$value = _slicedToArray(_step7.value, 2),
|
|
24349
|
+
opvKey = _step7$value[0],
|
|
24350
|
+
_opv = _step7$value[1];
|
|
24211
24351
|
if (!negatedValues.has(opvKey)) {
|
|
24212
24352
|
validOPVs[OPT].set(opvKey, _opv);
|
|
24213
24353
|
}
|
|
24214
24354
|
}
|
|
24215
24355
|
} catch (err) {
|
|
24216
|
-
|
|
24356
|
+
_iterator7.e(err);
|
|
24217
24357
|
} finally {
|
|
24218
|
-
|
|
24358
|
+
_iterator7.f();
|
|
24219
24359
|
}
|
|
24220
24360
|
} else {
|
|
24221
24361
|
validOPVs[OPT] = new Map(ops.visibleOptionValues);
|
|
@@ -24343,11 +24483,11 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24343
24483
|
}, {
|
|
24344
24484
|
key: "evalShowOnlyWhenHasPrice",
|
|
24345
24485
|
value: function evalShowOnlyWhenHasPrice() {
|
|
24346
|
-
var
|
|
24347
|
-
|
|
24486
|
+
var _iterator8 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
24487
|
+
_step8;
|
|
24348
24488
|
try {
|
|
24349
|
-
for (
|
|
24350
|
-
var ops =
|
|
24489
|
+
for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
|
|
24490
|
+
var ops = _step8.value;
|
|
24351
24491
|
for (var jKey in ops.visibleOptionValues) {
|
|
24352
24492
|
var opv = ops.visibleOptionValues.get(jKey);
|
|
24353
24493
|
if (opv.showOnlyWhenHasPrice && opv.price == 0) {
|
|
@@ -24359,9 +24499,9 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24359
24499
|
}
|
|
24360
24500
|
}
|
|
24361
24501
|
} catch (err) {
|
|
24362
|
-
|
|
24502
|
+
_iterator8.e(err);
|
|
24363
24503
|
} finally {
|
|
24364
|
-
|
|
24504
|
+
_iterator8.f();
|
|
24365
24505
|
}
|
|
24366
24506
|
}
|
|
24367
24507
|
|
|
@@ -24835,12 +24975,12 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24835
24975
|
}
|
|
24836
24976
|
|
|
24837
24977
|
//mengen und größenabhängige Preisberechungn.
|
|
24838
|
-
var
|
|
24839
|
-
|
|
24978
|
+
var _iterator9 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
24979
|
+
_step9;
|
|
24840
24980
|
try {
|
|
24841
|
-
for (
|
|
24981
|
+
for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
|
|
24842
24982
|
var _ops$addToMeasure;
|
|
24843
|
-
var ops =
|
|
24983
|
+
var ops = _step9.value;
|
|
24844
24984
|
var OP = ops.optionCodex;
|
|
24845
24985
|
var mUnit = ops.measureUnit;
|
|
24846
24986
|
var pUnit = ops.priceUnit;
|
|
@@ -24923,15 +25063,15 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24923
25063
|
}
|
|
24924
25064
|
//jetzt nochmal prozentuelle Preise mit TargetOption berechnen
|
|
24925
25065
|
} catch (err) {
|
|
24926
|
-
|
|
25066
|
+
_iterator9.e(err);
|
|
24927
25067
|
} finally {
|
|
24928
|
-
|
|
25068
|
+
_iterator9.f();
|
|
24929
25069
|
}
|
|
24930
|
-
var
|
|
24931
|
-
|
|
25070
|
+
var _iterator10 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
25071
|
+
_step10;
|
|
24932
25072
|
try {
|
|
24933
|
-
for (
|
|
24934
|
-
var _ops4 =
|
|
25073
|
+
for (_iterator10.s(); !(_step10 = _iterator10.n()).done;) {
|
|
25074
|
+
var _ops4 = _step10.value;
|
|
24935
25075
|
var targetPPGPrefixes = _ops4.targetPPGPrefixes;
|
|
24936
25076
|
if (!targetPPGPrefixes) continue;
|
|
24937
25077
|
var _loop7 = function _loop7() {
|
|
@@ -24951,9 +25091,9 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24951
25091
|
}
|
|
24952
25092
|
}
|
|
24953
25093
|
} catch (err) {
|
|
24954
|
-
|
|
25094
|
+
_iterator10.e(err);
|
|
24955
25095
|
} finally {
|
|
24956
|
-
|
|
25096
|
+
_iterator10.f();
|
|
24957
25097
|
}
|
|
24958
25098
|
for (var _i5 = 0; _i5 < this.article.priceRefs.length; _i5++) {
|
|
24959
25099
|
var basePriceRef = this.article.priceRefs[_i5];
|
|
@@ -24965,19 +25105,19 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
24965
25105
|
return item.PPG && item.PPG.split('_')[0] == targetPrefix;
|
|
24966
25106
|
});
|
|
24967
25107
|
if (!priceRef) {
|
|
24968
|
-
var
|
|
24969
|
-
|
|
25108
|
+
var _iterator11 = _createForOfIteratorHelper$c(_this5.article.articleOptionStates.values()),
|
|
25109
|
+
_step11;
|
|
24970
25110
|
try {
|
|
24971
|
-
for (
|
|
24972
|
-
var ops =
|
|
25111
|
+
for (_iterator11.s(); !(_step11 = _iterator11.n()).done;) {
|
|
25112
|
+
var ops = _step11.value;
|
|
24973
25113
|
if (ops.ppg && ops.ppg.split('_')[0] == targetPrefix) {
|
|
24974
25114
|
myArtOpv = ops;
|
|
24975
25115
|
}
|
|
24976
25116
|
}
|
|
24977
25117
|
} catch (err) {
|
|
24978
|
-
|
|
25118
|
+
_iterator11.e(err);
|
|
24979
25119
|
} finally {
|
|
24980
|
-
|
|
25120
|
+
_iterator11.f();
|
|
24981
25121
|
}
|
|
24982
25122
|
}
|
|
24983
25123
|
|
|
@@ -25003,36 +25143,36 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
25003
25143
|
myArticleBasePrice += priceRef.Price ? DivaUtils.decimalAdjust('round', (_priceRef$calcPrice = priceRef.calcPrice) !== null && _priceRef$calcPrice !== void 0 ? _priceRef$calcPrice : priceRef.Price, digits) : 0.0;
|
|
25004
25144
|
}
|
|
25005
25145
|
var articleUsedCalcPrice = myArticleBasePrice;
|
|
25006
|
-
var
|
|
25007
|
-
|
|
25146
|
+
var _iterator12 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
25147
|
+
_step12;
|
|
25008
25148
|
try {
|
|
25009
|
-
for (
|
|
25010
|
-
var tmpOps =
|
|
25149
|
+
for (_iterator12.s(); !(_step12 = _iterator12.n()).done;) {
|
|
25150
|
+
var tmpOps = _step12.value;
|
|
25011
25151
|
articleUsedCalcPrice = this.getOptionPrice(articleUsedCalcPrice, tmpOps.option, digits);
|
|
25012
25152
|
}
|
|
25013
25153
|
|
|
25014
25154
|
//jetzt nochmal prozentuelle Preise mit GLOBAL tarbetoption berechnen
|
|
25015
25155
|
/* TODO ABklären mit Franz - ops hat nie die Optionen - targetPPGPrefixes - ich glaube hier sollte article.priceRefs durchlaufen werden. */
|
|
25016
25156
|
} catch (err) {
|
|
25017
|
-
|
|
25157
|
+
_iterator12.e(err);
|
|
25018
25158
|
} finally {
|
|
25019
|
-
|
|
25159
|
+
_iterator12.f();
|
|
25020
25160
|
}
|
|
25021
|
-
var
|
|
25022
|
-
|
|
25161
|
+
var _iterator13 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
25162
|
+
_step13;
|
|
25023
25163
|
try {
|
|
25024
|
-
for (
|
|
25164
|
+
for (_iterator13.s(); !(_step13 = _iterator13.n()).done;) {
|
|
25025
25165
|
var _ops5$targetPPGPrefix, _ops5$targetPPGPrefix2;
|
|
25026
|
-
var _ops5 =
|
|
25166
|
+
var _ops5 = _step13.value;
|
|
25027
25167
|
var targetOption = (_ops5$targetPPGPrefix = (_ops5$targetPPGPrefix2 = _ops5.targetPPGPrefixes) === null || _ops5$targetPPGPrefix2 === void 0 ? void 0 : _ops5$targetPPGPrefix2[0]) !== null && _ops5$targetPPGPrefix !== void 0 ? _ops5$targetPPGPrefix : _ops5.targetOption;
|
|
25028
25168
|
if (_ops5.isPercentage && targetOption == 'GLOBAL') {
|
|
25029
25169
|
articleUsedCalcPrice = articleUsedCalcPrice * (1 + _ops5.calcPrice);
|
|
25030
25170
|
}
|
|
25031
25171
|
}
|
|
25032
25172
|
} catch (err) {
|
|
25033
|
-
|
|
25173
|
+
_iterator13.e(err);
|
|
25034
25174
|
} finally {
|
|
25035
|
-
|
|
25175
|
+
_iterator13.f();
|
|
25036
25176
|
}
|
|
25037
25177
|
for (var _i7 = 0; _i7 < this.article.priceRefs.length; _i7++) {
|
|
25038
25178
|
var _priceRef = this.article.priceRefs[_i7];
|
|
@@ -25174,11 +25314,11 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
25174
25314
|
if (a[i].trim() != '') {
|
|
25175
25315
|
var searchOpt = 'OPT' + a[i].trim();
|
|
25176
25316
|
//Optionsbaum des Artikels durchsuchen
|
|
25177
|
-
var
|
|
25178
|
-
|
|
25317
|
+
var _iterator14 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
25318
|
+
_step14;
|
|
25179
25319
|
try {
|
|
25180
|
-
for (
|
|
25181
|
-
var _ops6 =
|
|
25320
|
+
for (_iterator14.s(); !(_step14 = _iterator14.n()).done;) {
|
|
25321
|
+
var _ops6 = _step14.value;
|
|
25182
25322
|
if (_ops6.ocd == searchOpt || _ops6.optionCodex == searchOpt) {
|
|
25183
25323
|
if (_ops6 && _ops6.price > 0) {
|
|
25184
25324
|
myPercBasePrice += _ops6.price * _ops6.quantity;
|
|
@@ -25187,9 +25327,9 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
25187
25327
|
}
|
|
25188
25328
|
}
|
|
25189
25329
|
} catch (err) {
|
|
25190
|
-
|
|
25330
|
+
_iterator14.e(err);
|
|
25191
25331
|
} finally {
|
|
25192
|
-
|
|
25332
|
+
_iterator14.f();
|
|
25193
25333
|
}
|
|
25194
25334
|
}
|
|
25195
25335
|
}
|
|
@@ -25235,18 +25375,18 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
25235
25375
|
}
|
|
25236
25376
|
|
|
25237
25377
|
// this functions updates the images of OPVs that depend on rules
|
|
25238
|
-
var
|
|
25239
|
-
|
|
25378
|
+
var _iterator15 = _createForOfIteratorHelper$c(this.article.articleOptionStates.values()),
|
|
25379
|
+
_step15;
|
|
25240
25380
|
try {
|
|
25241
|
-
for (
|
|
25242
|
-
var ops =
|
|
25243
|
-
var
|
|
25244
|
-
|
|
25381
|
+
for (_iterator15.s(); !(_step15 = _iterator15.n()).done;) {
|
|
25382
|
+
var ops = _step15.value;
|
|
25383
|
+
var _iterator16 = _createForOfIteratorHelper$c(ops.visibleOptionValues),
|
|
25384
|
+
_step16;
|
|
25245
25385
|
try {
|
|
25246
|
-
for (
|
|
25247
|
-
var
|
|
25248
|
-
jKey =
|
|
25249
|
-
opv =
|
|
25386
|
+
for (_iterator16.s(); !(_step16 = _iterator16.n()).done;) {
|
|
25387
|
+
var _step16$value = _slicedToArray(_step16.value, 2),
|
|
25388
|
+
jKey = _step16$value[0],
|
|
25389
|
+
opv = _step16$value[1];
|
|
25250
25390
|
if (opv.images) {
|
|
25251
25391
|
var imageFound = false;
|
|
25252
25392
|
for (var _i10 = 0; _i10 < opv.images.length; _i10++) {
|
|
@@ -25265,18 +25405,18 @@ var DivaEngine = /*#__PURE__*/function () {
|
|
|
25265
25405
|
}
|
|
25266
25406
|
}
|
|
25267
25407
|
} catch (err) {
|
|
25268
|
-
|
|
25408
|
+
_iterator16.e(err);
|
|
25269
25409
|
} finally {
|
|
25270
|
-
|
|
25410
|
+
_iterator16.f();
|
|
25271
25411
|
}
|
|
25272
25412
|
}
|
|
25273
25413
|
|
|
25274
25414
|
// this function calculates an Svg to the current configuration if neccessary (SVG Tausch)
|
|
25275
25415
|
// if the Article has no SVG Tausch nothing is done
|
|
25276
25416
|
} catch (err) {
|
|
25277
|
-
|
|
25417
|
+
_iterator15.e(err);
|
|
25278
25418
|
} finally {
|
|
25279
|
-
|
|
25419
|
+
_iterator15.f();
|
|
25280
25420
|
}
|
|
25281
25421
|
var newSVGFile = null;
|
|
25282
25422
|
var svgChangedViaSvgTausch = false;
|
|
@@ -25907,7 +26047,7 @@ var IDMEngine = /*#__PURE__*/function () {
|
|
|
25907
26047
|
} else if (!_ops4.valCodex) {
|
|
25908
26048
|
LOG$g.warn('evalSetFeature(featureRef) decision ' + decision.decisionNo + ': referenced source feature ' + action.featureRef.featureNo + ' has no selected value (valCodex undefined) - target feature ' + action.featureNo + ' will NOT be set (price relevant)');
|
|
25909
26049
|
} else if (!targetHasSourceValue) {
|
|
25910
|
-
LOG$g.warn('evalSetFeature(featureRef) decision ' + decision.decisionNo + ': target feature ' + action.featureNo +
|
|
26050
|
+
LOG$g.warn('evalSetFeature(featureRef) decision ' + decision.decisionNo + ': target feature ' + action.featureNo + ' does not have source feature ' + action.featureRef.featureNo + "'s value '" + _ops4.valCodex + "' among its visible option values - assignOptionValue will be a no-op (price relevant). Target visible values: " + (targetOps ? Array.from(targetOps.visibleOptionValues.keys()).join(', ') : '<no target>'));
|
|
25911
26051
|
}
|
|
25912
26052
|
if (_ops4 !== null && _ops4 !== void 0 && _ops4.valCodex) this.assignOptionValue(action.featureNo.toString(), _ops4.valCodex, isFixed ? 'fix' : 'set');
|
|
25913
26053
|
} else if (action.optionRef) {
|
|
@@ -26005,7 +26145,7 @@ var IDMEngine = /*#__PURE__*/function () {
|
|
|
26005
26145
|
this.logPrice(priceFeatureGroup, index);
|
|
26006
26146
|
if (index !== undefined) {
|
|
26007
26147
|
var _this$article$catalog, _this$article$catalog4, _priceFeatureGroup$fe, _priceFeatureGroup$fe2;
|
|
26008
|
-
var matichingFinish = priceFeatureGroup.
|
|
26148
|
+
var matichingFinish = priceFeatureGroup.projectFinishes[index];
|
|
26009
26149
|
var priceKey = 'PRFG' + priceFeatureGroup.priceFeatureGroupNo + '_' + matichingFinish.supplierPriceGroup;
|
|
26010
26150
|
if (((_this$article$catalog = this.article.catalogArticle.idmPrices) === null || _this$article$catalog === void 0 ? void 0 : _this$article$catalog.prices[priceKey]) === undefined) {
|
|
26011
26151
|
var _this$article$catalog2, _this$article$catalog3;
|
|
@@ -26360,7 +26500,7 @@ var IDMEngine = /*#__PURE__*/function () {
|
|
|
26360
26500
|
_loop7(i);
|
|
26361
26501
|
}
|
|
26362
26502
|
if (quanitity >= 1) {
|
|
26363
|
-
var _catalogCodex$toStrin,
|
|
26503
|
+
var _catalogCodex$toStrin, _ref9;
|
|
26364
26504
|
partlistArticlesToLoad.push({
|
|
26365
26505
|
CatalogCodex: (_catalogCodex$toStrin = catalogCodex.toString()) !== null && _catalogCodex$toStrin !== void 0 ? _catalogCodex$toStrin : this.article.catalogCodex,
|
|
26366
26506
|
BasketID: previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.basketId,
|
|
@@ -26377,7 +26517,7 @@ var IDMEngine = /*#__PURE__*/function () {
|
|
|
26377
26517
|
VariantValues: this.article.variantValuesForPla(myPartListPos.configurationMode, previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.VariantValues, newConfigValues),
|
|
26378
26518
|
VariantItemData: previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.VariantItemData,
|
|
26379
26519
|
optionsForPrint: featuresForPrint,
|
|
26380
|
-
RetailArticleNr:
|
|
26520
|
+
RetailArticleNr: myPartListPos.retailArticleNr && myPartListPos.retailArticleNr !== '' ? myPartListPos.retailArticleNr : undefined,
|
|
26381
26521
|
RetailPrefix: (_ref9 = myPartListPos.retailPrefix) !== null && _ref9 !== void 0 ? _ref9 : undefined
|
|
26382
26522
|
//SupplierOrderCodex: // TODO WWS IDM ,myPartListPos.SupplierOrderCodex,
|
|
26383
26523
|
|
|
@@ -26503,13 +26643,16 @@ var IDMEngine = /*#__PURE__*/function () {
|
|
|
26503
26643
|
value: function updateIDMSpecificFeature(myArtOPS) {
|
|
26504
26644
|
var _myArtOPS$option$idmV, _myArtOPS$option$idmV2, _myArtOPS$option$idmV3, _myArtOPS$option$idmV4, _myArtOPS$option$idmV5;
|
|
26505
26645
|
if (!this.article.parentHasSameOption(myArtOPS.optionCodex)) return;
|
|
26646
|
+
var toConnectorCodex = function toConnectorCodex(key) {
|
|
26647
|
+
return key.startsWith(myArtOPS.optionCodex + '_') ? key.substring(myArtOPS.optionCodex.length + 1) : key;
|
|
26648
|
+
};
|
|
26506
26649
|
if ([90, 1090].includes((_myArtOPS$option$idmV = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV !== void 0 ? _myArtOPS$option$idmV : 0)) {
|
|
26507
26650
|
//R (Anschlusstyp R) - AVR
|
|
26508
|
-
this.article.newPossibleAVRFilters = myArtOPS.visibleOPVKeys;
|
|
26651
|
+
this.article.newPossibleAVRFilters = myArtOPS.visibleOPVKeys.map(toConnectorCodex);
|
|
26509
26652
|
}
|
|
26510
26653
|
if ([89, 1089].includes((_myArtOPS$option$idmV2 = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV2 !== void 0 ? _myArtOPS$option$idmV2 : 0)) {
|
|
26511
26654
|
//L (Anschlusstyp L) - AVL
|
|
26512
|
-
this.article.newPossibleAVLFilters = myArtOPS.visibleOPVKeys;
|
|
26655
|
+
this.article.newPossibleAVLFilters = myArtOPS.visibleOPVKeys.map(toConnectorCodex);
|
|
26513
26656
|
}
|
|
26514
26657
|
if ([97, 1097].includes((_myArtOPS$option$idmV3 = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV3 !== void 0 ? _myArtOPS$option$idmV3 : 0)) {
|
|
26515
26658
|
try {
|
|
@@ -26873,6 +27016,7 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
26873
27016
|
partlistDecisionNo: initParams.partlistDecisionNo,
|
|
26874
27017
|
partListParentArticle: initParams.parentArticle,
|
|
26875
27018
|
partlistArticleVisibleInTree: initParams.partlistArticleVisibleInTree,
|
|
27019
|
+
posInvisibility: initParams.posInvisibility,
|
|
26876
27020
|
partlistArticleStandalone: initParams.partlistArticleStandalone,
|
|
26877
27021
|
partlistGroupPrefix: initParams.partlistGroupPrefix,
|
|
26878
27022
|
hasPartlistArticle: initParams.hasPartlistArticle ? initParams.hasPartlistArticle : false,
|
|
@@ -27025,6 +27169,11 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
27025
27169
|
get: function get() {
|
|
27026
27170
|
return this.article.partlistArticleVisibleInTree && this.hasOptionsThatParentDoesNotHave;
|
|
27027
27171
|
}
|
|
27172
|
+
}, {
|
|
27173
|
+
key: "posInvisibility",
|
|
27174
|
+
get: function get() {
|
|
27175
|
+
return this.article.posInvisibility;
|
|
27176
|
+
}
|
|
27028
27177
|
}, {
|
|
27029
27178
|
key: "partlistArticleStandalone",
|
|
27030
27179
|
get: function get() {
|
|
@@ -27948,6 +28097,11 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
27948
28097
|
get: function get() {
|
|
27949
28098
|
return this.catalogArticle.bundleRules;
|
|
27950
28099
|
}
|
|
28100
|
+
}, {
|
|
28101
|
+
key: "addAsZKAT",
|
|
28102
|
+
get: function get() {
|
|
28103
|
+
return this.catalogArticle.addAsZKAT;
|
|
28104
|
+
}
|
|
27951
28105
|
}, {
|
|
27952
28106
|
key: "hasPartlistArticleVisibleInTree",
|
|
27953
28107
|
get: function get() {
|
|
@@ -29552,7 +29706,7 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
29552
29706
|
break;
|
|
29553
29707
|
}
|
|
29554
29708
|
_context.next = 4;
|
|
29555
|
-
return import('./ShelfPlanner-
|
|
29709
|
+
return import('./ShelfPlanner-2a545c7c.js');
|
|
29556
29710
|
case 4:
|
|
29557
29711
|
_yield$import = _context.sent;
|
|
29558
29712
|
ShelfPlanner = _yield$import["default"];
|
|
@@ -29825,7 +29979,7 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
29825
29979
|
var opv;
|
|
29826
29980
|
var opt;
|
|
29827
29981
|
if (ops.val) {
|
|
29828
|
-
var _ops$option$ocd, _ops$option$ocd2, _ops$val$ocd3;
|
|
29982
|
+
var _ops$option$ocd, _ops$option$ocd2, _ops$val$ocd3, _ops$val$properties;
|
|
29829
29983
|
opt = (this.CatalogData.isIDMFormat ? 'OPT' : '') + ((_ops$option$ocd = ops.option.ocd) !== null && _ops$option$ocd !== void 0 ? _ops$option$ocd : ops.optionCodex);
|
|
29830
29984
|
opv = (this.CatalogData.isIDMFormat ? 'OPV' + ((_ops$option$ocd2 = ops.option.ocd) !== null && _ops$option$ocd2 !== void 0 ? _ops$option$ocd2 : ops.optionCodex) + '_' : '') + ((_ops$val$ocd3 = ops.val.ocd) !== null && _ops$val$ocd3 !== void 0 ? _ops$val$ocd3 : ops.val.codex);
|
|
29831
29985
|
if (this.CatalogData.isIDM3DCat && ops.val.vCodex) opv = 'OPV' + ops.idmVariantenArt + '_' + ops.val.vCodex;
|
|
@@ -29841,14 +29995,26 @@ var DivaArticle = /*#__PURE__*/function () {
|
|
|
29841
29995
|
OPV: ops.freeText
|
|
29842
29996
|
});
|
|
29843
29997
|
}
|
|
29844
|
-
|
|
29998
|
+
var divaDataEngineMat = (_ops$val$properties = ops.val.properties) === null || _ops$val$properties === void 0 ? void 0 : _ops$val$properties.find(function (prop) {
|
|
29999
|
+
return prop.Codex == "TEXTURENAME";
|
|
30000
|
+
});
|
|
30001
|
+
if (!ret.MAT) {
|
|
30002
|
+
ret.MAT = [];
|
|
30003
|
+
}
|
|
30004
|
+
if (divaDataEngineMat) {
|
|
29845
30005
|
var _ops$val$name;
|
|
29846
|
-
if (!ret.MAT) {
|
|
29847
|
-
ret.MAT = [];
|
|
29848
|
-
}
|
|
29849
30006
|
ret.MAT.push({
|
|
29850
30007
|
OPT: partlistPrefix ? 'OPT' + partlistPrefix + opt.substring(3) : opt,
|
|
29851
30008
|
N: DivaUtils.removeSpecialChars((_ops$val$name = ops.val.name) !== null && _ops$val$name !== void 0 ? _ops$val$name : ''),
|
|
30009
|
+
T: divaDataEngineMat.Name,
|
|
30010
|
+
M: divaDataEngineMat.Value
|
|
30011
|
+
});
|
|
30012
|
+
}
|
|
30013
|
+
if (ops.val.isTexture) {
|
|
30014
|
+
var _ops$val$name2;
|
|
30015
|
+
ret.MAT.push({
|
|
30016
|
+
OPT: partlistPrefix ? 'OPT' + partlistPrefix + opt.substring(3) : opt,
|
|
30017
|
+
N: DivaUtils.removeSpecialChars((_ops$val$name2 = ops.val.name) !== null && _ops$val$name2 !== void 0 ? _ops$val$name2 : ''),
|
|
29852
30018
|
T: ops.val.textureName,
|
|
29853
30019
|
M: ops.val.material
|
|
29854
30020
|
});
|
|
@@ -31338,6 +31504,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
|
|
|
31338
31504
|
supplierOrderCodex: doLoadItem.SupplierOrderCodex,
|
|
31339
31505
|
initDecisions: doLoadItem.initDecisions,
|
|
31340
31506
|
partlistArticleVisibleInTree: doLoadItem.PosInvisibility === 0,
|
|
31507
|
+
posInvisibility: doLoadItem.PosInvisibility,
|
|
31341
31508
|
partlistArticleStandalone: doLoadItem.ConfigurationMode,
|
|
31342
31509
|
partlistGroupPrefix: doLoadItem.partlistGroupPrefix,
|
|
31343
31510
|
optionsForPrint: doLoadItem.optionsForPrint,
|
|
@@ -31720,6 +31887,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
|
|
|
31720
31887
|
ArticleCodex: article.articleCodex,
|
|
31721
31888
|
ConfigArticleCodex: article.configArticleCodex,
|
|
31722
31889
|
UseTypeNrAsArticleNrEKText: catalogData.useTypeNrAsArticleNrEKText,
|
|
31890
|
+
HideSubPosArticleCodexEKText: catalogData.hideSubPosArticleCodexEKText,
|
|
31723
31891
|
TypeNr: article.typeNr,
|
|
31724
31892
|
ArticleEAN: article.articleEAN,
|
|
31725
31893
|
ArticleGUID: article.articleGUID,
|
|
@@ -31759,6 +31927,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
|
|
|
31759
31927
|
IsPlannerElement: article.hasCatalogPlannerArticle,
|
|
31760
31928
|
HasPartlistArticle: article.hasPartlistArticle,
|
|
31761
31929
|
PartlistArticleInvisibility: !article.partlistArticleVisibleInTree && !article.optionsForPrint && !article.partlistArticleStandalone,
|
|
31930
|
+
PosInvisibility: catalogData.addPosInvisibilityToOL ? article.posInvisibility : undefined,
|
|
31762
31931
|
SendToSAP: article.sendToSap,
|
|
31763
31932
|
ShelfPlandata: article.shelfPlanner ? DivaUtils.encodeBasketJson((_article$shelfPlanner3 = (_article$shelfPlanner4 = article.shelfPlanner) === null || _article$shelfPlanner4 === void 0 ? void 0 : _article$shelfPlanner4.generateShelfPlandata()) !== null && _article$shelfPlanner3 !== void 0 ? _article$shelfPlanner3 : (_article$doorPlanner = article.doorPlanner) === null || _article$doorPlanner === void 0 ? void 0 : _article$doorPlanner.getMovedData(article.basketId)) : undefined,
|
|
31764
31933
|
MetaData: !hasFavorites ? article.MetaData : undefined,
|
|
@@ -34761,7 +34930,7 @@ var DivaFavoritesHandler = /*#__PURE__*/function () {
|
|
|
34761
34930
|
if (targetArticle[opt] && !variantValues[opt]) variantValues[opt] = targetArticle[opt];
|
|
34762
34931
|
}
|
|
34763
34932
|
}
|
|
34764
|
-
configVariant = new ConfigVariantData(variant.id, set.setName, set.setName_locales, setImage, (_hQRenderScript = hQRenderScript) === null || _hQRenderScript === void 0 ? void 0 : _hQRenderScript._id, DivaUtils.encodeBase64(set.plannerHandler.getProject3D(set.getSetId())), set.getVariantsDescription(), set.SetArticleNr, set.getSetPrice(), set.setHash, 1, set.getVariantBasketData(), articleHandlerInstance.getCompactOrderLine(_objectSpread$g(_objectSpread$g({}, set.getDivaArticles()), set.getPartlistArticlesOfSet())), variantValues, summaryHandlerInstance.convertSummaryItemsToSummaryInfo(set), plannerData != undefined ? DivaUtils.encodeBase64(JSON.stringify(plannerData)) : '', urlToPlanning2D, setHandlerInstance.getBBoxObject(set, dimensions), set.getBruttoSetPrice(), undefined, undefined, set.MetaData, set.MetaData_locales, DivaUtils.stripTagsFromDict(set.getVariantsDescription_locales()), (_basket$OrderSets$set = basket.OrderSets[setindex].ConfigVariants) === null || _basket$OrderSets$set === void 0 || (_basket$OrderSets$set = _basket$OrderSets$set[set.basketConfigVariants.length]) === null || _basket$OrderSets$set === void 0 ? void 0 : _basket$OrderSets$set.SetOrderText, (_basket$OrderSets$set2 = basket.OrderSets[setindex].ConfigVariants) === null || _basket$OrderSets$set2 === void 0 || (_basket$OrderSets$set2 = _basket$OrderSets$set2[set.basketConfigVariants.length]) === null || _basket$OrderSets$set2 === void 0 ? void 0 : _basket$OrderSets$set2.SetOrderText_locales);
|
|
34933
|
+
configVariant = new ConfigVariantData(variant.id, set.setName, set.setName_locales, setImage, (_hQRenderScript = hQRenderScript) === null || _hQRenderScript === void 0 ? void 0 : _hQRenderScript._id, DivaUtils.encodeBase64(set.plannerHandler.getProject3D(set.getSetId()), set.CatalogData.isIDM3DCat), set.getVariantsDescription(), set.SetArticleNr, set.getSetPrice(), set.setHash, 1, set.getVariantBasketData(), articleHandlerInstance.getCompactOrderLine(_objectSpread$g(_objectSpread$g({}, set.getDivaArticles()), set.getPartlistArticlesOfSet())), variantValues, summaryHandlerInstance.convertSummaryItemsToSummaryInfo(set), plannerData != undefined ? DivaUtils.encodeBase64(JSON.stringify(plannerData), set.CatalogData.isIDM3DCat) : '', urlToPlanning2D, setHandlerInstance.getBBoxObject(set, dimensions), set.getBruttoSetPrice(), undefined, undefined, set.MetaData, set.MetaData_locales, DivaUtils.stripTagsFromDict(set.getVariantsDescription_locales()), (_basket$OrderSets$set = basket.OrderSets[setindex].ConfigVariants) === null || _basket$OrderSets$set === void 0 || (_basket$OrderSets$set = _basket$OrderSets$set[set.basketConfigVariants.length]) === null || _basket$OrderSets$set === void 0 ? void 0 : _basket$OrderSets$set.SetOrderText, (_basket$OrderSets$set2 = basket.OrderSets[setindex].ConfigVariants) === null || _basket$OrderSets$set2 === void 0 || (_basket$OrderSets$set2 = _basket$OrderSets$set2[set.basketConfigVariants.length]) === null || _basket$OrderSets$set2 === void 0 ? void 0 : _basket$OrderSets$set2.SetOrderText_locales);
|
|
34765
34934
|
set.basketConfigVariants.push(configVariant);
|
|
34766
34935
|
case 32:
|
|
34767
34936
|
case "end":
|
|
@@ -35213,8 +35382,9 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
|
|
|
35213
35382
|
}
|
|
35214
35383
|
var configInAccessoire = set.configAccessoiresInAccessoireStep;
|
|
35215
35384
|
var configInAccessoireAndTree = set.CatalogData.configAccessoires && !article.isShelfAccessoire;
|
|
35385
|
+
var isRelatedAccessoire = !!article.relatedToBasketId && !(article.isPartListArticle && article.partlistArticleVisibleInTree);
|
|
35216
35386
|
//give this step a unique key so it is not merged with any option of te main article
|
|
35217
|
-
if (configInAccessoire &&
|
|
35387
|
+
if (configInAccessoire && isRelatedAccessoire) {
|
|
35218
35388
|
if (configInAccessoireAndTree) {
|
|
35219
35389
|
//remember old configStepKey to push basketId to its targetArticles anyways
|
|
35220
35390
|
mainConfigStepKey = configStepKey;
|
|
@@ -35223,7 +35393,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
|
|
|
35223
35393
|
}
|
|
35224
35394
|
var plaBasketIds = Object.keys(articles[basketId].getRecursivePartlistArticles(true, true));
|
|
35225
35395
|
var singleOPVOnly = ops.visibleCount == 1 && !ops.isFreeText && !set.CatalogData.dontHideOption.includes(ops.option.codex) && !((_set$ViewConfig4 = set.ViewConfig) !== null && _set$ViewConfig4 !== void 0 && _set$ViewConfig4.showSingleOPVOnly);
|
|
35226
|
-
var isAccessoire =
|
|
35396
|
+
var isAccessoire = isRelatedAccessoire ? article.articleCodex : false;
|
|
35227
35397
|
if (!configTree.getTabGroupByCodex(tabGroupCodex)) {
|
|
35228
35398
|
var newTabGroup = this.createTabGroup(tabGroupCodex, tabGroupTitel, 'OPTION', configTree);
|
|
35229
35399
|
configTree.addTabGroup(tabGroupCodex, newTabGroup);
|
|
@@ -36060,7 +36230,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
|
|
|
36060
36230
|
if (!selectedVals.find(function (opv) {
|
|
36061
36231
|
var _myConfigItems$get, _myConfigItems$get2;
|
|
36062
36232
|
return opv == item.codex || ((_myConfigItems$get = myConfigItems.get(opv)) === null || _myConfigItems$get === void 0 ? void 0 : _myConfigItems$get.ocd) && ((_myConfigItems$get2 = myConfigItems.get(opv)) === null || _myConfigItems$get2 === void 0 ? void 0 : _myConfigItems$get2.ocd) === item.codex;
|
|
36063
|
-
}) && (ops.definedBySetFeatureFixed || item.hiddenByMask)) return 1; // continue
|
|
36233
|
+
}) && (ops.definedBySetFeatureFixed || item.hiddenByMask || item.isHiddenInFeature(ops.optionCodex))) return 1; // continue
|
|
36064
36234
|
var image = item.image ? set.CatalogData.getCatImageURL(item.image, '_gal') : '';
|
|
36065
36235
|
var zoomImage = undefined;
|
|
36066
36236
|
if (item.zoomImage && item.isTexture) {
|
|
@@ -37574,7 +37744,7 @@ var DivaSet = /*#__PURE__*/function () {
|
|
|
37574
37744
|
break;
|
|
37575
37745
|
}
|
|
37576
37746
|
_context5.next = 3;
|
|
37577
|
-
return import('./DoorPlanner-
|
|
37747
|
+
return import('./DoorPlanner-dc53eaca.js');
|
|
37578
37748
|
case 3:
|
|
37579
37749
|
_yield$import = _context5.sent;
|
|
37580
37750
|
DoorPlanner = _yield$import["default"];
|
|
@@ -39100,7 +39270,7 @@ var DivaSetHandler = /*#__PURE__*/function () {
|
|
|
39100
39270
|
}
|
|
39101
39271
|
}
|
|
39102
39272
|
if (!(from !== 'toDeleteShelf')) {
|
|
39103
|
-
_context14.next =
|
|
39273
|
+
_context14.next = 16;
|
|
39104
39274
|
break;
|
|
39105
39275
|
}
|
|
39106
39276
|
set.addArticle(newArticle);
|
|
@@ -39108,7 +39278,7 @@ var DivaSetHandler = /*#__PURE__*/function () {
|
|
|
39108
39278
|
return articleHandlerInstance.toDoAfterArticleLoaded(newArticle, defaultHeaderValues, {}, from, undefined, ignorePlanner);
|
|
39109
39279
|
case 15:
|
|
39110
39280
|
if (newArticle.relatedToBasketId) {
|
|
39111
|
-
LOG$9.businessEvent('onClickAccesorie', 'Planner', '
|
|
39281
|
+
LOG$9.businessEvent('onClickAccesorie', 'Planner', 'Accessoire wurde geplant', {
|
|
39112
39282
|
article: {
|
|
39113
39283
|
articleCodex: articleCodex,
|
|
39114
39284
|
articleName: newArticle.name
|
|
@@ -39122,6 +39292,7 @@ var DivaSetHandler = /*#__PURE__*/function () {
|
|
|
39122
39292
|
}
|
|
39123
39293
|
});
|
|
39124
39294
|
}
|
|
39295
|
+
case 16:
|
|
39125
39296
|
return _context14.abrupt("return", newArticle);
|
|
39126
39297
|
case 17:
|
|
39127
39298
|
case "end":
|
|
@@ -41137,7 +41308,7 @@ var DivaSetHandler = /*#__PURE__*/function () {
|
|
|
41137
41308
|
break;
|
|
41138
41309
|
case 32:
|
|
41139
41310
|
//fill diva3DProject for renderings & AR Converter
|
|
41140
|
-
basketData.Diva3DProject = DivaUtils.encodeBase64(set === null || set === void 0 ? void 0 : set.plannerHandler.getProject3D());
|
|
41311
|
+
basketData.Diva3DProject = DivaUtils.encodeBase64(set === null || set === void 0 ? void 0 : set.plannerHandler.getProject3D(), set === null || set === void 0 ? void 0 : set.CatalogData.isIDM3DCat);
|
|
41141
41312
|
i = 0;
|
|
41142
41313
|
case 34:
|
|
41143
41314
|
if (!(i < ((_basketData$OrderSets = basketData.OrderSets) === null || _basketData$OrderSets === void 0 ? void 0 : _basketData$OrderSets.length))) {
|
|
@@ -41598,7 +41769,7 @@ var DivaSetHandler = /*#__PURE__*/function () {
|
|
|
41598
41769
|
FavoriteAiRoomKeys: set.getAiImagesAsJpg().map(function (img) {
|
|
41599
41770
|
return img.promptId;
|
|
41600
41771
|
}),
|
|
41601
|
-
SetPlanData: plannerData != undefined ? DivaUtils.encodeBase64(JSON.stringify(plannerData)) : '',
|
|
41772
|
+
SetPlanData: plannerData != undefined ? DivaUtils.encodeBase64(JSON.stringify(plannerData), catalogData.isIDM3DCat) : '',
|
|
41602
41773
|
SetID: set.getSetId(),
|
|
41603
41774
|
SetName: set.setName,
|
|
41604
41775
|
SetName_locales: set.setName_locales,
|
|
@@ -43048,7 +43219,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
|
|
|
43048
43219
|
break;
|
|
43049
43220
|
case 3:
|
|
43050
43221
|
_context12.next = 5;
|
|
43051
|
-
return import('./PfisterWWSHandler-
|
|
43222
|
+
return import('./PfisterWWSHandler-4ac1baf9.js');
|
|
43052
43223
|
case 5:
|
|
43053
43224
|
_yield$import = _context12.sent;
|
|
43054
43225
|
PfisterWWSHandler = _yield$import["default"];
|
|
@@ -43056,7 +43227,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
|
|
|
43056
43227
|
return _context12.abrupt("break", 27);
|
|
43057
43228
|
case 9:
|
|
43058
43229
|
_context12.next = 11;
|
|
43059
|
-
return import('./LiviqueWWSHandler-
|
|
43230
|
+
return import('./LiviqueWWSHandler-35286ba2.js');
|
|
43060
43231
|
case 11:
|
|
43061
43232
|
_yield$import2 = _context12.sent;
|
|
43062
43233
|
LiviqueWWSHandler = _yield$import2["default"];
|
|
@@ -43064,7 +43235,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
|
|
|
43064
43235
|
return _context12.abrupt("break", 27);
|
|
43065
43236
|
case 15:
|
|
43066
43237
|
_context12.next = 17;
|
|
43067
|
-
return import('./SeriousBasketHandler-
|
|
43238
|
+
return import('./SeriousBasketHandler-fd07c5d0.js');
|
|
43068
43239
|
case 17:
|
|
43069
43240
|
_yield$import3 = _context12.sent;
|
|
43070
43241
|
SeriousWWSHandler = _yield$import3["default"];
|
|
@@ -43072,7 +43243,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
|
|
|
43072
43243
|
return _context12.abrupt("break", 27);
|
|
43073
43244
|
case 21:
|
|
43074
43245
|
_context12.next = 23;
|
|
43075
|
-
return import('./StandardWWSHandler-
|
|
43246
|
+
return import('./StandardWWSHandler-21793a92.js');
|
|
43076
43247
|
case 23:
|
|
43077
43248
|
_yield$import4 = _context12.sent;
|
|
43078
43249
|
StandardWWSHandler = _yield$import4["default"];
|
|
@@ -44496,7 +44667,7 @@ var PlannerHandler3D = /*#__PURE__*/function () {
|
|
|
44496
44667
|
while (1) switch (_context3.prev = _context3.next) {
|
|
44497
44668
|
case 0:
|
|
44498
44669
|
_context3.next = 2;
|
|
44499
|
-
return import('./Host3DSignalR-
|
|
44670
|
+
return import('./Host3DSignalR-e94ff645.js');
|
|
44500
44671
|
case 2:
|
|
44501
44672
|
_yield$import = _context3.sent;
|
|
44502
44673
|
Host3DSignalR = _yield$import["default"];
|
|
@@ -46182,7 +46353,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
|
|
|
46182
46353
|
break;
|
|
46183
46354
|
case 8:
|
|
46184
46355
|
_context5.next = 10;
|
|
46185
|
-
return import('./DivaStandardPlanner-
|
|
46356
|
+
return import('./DivaStandardPlanner-c5615a1d.js');
|
|
46186
46357
|
case 10:
|
|
46187
46358
|
_yield$import = _context5.sent;
|
|
46188
46359
|
DivaStandardPlanner = _yield$import["default"];
|
|
@@ -46193,7 +46364,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
|
|
|
46193
46364
|
return _context5.abrupt("break", 21);
|
|
46194
46365
|
case 15:
|
|
46195
46366
|
_context5.next = 17;
|
|
46196
|
-
return import('./DivaBoxPlanner-
|
|
46367
|
+
return import('./DivaBoxPlanner-05a7aba4.js');
|
|
46197
46368
|
case 17:
|
|
46198
46369
|
_yield$import2 = _context5.sent;
|
|
46199
46370
|
DivaBoxPlanner = _yield$import2["default"];
|
|
@@ -47337,7 +47508,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
|
|
|
47337
47508
|
},
|
|
47338
47509
|
updatePlannerMsgContainer: function updatePlannerMsgContainer() {}
|
|
47339
47510
|
});
|
|
47340
|
-
var setData = DivaUtils.encodeBase64(JSON.stringify(set.plannerHandler.savePlanner(origSet.getSetId())));
|
|
47511
|
+
var setData = DivaUtils.encodeBase64(JSON.stringify(set.plannerHandler.savePlanner(origSet.getSetId())), set.CatalogData.isIDM3DCat);
|
|
47341
47512
|
this.plannerList.forEach(function (v) {
|
|
47342
47513
|
clone.plannerList.set(set.getSetId(), v.clonePlanner(set, _this6.plannerIDCount, setData));
|
|
47343
47514
|
_this6.plannerIDCount++;
|
|
@@ -48130,7 +48301,7 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48130
48301
|
key: "initialize",
|
|
48131
48302
|
value: function () {
|
|
48132
48303
|
var _initialize = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee14(cache) {
|
|
48133
|
-
var viewReadyPromise, loadSuccessful, ret, set, _this$actions15, _this$i18n4, _this$i18n5;
|
|
48304
|
+
var viewReadyPromise, loadSuccessful, ret, set, _this$actions15, _this$i18n4, _this$i18n5, initializationId;
|
|
48134
48305
|
return _regeneratorRuntime.wrap(function _callee14$(_context14) {
|
|
48135
48306
|
while (1) switch (_context14.prev = _context14.next) {
|
|
48136
48307
|
case 0:
|
|
@@ -48156,12 +48327,14 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48156
48327
|
case 12:
|
|
48157
48328
|
loadSuccessful = _context14.sent;
|
|
48158
48329
|
if (this.plannerConfig.configuratorSessionId) {
|
|
48159
|
-
//
|
|
48330
|
+
// ID forced from outside (Landingpage, PDP, Planung-ändern)
|
|
48160
48331
|
DivaUtils.businessMetrics.setConfiguratorSessionId(this.plannerConfig.configuratorSessionId);
|
|
48161
|
-
} else {
|
|
48162
|
-
//
|
|
48163
|
-
// session stable across re-inits (e.g. switching products inside the same catalog).
|
|
48332
|
+
} else if (cache !== undefined) {
|
|
48333
|
+
// Re-init with cache (Variant Select): keep existing session stable
|
|
48164
48334
|
DivaUtils.businessMetrics.setConfiguratorSessionId(undefined, true);
|
|
48335
|
+
} else {
|
|
48336
|
+
// Fresh start (new catalog, archive basket, etc.): always new UUID
|
|
48337
|
+
DivaUtils.businessMetrics.setConfiguratorSessionId();
|
|
48165
48338
|
}
|
|
48166
48339
|
if (!loadSuccessful) {
|
|
48167
48340
|
_context14.next = 31;
|
|
@@ -48188,14 +48361,17 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48188
48361
|
this.onError(_context14.t0);
|
|
48189
48362
|
return _context14.abrupt("return", false);
|
|
48190
48363
|
case 29:
|
|
48191
|
-
_context14.next =
|
|
48364
|
+
_context14.next = 35;
|
|
48192
48365
|
break;
|
|
48193
48366
|
case 31:
|
|
48194
48367
|
this.onError();
|
|
48195
48368
|
//fehler beim laden vom basket..
|
|
48196
|
-
|
|
48369
|
+
initializationId = this.getInitializationID();
|
|
48370
|
+
LOG$2.errorTransaction('LOADING_BASKET', 'BASKET_0002', 'Fehler beim Laden des Baskets', {
|
|
48371
|
+
initializationId: initializationId
|
|
48372
|
+
}, true);
|
|
48197
48373
|
return _context14.abrupt("return", false);
|
|
48198
|
-
case
|
|
48374
|
+
case 35:
|
|
48199
48375
|
case "end":
|
|
48200
48376
|
return _context14.stop();
|
|
48201
48377
|
}
|
|
@@ -48211,7 +48387,7 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48211
48387
|
value: function () {
|
|
48212
48388
|
var _initializeSets = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee15(loadSuccessful, viewReadyPromise) {
|
|
48213
48389
|
var _this$actions17, _set$getDivaArticles, _catalogData$catalogM, _catalogData$catalogM2;
|
|
48214
|
-
var _this$actions16, _this$actions16$toggl, initSetState, set, oldProductId, _result$customData$SA, _result$customData, _result$customData2, _result$customData$SA2, _result$customData3, _result$customData4, result, _this$actions18, catalogData, initializationId,
|
|
48390
|
+
var _this$actions16, _this$actions16$toggl, initSetState, set, oldProductId, _result$customData$SA, _result$customData, _result$customData2, _result$customData$SA2, _result$customData3, _result$customData4, result, _this$actions18, catalogData, initializationId, initializationType;
|
|
48215
48391
|
return _regeneratorRuntime.wrap(function _callee15$(_context15) {
|
|
48216
48392
|
while (1) switch (_context15.prev = _context15.next) {
|
|
48217
48393
|
case 0:
|
|
@@ -48277,18 +48453,7 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48277
48453
|
}
|
|
48278
48454
|
this.subscribeToWebPlannerEvents();
|
|
48279
48455
|
catalogData = set === null || set === void 0 ? void 0 : set.CatalogData;
|
|
48280
|
-
initializationId =
|
|
48281
|
-
if (this.divaBasketHandler.initializationTypeGetter == 'PRODUCT_ID') {
|
|
48282
|
-
//KONFIGURATOR LOADED BY PRODUCT. LOG THIS HERE! WITH PRODUCT NAME AND PRODUCT ID
|
|
48283
|
-
//this._customProductId = undefined; // bsp SAP wenn CUSTOM_PRODUCT_ID
|
|
48284
|
-
initializationId = this.plannerConfig.productId;
|
|
48285
|
-
} else if (this.divaBasketHandler.initializationTypeGetter == 'ARTICLELIST') {
|
|
48286
|
-
initializationId = (_this$plannerConfig$a = this.plannerConfig.articleCodexes) === null || _this$plannerConfig$a === void 0 ? void 0 : _this$plannerConfig$a.slice();
|
|
48287
|
-
} else if (this.divaBasketHandler.initializationTypeGetter == 'CUSTOM_PRODUCT_ID') {
|
|
48288
|
-
initializationId = this.plannerConfig.customProductId;
|
|
48289
|
-
} else if (this.divaBasketHandler.initializationTypeGetter == 'SERVER_DIVANR') {
|
|
48290
|
-
initializationId = this.plannerConfig.divaNr;
|
|
48291
|
-
}
|
|
48456
|
+
initializationId = this.getInitializationID();
|
|
48292
48457
|
initializationType = this.divaBasketHandler.initializationTypeGetter;
|
|
48293
48458
|
LOG$2.successTransaction('LOADING_BASKET', {
|
|
48294
48459
|
has3D: set === null || set === void 0 ? void 0 : set.getPlannerMode(),
|
|
@@ -48312,11 +48477,11 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48312
48477
|
}, false);
|
|
48313
48478
|
this.configuratorChangeLog('onConfigurationInit', undefined, true);
|
|
48314
48479
|
this.plannerChangeLog('onInitPlanner', true);
|
|
48315
|
-
_context15.next =
|
|
48480
|
+
_context15.next = 43;
|
|
48316
48481
|
return this.fillBaksetforOnWebPlanerConfigChange(undefined, true);
|
|
48317
|
-
case
|
|
48482
|
+
case 43:
|
|
48318
48483
|
return _context15.abrupt("return", true);
|
|
48319
|
-
case
|
|
48484
|
+
case 44:
|
|
48320
48485
|
case "end":
|
|
48321
48486
|
return _context15.stop();
|
|
48322
48487
|
}
|
|
@@ -48399,11 +48564,11 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48399
48564
|
return;
|
|
48400
48565
|
}
|
|
48401
48566
|
if (onErrorHandling) {
|
|
48402
|
-
var _this$plannerConfig$
|
|
48567
|
+
var _this$plannerConfig$a2;
|
|
48403
48568
|
if (!onErrorHandling.hideErrorMsg) {
|
|
48404
|
-
var _this$plannerConfig$
|
|
48569
|
+
var _this$plannerConfig$a, _this$i18n$t, _this$i18n8, _onErrorHandling$erro;
|
|
48405
48570
|
var isWeb = this.api.getApplicationEnvironment() == 'WEB';
|
|
48406
|
-
(_this$plannerConfig$
|
|
48571
|
+
(_this$plannerConfig$a = this.plannerConfig.actions) === null || _this$plannerConfig$a === void 0 || _this$plannerConfig$a.openModal({
|
|
48407
48572
|
title: (_this$i18n$t = (_this$i18n8 = this.i18n()) === null || _this$i18n8 === void 0 ? void 0 : _this$i18n8.t((_onErrorHandling$erro = onErrorHandling.errorMsg) !== null && _onErrorHandling$erro !== void 0 ? _onErrorHandling$erro : 'modals.error_accured')) !== null && _this$i18n$t !== void 0 ? _this$i18n$t : 'An error occured. Please try again later.',
|
|
48408
48573
|
accept: true,
|
|
48409
48574
|
callback: function callback(accepted) {
|
|
@@ -48417,28 +48582,28 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
48417
48582
|
}
|
|
48418
48583
|
// `openComponent` is also a UI side-effect — gate it on the same suppression flag so
|
|
48419
48584
|
// hosts can fully opt out without having to leave it undefined.
|
|
48420
|
-
if (!suppressUi && onErrorHandling.openComponent) (_this$plannerConfig$
|
|
48585
|
+
if (!suppressUi && onErrorHandling.openComponent) (_this$plannerConfig$a2 = this.plannerConfig.actions) === null || _this$plannerConfig$a2 === void 0 || _this$plannerConfig$a2.openComponent(onErrorHandling.openComponent);
|
|
48421
48586
|
} else if (!suppressUi && this.api.getApplicationEnvironment() == 'SELLER') {
|
|
48422
48587
|
var divaNr = this.plannerConfig.divaNr;
|
|
48423
48588
|
if (divaNr) {
|
|
48424
|
-
var _this$plannerConfig$
|
|
48425
|
-
(_this$plannerConfig$
|
|
48589
|
+
var _this$plannerConfig$a3, _this$i18n9, _this$i18n10, _this$plannerConfig$a4;
|
|
48590
|
+
(_this$plannerConfig$a3 = this.plannerConfig.actions) === null || _this$plannerConfig$a3 === void 0 || _this$plannerConfig$a3.openModal({
|
|
48426
48591
|
title: (_this$i18n9 = this.i18n()) === null || _this$i18n9 === void 0 ? void 0 : _this$i18n9.t('modals.divanr_not_found_title', {
|
|
48427
48592
|
divaNr: divaNr
|
|
48428
48593
|
}),
|
|
48429
48594
|
text: (_this$i18n10 = this.i18n()) === null || _this$i18n10 === void 0 ? void 0 : _this$i18n10.t('modals.divanr_not_found_text'),
|
|
48430
48595
|
accept: true
|
|
48431
48596
|
});
|
|
48432
|
-
(_this$plannerConfig$
|
|
48597
|
+
(_this$plannerConfig$a4 = this.plannerConfig.actions) === null || _this$plannerConfig$a4 === void 0 || _this$plannerConfig$a4.openComponent({
|
|
48433
48598
|
type: 'ARCHIVE'
|
|
48434
48599
|
});
|
|
48435
48600
|
} else {
|
|
48436
|
-
var _this$plannerConfig$
|
|
48437
|
-
(_this$plannerConfig$
|
|
48601
|
+
var _this$plannerConfig$a5, _this$i18n11, _this$plannerConfig$a6, _this$plannerConfig$c;
|
|
48602
|
+
(_this$plannerConfig$a5 = this.plannerConfig.actions) === null || _this$plannerConfig$a5 === void 0 || _this$plannerConfig$a5.openModal({
|
|
48438
48603
|
accept: true,
|
|
48439
48604
|
title: (_this$i18n11 = this.i18n()) === null || _this$i18n11 === void 0 ? void 0 : _this$i18n11.t('modals.error_accured')
|
|
48440
48605
|
});
|
|
48441
|
-
(_this$plannerConfig$
|
|
48606
|
+
(_this$plannerConfig$a6 = this.plannerConfig.actions) === null || _this$plannerConfig$a6 === void 0 || _this$plannerConfig$a6.openComponent({
|
|
48442
48607
|
type: 'SELLER',
|
|
48443
48608
|
parameters: {
|
|
48444
48609
|
module: ((_this$plannerConfig$c = this.plannerConfig.currentOrganization) === null || _this$plannerConfig$c === void 0 ? void 0 : _this$plannerConfig$c.parentType) == 'SUPPLIER' ? 'Catalogs' : 'Collections'
|
|
@@ -49700,8 +49865,8 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
49700
49865
|
var doTryOptimize = plannerType == 'CUSTOMER_OPTIMIZED_PLANNER' || plannerType == 'JUMP_OVER_PLANNER_ONLY_MOBILE' || plannerType == 'JUMP_OVER_PLANNER';
|
|
49701
49866
|
//if planner is hidden by config but nothing is planned initially
|
|
49702
49867
|
if (plannerType === 'NONE') {
|
|
49703
|
-
var _this$plannerConfig$
|
|
49704
|
-
if (!this.plannerConfig.divaNr && this.plannerConfig.catalogCodex !== undefined && !((_this$plannerConfig$
|
|
49868
|
+
var _this$plannerConfig$a7, _this$actSet14;
|
|
49869
|
+
if (!this.plannerConfig.divaNr && this.plannerConfig.catalogCodex !== undefined && !((_this$plannerConfig$a7 = this.plannerConfig.articleCodexes) !== null && _this$plannerConfig$a7 !== void 0 && _this$plannerConfig$a7.length) && !this.plannerConfig.productId && !this.plannerConfig.customProductId && !this.plannerConfig.basketData && !((_this$actSet14 = this.actSet()) !== null && _this$actSet14 !== void 0 && (_this$actSet14 = _this$actSet14.CatalogData.startPlannerArticle) !== null && _this$actSet14 !== void 0 && _this$actSet14.length)) {
|
|
49705
49870
|
plannerType = 'PLANNER';
|
|
49706
49871
|
}
|
|
49707
49872
|
}
|
|
@@ -50777,7 +50942,7 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
50777
50942
|
article_nested: articles
|
|
50778
50943
|
}
|
|
50779
50944
|
});
|
|
50780
|
-
LOG$2.businessEvent('onActualBasketValue', 'Planner', 'Aktueller Basket Value:' + actualBasketvalue, {
|
|
50945
|
+
LOG$2.businessEvent('onActualBasketValue', 'Planner', 'Aktueller Basket Value: ' + actualBasketvalue, {
|
|
50781
50946
|
basketValue: actualBasketvalue,
|
|
50782
50947
|
isInit: isInit
|
|
50783
50948
|
});
|
|
@@ -50841,15 +51006,34 @@ var DivaWebPlanner = /*#__PURE__*/function () {
|
|
|
50841
51006
|
}
|
|
50842
51007
|
}
|
|
50843
51008
|
}
|
|
50844
|
-
LOG$2.businessEvent(action, 'Planner', '
|
|
51009
|
+
LOG$2.businessEvent(action, 'Planner', 'Konfigurator wurde verändert', {
|
|
50845
51010
|
explicitlySetConfiguration: explicitlySetConfiguration,
|
|
50846
51011
|
wholeConfiguration: finalConfiguration
|
|
50847
51012
|
});
|
|
50848
|
-
LOG$2.businessEvent('onActualBasketValue', 'Planner', 'Aktueller Basket Value:' + actualBasketvalue, {
|
|
51013
|
+
LOG$2.businessEvent('onActualBasketValue', 'Planner', 'Aktueller Basket Value: ' + actualBasketvalue, {
|
|
50849
51014
|
basketValue: actualBasketvalue,
|
|
50850
51015
|
isInit: isInit
|
|
50851
51016
|
});
|
|
50852
51017
|
}
|
|
51018
|
+
}, {
|
|
51019
|
+
key: "getInitializationID",
|
|
51020
|
+
value: function getInitializationID() {
|
|
51021
|
+
var initializationId = undefined;
|
|
51022
|
+
if (!this.divaBasketHandler || !this.divaBasketHandler.initializationTypeGetter) return undefined;
|
|
51023
|
+
if (this.divaBasketHandler.initializationTypeGetter == 'PRODUCT_ID') {
|
|
51024
|
+
//KONFIGURATOR LOADED BY PRODUCT. LOG THIS HERE! WITH PRODUCT NAME AND PRODUCT ID
|
|
51025
|
+
//this._customProductId = undefined; // bsp SAP wenn CUSTOM_PRODUCT_ID
|
|
51026
|
+
initializationId = this.plannerConfig.productId;
|
|
51027
|
+
} else if (this.divaBasketHandler.initializationTypeGetter == 'ARTICLELIST') {
|
|
51028
|
+
var _this$plannerConfig$a8;
|
|
51029
|
+
initializationId = (_this$plannerConfig$a8 = this.plannerConfig.articleCodexes) === null || _this$plannerConfig$a8 === void 0 ? void 0 : _this$plannerConfig$a8.slice().join(',');
|
|
51030
|
+
} else if (this.divaBasketHandler.initializationTypeGetter == 'CUSTOM_PRODUCT_ID') {
|
|
51031
|
+
initializationId = this.plannerConfig.customProductId;
|
|
51032
|
+
} else if (this.divaBasketHandler.initializationTypeGetter == 'SERVER_DIVANR') {
|
|
51033
|
+
initializationId = this.plannerConfig.divaNr;
|
|
51034
|
+
}
|
|
51035
|
+
return initializationId;
|
|
51036
|
+
}
|
|
50853
51037
|
}, {
|
|
50854
51038
|
key: "clearRegisteredFunctions",
|
|
50855
51039
|
value: function clearRegisteredFunctions() {
|