@crystaldesign/web-planner-logic 25.10.0-beta.1 → 25.10.0-beta.10

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.
Files changed (51) hide show
  1. package/build/cjs/{DivaBoxPlanner-1364c551.js → DivaBoxPlanner-04bf6318.js} +2 -2
  2. package/build/cjs/{DivaStandardPlanner-e6e39978.js → DivaStandardPlanner-77476193.js} +2 -2
  3. package/build/cjs/{DoorPlanner-10e97f07.js → DoorPlanner-f5c079a9.js} +1 -1
  4. package/build/cjs/{Host3DSignalR-eea7d1d4.js → Host3DSignalR-57e23024.js} +1 -1
  5. package/build/cjs/{LiviqueWWSHandler-17894cd1.js → LiviqueWWSHandler-47a27ec7.js} +1 -1
  6. package/build/cjs/{PfisterWWSHandler-4058e465.js → PfisterWWSHandler-e44293f5.js} +1 -1
  7. package/build/cjs/{PlannerHandler2D-41d9d0cf.js → PlannerHandler2D-be01ece6.js} +1 -1
  8. package/build/cjs/{SeriousBasketHandler-c8e698e9.js → SeriousBasketHandler-6934e260.js} +1 -1
  9. package/build/cjs/{ShelfPlanner-33014e25.js → ShelfPlanner-d409ac3e.js} +1 -1
  10. package/build/cjs/{StandardWWSHandler-faeb77e7.js → StandardWWSHandler-5dd8d94a.js} +1 -1
  11. package/build/cjs/{index-f1e5aa56.js → index-a366532b.js} +1309 -1028
  12. package/build/cjs/index.js +1 -1
  13. package/build/esm/{DivaBoxPlanner-fcf19f4c.js → DivaBoxPlanner-b09f2e76.js} +2 -2
  14. package/build/esm/{DivaStandardPlanner-5221526b.js → DivaStandardPlanner-a186b727.js} +2 -2
  15. package/build/esm/{DoorPlanner-27fa5a55.js → DoorPlanner-5bdbe66c.js} +1 -1
  16. package/build/esm/{Host3DSignalR-e85d1c87.js → Host3DSignalR-b3bc2b02.js} +1 -1
  17. package/build/esm/{LiviqueWWSHandler-494ad9a9.js → LiviqueWWSHandler-1a326919.js} +1 -1
  18. package/build/esm/{PfisterWWSHandler-39c3f3e2.js → PfisterWWSHandler-fd75b316.js} +1 -1
  19. package/build/esm/{PlannerHandler2D-1a23208c.js → PlannerHandler2D-35519ef0.js} +1 -1
  20. package/build/esm/{SeriousBasketHandler-51aa34db.js → SeriousBasketHandler-def7e867.js} +1 -1
  21. package/build/esm/{ShelfPlanner-9f2c145d.js → ShelfPlanner-ffbf54ca.js} +1 -1
  22. package/build/esm/{StandardWWSHandler-6d93ce48.js → StandardWWSHandler-91ba6b7c.js} +1 -1
  23. package/build/esm/{index-51b98cbc.js → index-949457fc.js} +1309 -1028
  24. package/build/esm/index.js +1 -1
  25. package/build/types/web-planner-logic/src/interface/ArticleOptionStateType.d.ts +2 -6
  26. package/build/types/web-planner-logic/src/interface/ArticleOptionStateType.d.ts.map +1 -1
  27. package/build/types/web-planner-logic/src/interface/OptionTypes/ArticleOptionDataTypes.d.ts +2 -7
  28. package/build/types/web-planner-logic/src/interface/OptionTypes/ArticleOptionDataTypes.d.ts.map +1 -1
  29. package/build/types/web-planner-logic/src/logic/Article/ArticleOptionState.d.ts +4 -12
  30. package/build/types/web-planner-logic/src/logic/Article/ArticleOptionState.d.ts.map +1 -1
  31. package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts +3 -5
  32. package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts.map +1 -1
  33. package/build/types/web-planner-logic/src/logic/Article/DivaArticleHandler.d.ts +1 -1
  34. package/build/types/web-planner-logic/src/logic/Article/DivaArticleHandler.d.ts.map +1 -1
  35. package/build/types/web-planner-logic/src/logic/Article/Engine/DivaArticleEngine.d.ts +1 -0
  36. package/build/types/web-planner-logic/src/logic/Article/Engine/DivaArticleEngine.d.ts.map +1 -1
  37. package/build/types/web-planner-logic/src/logic/Article/Engine/IDMArticleEngine.d.ts.map +1 -1
  38. package/build/types/web-planner-logic/src/logic/ConfigTree/DivaConfigTreeHandler.d.ts.map +1 -1
  39. package/build/types/web-planner-logic/src/model/Articles/Article/CatalogArticleData.d.ts +1 -1
  40. package/build/types/web-planner-logic/src/model/Articles/Article/DivaCatalogArticle.d.ts +1 -3
  41. package/build/types/web-planner-logic/src/model/Articles/Article/DivaCatalogArticle.d.ts.map +1 -1
  42. package/build/types/web-planner-logic/src/model/Options/ArticleOptionData.d.ts +2 -6
  43. package/build/types/web-planner-logic/src/model/Options/ArticleOptionData.d.ts.map +1 -1
  44. package/build/types/web-planner-logic/src/model/Options/ArticleOptionValueData.d.ts +2 -6
  45. package/build/types/web-planner-logic/src/model/Options/ArticleOptionValueData.d.ts.map +1 -1
  46. package/build/types/web-planner-logic/src/test/datas/environments/testing/pfister-dev.d.ts.map +1 -1
  47. package/build/types/web-planner-logic/src/test/datas/environments/testing/pfister-prod.d.ts.map +1 -1
  48. package/build/types/web-planner-logic/src/test/datas/environments/testing/retail-dev.d.ts.map +1 -1
  49. package/build/types/web-planner-logic/src/test/datas/environments/testing/retail-prod-IDM.d.ts.map +1 -1
  50. package/build/types/web-planner-logic/src/test/datas/environments/testing/retail-test.d.ts.map +1 -1
  51. package/package.json +2 -2
@@ -43,8 +43,8 @@ var _typeof__default = /*#__PURE__*/_interopDefaultLegacy(_typeof);
43
43
  })();
44
44
 
45
45
  var _excluded = ["type"];
46
- function ownKeys$l(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; }
47
- function _objectSpread$l(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$l(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$l(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
46
+ function ownKeys$j(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; }
47
+ function _objectSpread$j(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$j(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$j(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
48
48
  var LOG$p = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
49
49
  var JsonDataCache = /*#__PURE__*/function () {
50
50
  function JsonDataCache() {
@@ -255,8 +255,8 @@ var DivaApiHandler = /*#__PURE__*/function () {
255
255
  if (this.getApplicationEnvironment() == 'WEB' && (_this$apiConfig2 = this.apiConfig) !== null && _this$apiConfig2 !== void 0 && _this$apiConfig2.api2.web) {
256
256
  api2Url = this.apiConfig.api2.web;
257
257
  }
258
- _context2.t0 = _objectSpread$l;
259
- _context2.t1 = _objectSpread$l({}, init.config.headers);
258
+ _context2.t0 = _objectSpread$j;
259
+ _context2.t1 = _objectSpread$j({}, init.config.headers);
260
260
  _context2.t2 = {};
261
261
  _context2.next = 21;
262
262
  return this.getSessionGuid('V', undefined, this.OrganizationId, api2Url);
@@ -16498,6 +16498,9 @@ var OptionValueCatalogData = /*#__PURE__*/function () {
16498
16498
  }]);
16499
16499
  }();
16500
16500
 
16501
+ function _createForOfIteratorHelper$b(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$b(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
16502
+ function _unsupportedIterableToArray$b(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$b(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$b(r, a) : void 0; } }
16503
+ function _arrayLikeToArray$b(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
16501
16504
  //kaufmännischer Artikel
16502
16505
  var CatalogArticleData = /*#__PURE__*/function () {
16503
16506
  function CatalogArticleData(catalogArticle) {
@@ -17210,14 +17213,25 @@ var CatalogArticleData = /*#__PURE__*/function () {
17210
17213
  value: function getOptionValueFromOption(opt, opv) {
17211
17214
  if (this._catalogArticle.articleOptions[opt] && this._catalogArticle.articleOptions[opt].hasOPG) {
17212
17215
  var myOPGs = this._catalogArticle.articleOptions[opt].articleOptionValues;
17213
- for (var _key2 in myOPGs) {
17214
- var myOPVs = myOPGs[_key2].articleOptionValues;
17215
- if (myOPVs && myOPVs[opv]) {
17216
- return myOPVs[opv];
17216
+ var _iterator = _createForOfIteratorHelper$b(myOPGs),
17217
+ _step;
17218
+ try {
17219
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
17220
+ var _step$value = _slicedToArray__default["default"](_step.value, 2),
17221
+ _key2 = _step$value[0],
17222
+ value = _step$value[1];
17223
+ var myOPVs = value.articleOptionValues;
17224
+ if (myOPVs && myOPVs.get(opv)) {
17225
+ return myOPVs.get(opv);
17226
+ }
17217
17227
  }
17228
+ } catch (err) {
17229
+ _iterator.e(err);
17230
+ } finally {
17231
+ _iterator.f();
17218
17232
  }
17219
17233
  } else {
17220
- return this._catalogArticle.articleOptions[opt].articleOptionValues[opv];
17234
+ return this._catalogArticle.articleOptions[opt].articleOptionValues.get(opv);
17221
17235
  }
17222
17236
  return null;
17223
17237
  }
@@ -17252,8 +17266,11 @@ var CatalogArticleData = /*#__PURE__*/function () {
17252
17266
  key: "getOptionCodexFromOptionsValue",
17253
17267
  value: function getOptionCodexFromOptionsValue(opv) {
17254
17268
  if (this._catalogArticle.articleOptions) {
17255
- for (var _key3 in this._catalogArticle.articleOptions) {
17256
- if (this._catalogArticle.articleOptions[_key3].articleOptionValues[opv]) {
17269
+ for (var _i = 0, _Object$entries = Object.entries(this._catalogArticle.articleOptions); _i < _Object$entries.length; _i++) {
17270
+ var _Object$entries$_i = _slicedToArray__default["default"](_Object$entries[_i], 2),
17271
+ _key3 = _Object$entries$_i[0],
17272
+ value = _Object$entries$_i[1];
17273
+ if (value.articleOptionValues.get(opv)) {
17257
17274
  return _key3;
17258
17275
  }
17259
17276
  }
@@ -18218,6 +18235,9 @@ var ArticleOptionValueData = /*#__PURE__*/function () {
18218
18235
  }]);
18219
18236
  }();
18220
18237
 
18238
+ function _createForOfIteratorHelper$a(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$a(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
18239
+ function _unsupportedIterableToArray$a(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$a(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$a(r, a) : void 0; } }
18240
+ function _arrayLikeToArray$a(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
18221
18241
  var ArticleOptionData = /*#__PURE__*/function () {
18222
18242
  function ArticleOptionData(opt) {
18223
18243
  var _this$tabGroup;
@@ -18236,24 +18256,6 @@ var ArticleOptionData = /*#__PURE__*/function () {
18236
18256
  key: "initOPVsInOPT",
18237
18257
  value: function initOPVsInOPT(articleOptionValues) {
18238
18258
  this.opt.articleOptionValues = articleOptionValues;
18239
- for (var key in articleOptionValues) {
18240
- if (this.opt.hasOPG) {
18241
- var opg = articleOptionValues[key];
18242
- for (var key2 in opg.articleOptionValues) {
18243
- var opv = opg.articleOptionValues[key2];
18244
- if (opv.image || opv.hexColor) {
18245
- this.opt.hasImages = true;
18246
- break;
18247
- }
18248
- }
18249
- } else {
18250
- var _opv = articleOptionValues[key];
18251
- if (_opv.image || _opv.hexColor) {
18252
- this.opt.hasImages = true;
18253
- }
18254
- }
18255
- if (this.opt.hasImages) break;
18256
- }
18257
18259
  }
18258
18260
  /**************************************************GETTER ************************************************** */
18259
18261
  }, {
@@ -18330,17 +18332,28 @@ var ArticleOptionData = /*#__PURE__*/function () {
18330
18332
  }, {
18331
18333
  key: "getOpvByOcd",
18332
18334
  value: function getOpvByOcd(codex) {
18333
- for (var key in this.opt.articleOptionValues) {
18334
- var opv = this.opt.articleOptionValues[key];
18335
- if (opv.ocd == codex) {
18336
- return opv;
18337
- }
18338
- if (opv.isOPVG) {
18339
- var _opv$articleOptionVal;
18340
- return Object.values((_opv$articleOptionVal = opv.articleOptionValues) !== null && _opv$articleOptionVal !== void 0 ? _opv$articleOptionVal : {}).find(function (v) {
18341
- return v.ocd === codex;
18342
- });
18335
+ var _iterator = _createForOfIteratorHelper$a(this.opt.articleOptionValues),
18336
+ _step;
18337
+ try {
18338
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
18339
+ var _step$value = _slicedToArray__default["default"](_step.value, 2),
18340
+ key = _step$value[0],
18341
+ value = _step$value[1];
18342
+ var opv = value;
18343
+ if (opv.ocd == codex) {
18344
+ return opv;
18345
+ }
18346
+ if (opv.isOPVG) {
18347
+ var _opv$articleOptionVal, _opv$articleOptionVal2;
18348
+ return Array.from((_opv$articleOptionVal = (_opv$articleOptionVal2 = opv.articleOptionValues) === null || _opv$articleOptionVal2 === void 0 ? void 0 : _opv$articleOptionVal2.values()) !== null && _opv$articleOptionVal !== void 0 ? _opv$articleOptionVal : []).find(function (v) {
18349
+ return v.ocd === codex;
18350
+ });
18351
+ }
18343
18352
  }
18353
+ } catch (err) {
18354
+ _iterator.e(err);
18355
+ } finally {
18356
+ _iterator.f();
18344
18357
  }
18345
18358
  return undefined;
18346
18359
  }
@@ -18352,7 +18365,13 @@ var ArticleOptionData = /*#__PURE__*/function () {
18352
18365
  }, {
18353
18366
  key: "hasImages",
18354
18367
  get: function get() {
18355
- return this.opt.hasImages;
18368
+ var _this$opt$articleOpti, _this$opt$articleOpti2;
18369
+ return ((_this$opt$articleOpti = (_this$opt$articleOpti2 = this.opt.articleOptionValues) === null || _this$opt$articleOpti2 === void 0 ? void 0 : _this$opt$articleOpti2.values()) !== null && _this$opt$articleOpti !== void 0 ? _this$opt$articleOpti : []).some(function (v) {
18370
+ var _v$articleOptionValue;
18371
+ return (_v$articleOptionValue = v.articleOptionValues) === null || _v$articleOptionValue === void 0 ? void 0 : _v$articleOptionValue.values().some(function (v2) {
18372
+ return v2.image || v2.hexColor;
18373
+ });
18374
+ });
18356
18375
  }
18357
18376
  }, {
18358
18377
  key: "parentOptionCodex",
@@ -18548,8 +18567,8 @@ function addSupplierColors(catalogArticleData, allOPVsOfOPT, supplierColors, cat
18548
18567
  var articleOPG = new ArticleOptionValueData(getArticleOptionValueType('OPVSUPPLIER_COLORS', {
18549
18568
  RUL: rule
18550
18569
  }, catalogOPG, catalogArticleData, false, newOPT, catalog.multiselectOptions));
18551
- allOPVsOfOPT['OPVSUPPLIER_COLORS'] = articleOPG;
18552
- var supplierColorsOpvs = {};
18570
+ allOPVsOfOPT.set('OPVSUPPLIER_COLORS', articleOPG);
18571
+ var supplierColorsOpvs = new Map();
18553
18572
  for (var i = 0; i < supplierColors.length; i++) {
18554
18573
  var col = supplierColors[i];
18555
18574
  var colorCatalogOpv = new OptionValueCatalogData(getCatalogOptionValueDataType('OPV' + col.OptionValueCodex, {
@@ -18558,7 +18577,7 @@ function addSupplierColors(catalogArticleData, allOPVsOfOPT, supplierColors, cat
18558
18577
  HexColor: col.HexColor,
18559
18578
  GroupName: 'Lieferantenfarben'
18560
18579
  }, catalog), catalog);
18561
- supplierColorsOpvs['OPV' + col.OptionValueCodex] = new ArticleOptionValueData(getArticleOptionValueType('OPV' + col.OptionValueCodex, {}, colorCatalogOpv, catalogArticleData, true, articleOPG, catalog.multiselectOptions));
18580
+ supplierColorsOpvs.set('OPV' + col.OptionValueCodex, new ArticleOptionValueData(getArticleOptionValueType('OPV' + col.OptionValueCodex, {}, colorCatalogOpv, catalogArticleData, true, articleOPG, catalog.multiselectOptions)));
18562
18581
  }
18563
18582
  articleOPG.initOPVsInOPG(supplierColorsOpvs);
18564
18583
  }
@@ -18714,26 +18733,26 @@ function loadArticleOptions(json, catalogArticleData, set, onlyRunLogic) {
18714
18733
  if (json.OPT && json.OPT.length != 0) {
18715
18734
  for (var i = 0; i < json.OPT.length; i++) {
18716
18735
  var myOPT = json.OPT[i];
18717
- var allOPVsOfOPT = {};
18736
+ var allOPVsOfOPT = new Map();
18718
18737
  var newOPT = new ArticleOptionData(getArticleOptionType(myOPT, set));
18719
18738
 
18720
18739
  //Items initalisieren
18721
18740
  if (newOPT.hasOPG) {
18722
18741
  var _myOPT$OPV;
18723
18742
  for (var j = 0; j < myOPT.OPG.length; j++) {
18724
- var allOPVsOfOPG = {};
18743
+ var allOPVsOfOPG = new Map();
18725
18744
  var tmpOPG = myOPT.OPG[j],
18726
18745
  catOPG = set.CatalogData.getOptionValue(tmpOPG.OCD ? tmpOPG.OCD : tmpOPG.Codex);
18727
18746
  if (catOPG) {
18728
18747
  var newOPG = new ArticleOptionValueData(getArticleOptionValueType(tmpOPG.Codex, tmpOPG, catOPG, catalogArticleData, false, newOPT, multiselectOptions));
18729
- allOPVsOfOPT[tmpOPG.Codex] = newOPG;
18748
+ allOPVsOfOPT.set(tmpOPG.Codex, newOPG);
18730
18749
  for (var m = 0; m < tmpOPG.OPV.length; m++) {
18731
18750
  var tmpOPV = tmpOPG.OPV[m],
18732
18751
  catOPV = set.CatalogData.getOptionValue(tmpOPV.OCD ? tmpOPV.OCD : tmpOPV.Codex);
18733
18752
  if (catOPV) {
18734
18753
  if (!(catOPV !== null && catOPV !== void 0 && catOPV.groupName) && catOPG) catOPV.groupName = catOPG.name;
18735
18754
  var myOPV = new ArticleOptionValueData(getArticleOptionValueType(tmpOPV.Codex, tmpOPV, catOPV, catalogArticleData, true, newOPG, multiselectOptions));
18736
- allOPVsOfOPG[tmpOPV.Codex] = myOPV;
18755
+ allOPVsOfOPG.set(tmpOPV.Codex, myOPV);
18737
18756
  }
18738
18757
  }
18739
18758
  newOPG.initOPVsInOPG(allOPVsOfOPG);
@@ -18741,16 +18760,16 @@ function loadArticleOptions(json, catalogArticleData, set, onlyRunLogic) {
18741
18760
  }
18742
18761
  if ((_myOPT$OPV = myOPT.OPV) !== null && _myOPT$OPV !== void 0 && _myOPT$OPV.length) {
18743
18762
  for (var _j = 0; _j < myOPT.OPV.length; _j++) {
18744
- var _allOPVsOfOPG = {};
18763
+ var _allOPVsOfOPG = new Map();
18745
18764
  var _tmpOPG = myOPT.OPV[_j],
18746
18765
  _catOPG = set.CatalogData.getOptionValue(_tmpOPG.OCD ? _tmpOPG.OCD : _tmpOPG.Codex);
18747
18766
  if (_catOPG) {
18748
18767
  var _newOPG = new ArticleOptionValueData(getArticleOptionValueType(_tmpOPG.Codex, _tmpOPG, _catOPG, catalogArticleData, false, newOPT, multiselectOptions));
18749
- allOPVsOfOPT[_tmpOPG.Codex] = _newOPG;
18768
+ allOPVsOfOPT.set(_tmpOPG.Codex, _newOPG);
18750
18769
  var _catOPV = set.CatalogData.getOptionValue(_tmpOPG.OCD ? _tmpOPG.OCD : _tmpOPG.Codex);
18751
18770
  if (_catOPV) {
18752
18771
  var _myOPV = new ArticleOptionValueData(getArticleOptionValueType(_tmpOPG.Codex, _tmpOPG, _catOPV, catalogArticleData, true, _newOPG, multiselectOptions));
18753
- _allOPVsOfOPG[_tmpOPG.Codex] = _myOPV;
18772
+ _allOPVsOfOPG.set(_tmpOPG.Codex, _myOPV);
18754
18773
  }
18755
18774
  _newOPG.initOPVsInOPG(_allOPVsOfOPG);
18756
18775
  }
@@ -18762,12 +18781,12 @@ function loadArticleOptions(json, catalogArticleData, set, onlyRunLogic) {
18762
18781
  _catOPV2 = set.CatalogData.getOptionValue(_tmpOPV.OCD ? _tmpOPV.OCD : _tmpOPV.Codex);
18763
18782
  if (_catOPV2) {
18764
18783
  var _myOPV2 = new ArticleOptionValueData(getArticleOptionValueType(_tmpOPV.Codex, _tmpOPV, _catOPV2, catalogArticleData, true, newOPT, multiselectOptions));
18765
- allOPVsOfOPT[_tmpOPV.Codex] = _myOPV2;
18784
+ allOPVsOfOPT.set(_tmpOPV.Codex, _myOPV2);
18766
18785
  }
18767
18786
  }
18768
18787
  }
18769
18788
  if (set.supplierColors) {
18770
- var supplierColorFound = Object.values(allOPVsOfOPT).find(function (item) {
18789
+ var supplierColorFound = Array.from(allOPVsOfOPT.values()).find(function (item) {
18771
18790
  var _item$codex;
18772
18791
  return (_item$codex = item.codex) === null || _item$codex === void 0 ? void 0 : _item$codex.endsWith('OPV_FARBE_BASIS');
18773
18792
  });
@@ -18883,7 +18902,7 @@ function getArticleOptionType(myOPT, set) {
18883
18902
  return {
18884
18903
  codex: myOPT.Codex,
18885
18904
  catalogOPT: catOPT,
18886
- articleOptionValues: {},
18905
+ articleOptionValues: new Map(),
18887
18906
  pos: Number(myOPT.POS),
18888
18907
  tabGroup: myOPT.TabGroup,
18889
18908
  tabGroup_locales: myOPT.TabGroup_locales,
@@ -18892,7 +18911,6 @@ function getArticleOptionType(myOPT, set) {
18892
18911
  sendToSAP: myOPT.SendToSAP && myOPT.SendToSAP != '-1' ? myOPT.SendToSAP : undefined,
18893
18912
  articlePlaceholder: myOPT.ArticlePlaceholder,
18894
18913
  hasOPG: optHasOpg,
18895
- hasImages: false,
18896
18914
  invisible: myOPT.Invisible == 'True' ? true : myOPT.Invisible == 'False' ? false : undefined,
18897
18915
  parentOptionCodex: myOPT.ParentOptionCodex
18898
18916
  };
@@ -18992,8 +19010,8 @@ function getArticleOptionValueType(codex, jsonOPV, catalogOPV, myArticle, isPare
18992
19010
  return opv;
18993
19011
  }
18994
19012
 
18995
- function ownKeys$k(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; }
18996
- function _objectSpread$k(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$k(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$k(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
19013
+ function ownKeys$i(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; }
19014
+ function _objectSpread$i(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$i(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$i(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
18997
19015
  var LOG$k = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
18998
19016
  function loadMoreFromIDMArticles(_x, _x2) {
18999
19017
  return _loadMoreFromIDMArticles.apply(this, arguments);
@@ -19277,11 +19295,11 @@ var getPriceFeatureGroups = function getPriceFeatureGroups(catalogArticleDatas,
19277
19295
  var initializeDecision = function initializeDecision(decision, idmOptionGroups) {
19278
19296
  var _decision$optionCombi;
19279
19297
  var optionCombinations = (_decision$optionCombi = decision.optionCombinations) === null || _decision$optionCombi === void 0 ? void 0 : _decision$optionCombi.map(function (c) {
19280
- return _objectSpread$k(_objectSpread$k({}, c), {}, {
19298
+ return _objectSpread$i(_objectSpread$i({}, c), {}, {
19281
19299
  projectOptionsSetRefs: parseOptionSetRef(c.projectOptionsSetRefs, idmOptionGroups)
19282
19300
  });
19283
19301
  });
19284
- return _objectSpread$k(_objectSpread$k({}, decision), {}, {
19302
+ return _objectSpread$i(_objectSpread$i({}, decision), {}, {
19285
19303
  optionCombinations: optionCombinations === null || optionCombinations === void 0 ? void 0 : optionCombinations.sort(function (a, b) {
19286
19304
  return a.sequence - b.sequence;
19287
19305
  })
@@ -19290,11 +19308,11 @@ var initializeDecision = function initializeDecision(decision, idmOptionGroups)
19290
19308
  var initializePriceFeatureGroups = function initializePriceFeatureGroups(priceFeatureGroup, idmOptionGroups) {
19291
19309
  var _priceFeatureGroup$pr;
19292
19310
  var finishes = (_priceFeatureGroup$pr = priceFeatureGroup.projectFinishes) === null || _priceFeatureGroup$pr === void 0 ? void 0 : _priceFeatureGroup$pr.map(function (c) {
19293
- return _objectSpread$k(_objectSpread$k({}, c), {}, {
19311
+ return _objectSpread$i(_objectSpread$i({}, c), {}, {
19294
19312
  projectOptionsSetRefs: c.optionsSetRef ? parseOptionSetRef(c.optionsSetRef, idmOptionGroups) : []
19295
19313
  });
19296
19314
  });
19297
- return _objectSpread$k(_objectSpread$k({}, priceFeatureGroup), {}, {
19315
+ return _objectSpread$i(_objectSpread$i({}, priceFeatureGroup), {}, {
19298
19316
  projectFinishes: finishes === null || finishes === void 0 ? void 0 : finishes.sort(function (a, b) {
19299
19317
  return a.sequence - b.sequence;
19300
19318
  })
@@ -19410,11 +19428,10 @@ function getArticleFeatureType(feature, catalogArticleData, catOPT, set) {
19410
19428
  var opt = {
19411
19429
  codex: feature.featureNo,
19412
19430
  catalogOPT: catOPT,
19413
- articleOptionValues: {},
19431
+ articleOptionValues: new Map(),
19414
19432
  pos: feature.sequenceNo,
19415
19433
  articlePlaceholder: false,
19416
19434
  hasOPG: false,
19417
- hasImages: false,
19418
19435
  invisible: !!(featureClass !== null && featureClass !== void 0 && featureClass.featureRefs[feature.featureNo]),
19419
19436
  tabGroup: tabgroup !== null && tabgroup !== void 0 && tabgroup.name ? DivaUtils__default["default"].getLocals(tabgroup.name, set.api.getLanguage()) : undefined,
19420
19437
  tabGroup_locales: tabgroup === null || tabgroup === void 0 ? void 0 : tabgroup.name
@@ -19440,7 +19457,7 @@ function getArticleFeatureType(feature, catalogArticleData, catOPT, set) {
19440
19457
  //option in IDM language so in Diva World its OptionValue
19441
19458
  function initOption(feature, articleFeature, catalogArticle, set) {
19442
19459
  var options = feature.options;
19443
- var allOptionsOfFeature = {};
19460
+ var allOptionsOfFeature = new Map();
19444
19461
  //Items initalisieren
19445
19462
  var _loop2 = function _loop2() {
19446
19463
  var option = options[j];
@@ -19449,7 +19466,7 @@ function initOption(feature, articleFeature, catalogArticle, set) {
19449
19466
  });
19450
19467
  if (!catOption) catOption = getCatalogOptionType(option, set);
19451
19468
  var articleIDMOption = new ArticleOptionValueData(getArticleOption(option, catOption, articleFeature, catalogArticle));
19452
- allOptionsOfFeature[articleIDMOption.codex] = articleIDMOption;
19469
+ allOptionsOfFeature.set(articleIDMOption.codex, articleIDMOption);
19453
19470
  };
19454
19471
  for (var j = 0; j < options.length; j++) {
19455
19472
  _loop2();
@@ -19832,8 +19849,8 @@ function initCatalogPlannerArticleView(catalogData, catPlanArticle, catalogProps
19832
19849
  });
19833
19850
  }
19834
19851
 
19835
- function ownKeys$j(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; }
19836
- function _objectSpread$j(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$j(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$j(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
19852
+ function ownKeys$h(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; }
19853
+ function _objectSpread$h(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$h(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$h(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
19837
19854
 
19838
19855
  /*
19839
19856
  Diese KLasse enthält Inforamtion zu einem Catalog (C)
@@ -20872,7 +20889,7 @@ var DivaCatalogData = /*#__PURE__*/function () {
20872
20889
  }, {
20873
20890
  key: "setVariantsPriceByHash",
20874
20891
  value: function setVariantsPriceByHash(hash, data) {
20875
- this.variantsPriceHashObj[hash] = _objectSpread$j(_objectSpread$j({}, data), {}, {
20892
+ this.variantsPriceHashObj[hash] = _objectSpread$h(_objectSpread$h({}, data), {}, {
20876
20893
  calcTime: -1
20877
20894
  });
20878
20895
  }
@@ -21371,7 +21388,7 @@ var DivaCatalogData = /*#__PURE__*/function () {
21371
21388
  var mapMask = function mapMask(mask) {
21372
21389
  var _mappedMask$catalog;
21373
21390
  if (!mask) return undefined;
21374
- var mappedMask = _objectSpread$j({}, mask);
21391
+ var mappedMask = _objectSpread$h({}, mask);
21375
21392
  var mapProperties = function mapProperties(props) {
21376
21393
  if (Array.isArray(props)) return props;
21377
21394
  var mappedProps = [];
@@ -21400,8 +21417,8 @@ var mapMask = function mapMask(mask) {
21400
21417
  return mappedMask;
21401
21418
  };
21402
21419
 
21403
- function ownKeys$i(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; }
21404
- function _objectSpread$i(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$i(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$i(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
21420
+ function ownKeys$g(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; }
21421
+ function _objectSpread$g(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$g(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$g(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
21405
21422
  //import IDMCatalogData from '../model/Catalog/IDMCatalogData';
21406
21423
 
21407
21424
  var LOG$h = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
@@ -21619,7 +21636,7 @@ var DivaCatalogHandler = /*#__PURE__*/function () {
21619
21636
  }
21620
21637
  throw new Error('Serie not found: ' + serieNo);
21621
21638
  case 11:
21622
- catalogData = new DivaCatalogData(_objectSpread$i(_objectSpread$i({}, serieData[0]), {}, {
21639
+ catalogData = new DivaCatalogData(_objectSpread$g(_objectSpread$g({}, serieData[0]), {}, {
21623
21640
  catalogData: catalogApiData
21624
21641
  }), serieNo, orderSet, state.api, itemsList, undefined, true, additionalModelInfos);
21625
21642
  return _context4.abrupt("return", catalogData);
@@ -21666,8 +21683,11 @@ var DivaCatalogHandler = /*#__PURE__*/function () {
21666
21683
  }();
21667
21684
  var catalogHandlerInstance = new DivaCatalogHandler();
21668
21685
 
21669
- function ownKeys$h(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; }
21670
- function _objectSpread$h(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$h(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$h(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
21686
+ function ownKeys$f(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; }
21687
+ function _objectSpread$f(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$f(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$f(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
21688
+ function _createForOfIteratorHelper$9(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$9(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
21689
+ function _unsupportedIterableToArray$9(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$9(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$9(r, a) : void 0; } }
21690
+ function _arrayLikeToArray$9(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
21671
21691
  var ArticleOptionStateData = /*#__PURE__*/function () {
21672
21692
  function ArticleOptionStateData(option, getIsConfigSingle, defaultOPV, useIsOptionDefinedWarning) {
21673
21693
  _classCallCheck__default["default"](this, ArticleOptionStateData);
@@ -21679,9 +21699,9 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21679
21699
  name: '',
21680
21700
  origName: '',
21681
21701
  imageOPVs: {},
21682
- visibleOPVs: {},
21702
+ visibleOPVs: new Map(),
21683
21703
  visibleOPVKeys: [],
21684
- visibleOPVsImages: {},
21704
+ visibleOPVsImages: new Map(),
21685
21705
  favoriteOPVs: {},
21686
21706
  disabled: false,
21687
21707
  doShow: false,
@@ -21769,23 +21789,44 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21769
21789
  return opv.codex;
21770
21790
  })) !== null && _this$articleOptionSt !== void 0 ? _this$articleOptionSt : [];
21771
21791
  var option = this.option;
21772
- for (var key in option.articleOptionValues) {
21773
- if (option.articleOptionValues[key].isOPVG) {
21774
- var _option$articleOption;
21775
- var opg = (_option$articleOption = option.articleOptionValues) === null || _option$articleOption === void 0 ? void 0 : _option$articleOption[key];
21776
- for (var opvCodex in (_opg$articleOptionVal = opg.articleOptionValues) !== null && _opg$articleOptionVal !== void 0 ? _opg$articleOptionVal : {}) {
21792
+ var _iterator = _createForOfIteratorHelper$9(option.articleOptionValues),
21793
+ _step;
21794
+ try {
21795
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
21796
+ var _step$value = _slicedToArray__default["default"](_step.value, 2),
21797
+ key = _step$value[0],
21798
+ value = _step$value[1];
21799
+ if (value.isOPVG) {
21777
21800
  var _opg$articleOptionVal;
21778
- var found = opvKeys.includes(opvCodex);
21779
- if (found) {
21780
- values.push(opg.articleOptionValues[opvCodex]);
21801
+ var opg = value;
21802
+ var _iterator2 = _createForOfIteratorHelper$9((_opg$articleOptionVal = opg.articleOptionValues) !== null && _opg$articleOptionVal !== void 0 ? _opg$articleOptionVal : new Map()),
21803
+ _step2;
21804
+ try {
21805
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
21806
+ var _step2$value = _slicedToArray__default["default"](_step2.value, 2),
21807
+ opvCodex = _step2$value[0],
21808
+ opvValue = _step2$value[1];
21809
+ var found = opvKeys.includes(opvCodex);
21810
+ if (found) {
21811
+ values.push(opvValue);
21812
+ }
21813
+ }
21814
+ } catch (err) {
21815
+ _iterator2.e(err);
21816
+ } finally {
21817
+ _iterator2.f();
21818
+ }
21819
+ } else {
21820
+ var _found = opvKeys.includes(key);
21821
+ if (_found) {
21822
+ values.push(value);
21781
21823
  }
21782
- }
21783
- } else {
21784
- var _found = opvKeys.includes(key);
21785
- if (_found) {
21786
- values.push(option.articleOptionValues[key]);
21787
21824
  }
21788
21825
  }
21826
+ } catch (err) {
21827
+ _iterator.e(err);
21828
+ } finally {
21829
+ _iterator.f();
21789
21830
  }
21790
21831
  return values;
21791
21832
  }
@@ -21896,7 +21937,7 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21896
21937
  key: "updateVisibleOptionValues",
21897
21938
  value: function updateVisibleOptionValues(visibleOPVs) {
21898
21939
  this.articleOptionState.visibleOPVs = visibleOPVs;
21899
- this.articleOptionState.visibleOPVKeys = Object.keys(visibleOPVs);
21940
+ this.articleOptionState.visibleOPVKeys = Array.from(visibleOPVs.keys());
21900
21941
  }
21901
21942
  }, {
21902
21943
  key: "visibleOPVKeys",
@@ -21906,19 +21947,19 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21906
21947
  }, {
21907
21948
  key: "getVisibleOptionValue",
21908
21949
  value: function getVisibleOptionValue(codex) {
21909
- var searchValues = Object.values(this.visibleOptionValues);
21950
+ var searchValues = Array.from(this.visibleOptionValues.values());
21910
21951
  if (this.option.hasOPG) {
21911
21952
  var opgs = searchValues;
21912
21953
  for (var i = 0; i < opgs.length; i++) {
21913
- var _opgs$i$articleOption;
21914
- var valuesInOpg = Object.values((_opgs$i$articleOption = opgs[i].articleOptionValues) !== null && _opgs$i$articleOption !== void 0 ? _opgs$i$articleOption : {});
21954
+ var _opgs$i$articleOption, _opgs$i$articleOption2;
21955
+ var valuesInOpg = Array.from((_opgs$i$articleOption = (_opgs$i$articleOption2 = opgs[i].articleOptionValues) === null || _opgs$i$articleOption2 === void 0 ? void 0 : _opgs$i$articleOption2.values()) !== null && _opgs$i$articleOption !== void 0 ? _opgs$i$articleOption : []);
21915
21956
  var found = valuesInOpg.find(function (opv) {
21916
21957
  return opv.codex == codex || opv.ocd === codex;
21917
21958
  });
21918
21959
  if (found) return found;
21919
21960
  }
21920
21961
  } else {
21921
- var visibleValues = Object.values(this.visibleOptionValues);
21962
+ var visibleValues = Array.from(this.visibleOptionValues.values());
21922
21963
  var _found2 = visibleValues.find(function (opv) {
21923
21964
  return opv.codex == codex || opv.ocd === codex;
21924
21965
  });
@@ -21935,9 +21976,9 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21935
21976
  key: "editVisibleOPVsImages",
21936
21977
  value: function editVisibleOPVsImages(codex, image) {
21937
21978
  if (image) {
21938
- this.visibleOPVsImages[codex] = image;
21979
+ this.visibleOPVsImages.set(codex, image);
21939
21980
  } else {
21940
- delete this.visibleOPVsImages[codex];
21981
+ this.visibleOPVsImages["delete"](codex);
21941
21982
  }
21942
21983
  }
21943
21984
  }, {
@@ -21948,7 +21989,7 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
21948
21989
  if (this.option.hasOPG) {
21949
21990
  return this.visibleOPVKeys.reduce(function (acc, key) {
21950
21991
  var _this$visibleOptionVa, _this$visibleOptionVa2, _this$visibleOptionVa3;
21951
- return acc + ((_this$visibleOptionVa = _this.visibleOptionValues[key]) !== null && _this$visibleOptionVa !== void 0 && _this$visibleOptionVa.isOPVG ? Object.keys((_this$visibleOptionVa2 = (_this$visibleOptionVa3 = _this.visibleOptionValues[key]) === null || _this$visibleOptionVa3 === void 0 ? void 0 : _this$visibleOptionVa3.articleOptionValues) !== null && _this$visibleOptionVa2 !== void 0 ? _this$visibleOptionVa2 : {}).length : 1);
21992
+ return acc + ((_this$visibleOptionVa = _this.visibleOptionValues.get(key)) !== null && _this$visibleOptionVa !== void 0 && _this$visibleOptionVa.isOPVG ? (_this$visibleOptionVa2 = (_this$visibleOptionVa3 = _this.visibleOptionValues.get(key)) === null || _this$visibleOptionVa3 === void 0 || (_this$visibleOptionVa3 = _this$visibleOptionVa3.articleOptionValues) === null || _this$visibleOptionVa3 === void 0 ? void 0 : _this$visibleOptionVa3.size) !== null && _this$visibleOptionVa2 !== void 0 ? _this$visibleOptionVa2 : 0 : 1);
21952
21993
  }, 0);
21953
21994
  }
21954
21995
  return this.visibleOPVKeys.length;
@@ -22224,13 +22265,23 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
22224
22265
  get: function get() {
22225
22266
  if (!this.option.onlyVisibleIfNotDocked) return undefined;
22226
22267
  var ret = {};
22227
- for (var key in this.visibleOptionValues) {
22228
- var dockingPoints = this.visibleOptionValues[key].onlyVisibleIfNotDocked;
22229
- if (dockingPoints) {
22230
- ret[key] = dockingPoints.split(';');
22231
- } else {
22232
- ret[key] = [];
22268
+ var _iterator3 = _createForOfIteratorHelper$9(this.visibleOptionValues.keys()),
22269
+ _step3;
22270
+ try {
22271
+ for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
22272
+ var _this$visibleOptionVa4;
22273
+ var key = _step3.value;
22274
+ var dockingPoints = (_this$visibleOptionVa4 = this.visibleOptionValues.get(key)) === null || _this$visibleOptionVa4 === void 0 ? void 0 : _this$visibleOptionVa4.onlyVisibleIfNotDocked;
22275
+ if (dockingPoints) {
22276
+ ret[key] = dockingPoints.split(';');
22277
+ } else {
22278
+ ret[key] = [];
22279
+ }
22233
22280
  }
22281
+ } catch (err) {
22282
+ _iterator3.e(err);
22283
+ } finally {
22284
+ _iterator3.f();
22234
22285
  }
22235
22286
  return Object.entries(ret).length ? ret : undefined;
22236
22287
  }
@@ -22370,19 +22421,17 @@ var ArticleOptionStateData = /*#__PURE__*/function () {
22370
22421
  key: "cloneOptionState",
22371
22422
  value: function cloneOptionState(getIsConfigSingle) {
22372
22423
  var clonedOps = new ArticleOptionStateData(this.option, getIsConfigSingle);
22373
- clonedOps.articleOptionState = _objectSpread$h(_objectSpread$h({}, this.articleOptionState), {}, {
22374
- imageOPVs: _objectSpread$h({}, this.articleOptionState.imageOPVs),
22375
- visibleOPVs: _objectSpread$h({}, this.articleOptionState.visibleOPVs),
22376
- visibleOPVsImages: _objectSpread$h({}, this.articleOptionState.visibleOPVsImages),
22377
- favoriteOPVs: _objectSpread$h({}, this.articleOptionState.favoriteOPVs)
22424
+ clonedOps.articleOptionState = _objectSpread$f(_objectSpread$f({}, this.articleOptionState), {}, {
22425
+ imageOPVs: _objectSpread$f({}, this.articleOptionState.imageOPVs),
22426
+ visibleOPVs: new Map(this.articleOptionState.visibleOPVs),
22427
+ visibleOPVsImages: new Map(this.articleOptionState.visibleOPVsImages),
22428
+ favoriteOPVs: _objectSpread$f({}, this.articleOptionState.favoriteOPVs)
22378
22429
  });
22379
22430
  return clonedOps;
22380
22431
  }
22381
22432
  }]);
22382
22433
  }();
22383
22434
 
22384
- function ownKeys$g(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; }
22385
- function _objectSpread$g(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$g(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$g(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
22386
22435
  function _createForOfIteratorHelper$8(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$8(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
22387
22436
  function _unsupportedIterableToArray$8(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$8(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$8(r, a) : void 0; } }
22388
22437
  function _arrayLikeToArray$8(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
@@ -22404,7 +22453,7 @@ var DivaEngine = /*#__PURE__*/function () {
22404
22453
  var maxPriceOfGroup = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
22405
22454
  var maxPriceOfGroupCodex = ['', '', '', '', '', '', '', '', '', ''];
22406
22455
  var previousVaraintValues = this.article.VariantValues;
22407
- var _iterator = _createForOfIteratorHelper$8(this.article.articleOptionStates),
22456
+ var _iterator = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
22408
22457
  _step;
22409
22458
  try {
22410
22459
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -22419,48 +22468,79 @@ var DivaEngine = /*#__PURE__*/function () {
22419
22468
 
22420
22469
  var foundFirstItem = false;
22421
22470
  var setDefaultOPV = ops.defaultOPV;
22422
- ops.updateVisibleOptionValues({});
22423
- var visibleOptionValues = {};
22471
+ ops.updateVisibleOptionValues(new Map());
22472
+ var visibleOptionValues = new Map();
22424
22473
  if (myOpt.hasOPG) {
22425
22474
  var myOPGs = myOpt.articleOptionValues;
22426
- for (var lKey in myOPGs) {
22427
- var myOPVsInOPG = myOPGs[lKey].articleOptionValues;
22428
- if (this.checkItemVisibility(myOPGs[lKey], ops) && myOPVsInOPG) {
22429
- visibleOptionValues[myOPGs[lKey].codex] = myOPGs[lKey];
22430
- for (var opvCodex in myOPVsInOPG) {
22431
- var tmpOPV = myOPVsInOPG[opvCodex];
22432
- if (tmpOPV.hiddenByMask) continue;
22433
- visibleItems[OP + '#' + opvCodex] = tmpOPV;
22434
- if (!ops.getConstructionRulesIsDisablingByOPVCodex(opvCodex)) {
22435
- if (setDefaultOPV && setDefaultOPV == opvCodex) {
22436
- firstVisibleItem = tmpOPV;
22437
- foundFirstItem = true;
22438
- } else if (!foundFirstItem) {
22439
- firstVisibleItem = tmpOPV;
22440
- foundFirstItem = true;
22475
+ var _iterator2 = _createForOfIteratorHelper$8(myOPGs),
22476
+ _step2;
22477
+ try {
22478
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
22479
+ var _step2$value = _slicedToArray__default["default"](_step2.value, 2),
22480
+ lKey = _step2$value[0],
22481
+ value = _step2$value[1];
22482
+ var myOPVsInOPG = value.articleOptionValues;
22483
+ if (this.checkItemVisibility(value, ops) && myOPVsInOPG) {
22484
+ visibleOptionValues.set(value.codex, value);
22485
+ var _iterator3 = _createForOfIteratorHelper$8(myOPVsInOPG),
22486
+ _step3;
22487
+ try {
22488
+ for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
22489
+ var _step3$value = _slicedToArray__default["default"](_step3.value, 2),
22490
+ opvCodex = _step3$value[0],
22491
+ tmpOPV = _step3$value[1];
22492
+ if (tmpOPV.hiddenByMask) continue;
22493
+ visibleItems[OP + '#' + opvCodex] = tmpOPV;
22494
+ if (!ops.getConstructionRulesIsDisablingByOPVCodex(opvCodex)) {
22495
+ if (setDefaultOPV && setDefaultOPV == opvCodex) {
22496
+ firstVisibleItem = tmpOPV;
22497
+ foundFirstItem = true;
22498
+ } else if (!foundFirstItem) {
22499
+ firstVisibleItem = tmpOPV;
22500
+ foundFirstItem = true;
22501
+ }
22502
+ }
22441
22503
  }
22504
+ } catch (err) {
22505
+ _iterator3.e(err);
22506
+ } finally {
22507
+ _iterator3.f();
22442
22508
  }
22443
22509
  }
22444
22510
  }
22511
+ } catch (err) {
22512
+ _iterator2.e(err);
22513
+ } finally {
22514
+ _iterator2.f();
22445
22515
  }
22446
22516
  } else {
22447
22517
  var myOPVs = myOpt.articleOptionValues;
22448
22518
  if (myOPVs) {
22449
- for (var opvCodex in myOPVs) {
22450
- var tmpOPV = myOPVs[opvCodex];
22451
- if (!tmpOPV.hiddenByMask && this.checkItemVisibility(tmpOPV, ops)) {
22452
- visibleOptionValues[tmpOPV.codex] = tmpOPV;
22453
- visibleItems[OP + '#' + opvCodex] = tmpOPV;
22454
- if (!ops.getConstructionRulesIsDisablingByOPVCodex(opvCodex)) {
22455
- if (setDefaultOPV && setDefaultOPV == opvCodex) {
22456
- firstVisibleItem = tmpOPV;
22457
- foundFirstItem = true;
22458
- } else if (!foundFirstItem) {
22459
- firstVisibleItem = tmpOPV;
22460
- foundFirstItem = true;
22519
+ var _iterator4 = _createForOfIteratorHelper$8(myOPVs),
22520
+ _step4;
22521
+ try {
22522
+ for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
22523
+ var _step4$value = _slicedToArray__default["default"](_step4.value, 2),
22524
+ _opvCodex = _step4$value[0],
22525
+ _tmpOPV = _step4$value[1];
22526
+ if (!_tmpOPV.hiddenByMask && this.checkItemVisibility(_tmpOPV, ops)) {
22527
+ visibleOptionValues.set(_tmpOPV.codex, _tmpOPV);
22528
+ visibleItems[OP + '#' + _opvCodex] = _tmpOPV;
22529
+ if (!ops.getConstructionRulesIsDisablingByOPVCodex(_opvCodex)) {
22530
+ if (setDefaultOPV && setDefaultOPV == _opvCodex) {
22531
+ firstVisibleItem = _tmpOPV;
22532
+ foundFirstItem = true;
22533
+ } else if (!foundFirstItem) {
22534
+ firstVisibleItem = _tmpOPV;
22535
+ foundFirstItem = true;
22536
+ }
22461
22537
  }
22462
22538
  }
22463
22539
  }
22540
+ } catch (err) {
22541
+ _iterator4.e(err);
22542
+ } finally {
22543
+ _iterator4.f();
22464
22544
  }
22465
22545
  }
22466
22546
  }
@@ -22503,7 +22583,7 @@ var DivaEngine = /*#__PURE__*/function () {
22503
22583
  if (_ops !== null && _ops !== void 0 && _ops.valCodex) {
22504
22584
  var foundItem = _this.article.checkOptionAndOptionValue(_ops.optionCodex, _ops.valCodex);
22505
22585
  if ((foundItem === null || foundItem === void 0 ? void 0 : foundItem.opv) instanceof ArticleOptionValueData) {
22506
- if (_ops.visibleOptionValues[foundItem.opv.codex] || _ops.visibleOptionValues[foundItem.opv.parentCodex]) {
22586
+ if (_ops.visibleOptionValues.get(foundItem.opv.codex) || _ops.visibleOptionValues.get(foundItem.opv.parentCodex)) {
22507
22587
  myItem = foundItem.opv;
22508
22588
  }
22509
22589
  }
@@ -22518,8 +22598,8 @@ var DivaEngine = /*#__PURE__*/function () {
22518
22598
  //sonst myItem aus default sibling option versuchen zu verwenden
22519
22599
  if (myItem == null && ops.option.isDefaultSiblingOption) {
22520
22600
  var siblingsPreviousOpv = previousVaraintValues['OPT' + ops.option.isDefaultSiblingOption];
22521
- if (siblingsPreviousOpv && ops.visibleOptionValues[siblingsPreviousOpv]) {
22522
- myItem = ops.visibleOptionValues[siblingsPreviousOpv];
22601
+ if (siblingsPreviousOpv && ops.visibleOptionValues.get(siblingsPreviousOpv)) {
22602
+ myItem = ops.visibleOptionValues.get(siblingsPreviousOpv);
22523
22603
  }
22524
22604
  }
22525
22605
  if (myItem == null && !ops.defaultOPV) {
@@ -22602,8 +22682,19 @@ var DivaEngine = /*#__PURE__*/function () {
22602
22682
  //R (Anschlusstyp R) - AVR
22603
22683
  var newAVRFilter = [],
22604
22684
  visibleOPVs = ops.visibleOptionValues;
22605
- for (var key in visibleOPVs) {
22606
- newAVRFilter.push(visibleOPVs[key].codex.substring(3));
22685
+ var _iterator5 = _createForOfIteratorHelper$8(visibleOPVs),
22686
+ _step5;
22687
+ try {
22688
+ for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
22689
+ var _step5$value = _slicedToArray__default["default"](_step5.value, 2),
22690
+ key = _step5$value[0],
22691
+ value = _step5$value[1];
22692
+ newAVRFilter.push(value.codex.substring(3));
22693
+ }
22694
+ } catch (err) {
22695
+ _iterator5.e(err);
22696
+ } finally {
22697
+ _iterator5.f();
22607
22698
  }
22608
22699
  this.article.newPossibleAVRFilters = newAVRFilter;
22609
22700
  }
@@ -22611,8 +22702,19 @@ var DivaEngine = /*#__PURE__*/function () {
22611
22702
  //L (Anschlusstyp L) - AVL
22612
22703
  var newAVLFilter = [],
22613
22704
  _visibleOPVs = ops.visibleOptionValues;
22614
- for (var key in _visibleOPVs) {
22615
- newAVLFilter.push(_visibleOPVs[key].codex.substring(3));
22705
+ var _iterator6 = _createForOfIteratorHelper$8(_visibleOPVs),
22706
+ _step6;
22707
+ try {
22708
+ for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
22709
+ var _step6$value = _slicedToArray__default["default"](_step6.value, 2),
22710
+ _key = _step6$value[0],
22711
+ _value = _step6$value[1];
22712
+ newAVLFilter.push(_value.codex.substring(3));
22713
+ }
22714
+ } catch (err) {
22715
+ _iterator6.e(err);
22716
+ } finally {
22717
+ _iterator6.f();
22616
22718
  }
22617
22719
  this.article.newPossibleAVLFilters = newAVLFilter;
22618
22720
  }
@@ -22831,18 +22933,18 @@ var DivaEngine = /*#__PURE__*/function () {
22831
22933
  myDecisions[i].disableHistory = [];
22832
22934
  myDecisions[i].activeCombination = undefined;
22833
22935
  }
22834
- var _iterator2 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
22835
- _step2;
22936
+ var _iterator7 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
22937
+ _step7;
22836
22938
  try {
22837
- for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
22838
- var ops = _step2.value;
22839
- ops.updateVisibleOptionValues(_objectSpread$g({}, ops.option.articleOptionValues));
22939
+ for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {
22940
+ var ops = _step7.value;
22941
+ ops.updateVisibleOptionValues(ops.option.articleOptionValues);
22840
22942
  ops.definedBySetFeatureFixed = false;
22841
22943
  }
22842
22944
  } catch (err) {
22843
- _iterator2.e(err);
22945
+ _iterator7.e(err);
22844
22946
  } finally {
22845
- _iterator2.f();
22947
+ _iterator7.f();
22846
22948
  }
22847
22949
  this.decisionDebugStack = [];
22848
22950
  var beforeSnapshot = this.article.set.logDecisions ? this.article.snapshot : undefined;
@@ -22970,18 +23072,18 @@ var DivaEngine = /*#__PURE__*/function () {
22970
23072
  key: "updateIDMSpecificFeatures",
22971
23073
  value: function updateIDMSpecificFeatures() {
22972
23074
  //updaten idm planner specific options
22973
- var _iterator3 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
22974
- _step3;
23075
+ var _iterator8 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
23076
+ _step8;
22975
23077
  try {
22976
- for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
22977
- var ops = _step3.value;
23078
+ for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
23079
+ var ops = _step8.value;
22978
23080
  //when an option has no decisions the first visible optionValue has to be selected per default
22979
23081
  if (ops.val === undefined && ops.visibleCount && !this.article.CatalogData.useDiomexConfigLogic) {
22980
23082
  this.assignOptionValue(ops.optionCodex, ops.visibleOPVKeys[0]);
22981
23083
  }
22982
23084
  if (ops.visibleCount && ops.IsIDMSpecialFeature) {
22983
23085
  var _validOpv;
22984
- var validOpvs = Object.values(ops.visibleOptionValues);
23086
+ var validOpvs = Array.from(ops.visibleOptionValues.values());
22985
23087
  if (ops.val) validOpvs.unshift(ops.val);
22986
23088
  var validOpv = undefined;
22987
23089
  for (var i = 0; i < validOpvs.length; i++) {
@@ -22995,9 +23097,9 @@ var DivaEngine = /*#__PURE__*/function () {
22995
23097
  }
22996
23098
  }
22997
23099
  } catch (err) {
22998
- _iterator3.e(err);
23100
+ _iterator8.e(err);
22999
23101
  } finally {
23000
- _iterator3.f();
23102
+ _iterator8.f();
23001
23103
  }
23002
23104
  }
23003
23105
  }, {
@@ -23160,201 +23262,219 @@ var DivaEngine = /*#__PURE__*/function () {
23160
23262
  }, {
23161
23263
  key: "evalType1Decision",
23162
23264
  value: function evalType1Decision(myDecision) {
23265
+ var _this2 = this;
23163
23266
  var validOPVs = {};
23164
23267
  var doAlsoCheckOPTs = [];
23165
- if (myDecision.Options && myDecision.DOC) for (var p = 0; p < myDecision.Options.length; p++) {
23166
- var OPT = myDecision.Options[p];
23167
- var ops = this.article.getArticleOptionStateFlat(OPT);
23168
- if (!ops) break;
23169
- if (!validOPVs[OPT]) validOPVs[OPT] = {};
23170
- var possibleOPVs = ops.visibleOptionValues;
23171
- //welche Optionen sind auch zu prüfen?
23268
+ if (myDecision.Options && myDecision.DOC) {
23269
+ var _loop2 = function _loop2() {
23270
+ var OPT = myDecision.Options[p];
23271
+ var ops = _this2.article.getArticleOptionStateFlat(OPT);
23272
+ if (!ops) return 1; // break
23273
+ if (!validOPVs[OPT]) validOPVs[OPT] = new Map();
23274
+ var possibleOPVs = new Map(ops.visibleOptionValues);
23275
+ //welche Optionen sind auch zu prüfen?
23172
23276
 
23173
- for (var j = 0; j < myDecision.DOC.length; j++) {
23174
- //DecisionOptionCombination
23175
- //wenn diese Row mehrere Optionen hat, dann müssen die bisher gesetzten schon übereinstimmen
23277
+ for (var j = 0; j < myDecision.DOC.length; j++) {
23278
+ //DecisionOptionCombination
23279
+ //wenn diese Row mehrere Optionen hat, dann müssen die bisher gesetzten schon übereinstimmen
23176
23280
 
23177
- var doUseDoc = true;
23178
- var myDoc = myDecision.DOC[j];
23179
- if (doAlsoCheckOPTs.length > 0) {
23180
- for (var f = 0; f < doAlsoCheckOPTs.length; f++) {
23281
+ var myDoc = myDecision.DOC[j];
23282
+ var doUseDoc = _this2.checkIfDocIsValid(myDoc, doAlsoCheckOPTs);
23283
+ if (doUseDoc) {
23181
23284
  var _myDoc$Row;
23182
- var checkOptX = doAlsoCheckOPTs[f];
23183
- var _ops3 = this.article.getArticleOptionState(checkOptX);
23184
- if (_ops3 && (_myDoc$Row = myDoc.Row) !== null && _myDoc$Row !== void 0 && _myDoc$Row[checkOptX] && _ops3.valCodex && !myDoc.Row[checkOptX].includes(_ops3.valCodex)) {
23185
- if (!myDoc.Row[checkOptX].find(function (o) {
23186
- return !o.startsWith('!');
23187
- })) {
23188
- //all is inverted
23189
- if (myDoc.Row[checkOptX].includes('!' + _ops3.valCodex)) {
23190
- doUseDoc = false;
23191
- break;
23192
- }
23193
- } else {
23194
- doUseDoc = false;
23195
- break;
23196
- }
23197
- }
23198
- }
23199
- }
23200
- if (doUseDoc) {
23201
- var _myDoc$Row2;
23202
- myDecision.activeCombination = j;
23203
- if ((_myDoc$Row2 = myDoc.Row) !== null && _myDoc$Row2 !== void 0 && _myDoc$Row2[OPT]) {
23204
- var ruleWasValidOnce = false;
23205
- for (var m = 0; m < myDoc.Row[OPT].length; m++) {
23206
- var opvCodex = myDoc.Row[OPT][m];
23207
- if (opvCodex.startsWith('!')) {
23208
- //this should only delete the value when all the following options match the values
23209
- //https://app.asana.com/0/search?q=nin&child=1203078926793962
23210
- //https://app.asana.com/0/1203759050701666/1203780404115819
23211
-
23212
- var ruleValid = true;
23213
- var _loop2 = function _loop2() {
23214
- if (key === OPT) return 0; // continue
23285
+ myDecision.activeCombination = j;
23286
+ if ((_myDoc$Row = myDoc.Row) !== null && _myDoc$Row !== void 0 && _myDoc$Row[OPT]) {
23287
+ var ruleWasValidOnce = false;
23288
+ for (var m = 0; m < myDoc.Row[OPT].length; m++) {
23289
+ var opvCodex = myDoc.Row[OPT][m];
23290
+ if (opvCodex.startsWith('!')) {
23291
+ //this should only delete the value when all the following options match the values
23292
+ //https://app.asana.com/0/search?q=nin&child=1203078926793962
23293
+ //https://app.asana.com/0/1203759050701666/1203780404115819
23215
23294
 
23216
- // Cache the row values array
23217
- var rowValues = myDoc.Row[key];
23295
+ var ruleValid = true;
23296
+ for (var key in myDoc.Row) {
23297
+ if (key === OPT) continue;
23218
23298
 
23219
- // Use some() to break early when match found
23220
- var hasMatch = ops.visibleOPVKeys.some(function (opv) {
23221
- return rowValues.includes(opv);
23299
+ // Converting array to Set is O(n) but only done once. Then each lookup is O(1) instead of O(n) for includes() (total O(n))
23300
+ var rowValuesSet = new Set(myDoc.Row[key]);
23301
+ var hasMatch = _toConsumableArray__default["default"](rowValuesSet).some(function (v) {
23302
+ return ops.visibleOptionValues.has(v);
23222
23303
  });
23223
23304
  if (!hasMatch) {
23224
23305
  ruleValid = false;
23225
- return 1; // break
23306
+ break;
23226
23307
  }
23227
- },
23228
- _ret;
23229
- for (var key in myDoc.Row) {
23230
- _ret = _loop2();
23231
- if (_ret === 0) continue;
23232
- if (_ret === 1) break;
23233
- }
23234
- if (ruleValid) {
23308
+ }
23309
+ if (ruleValid) {
23310
+ ruleWasValidOnce = true;
23311
+ if (m == 0) validOPVs[OPT] = new Map(possibleOPVs);
23312
+ opvCodex = opvCodex.slice(1);
23313
+ if (possibleOPVs.get(opvCodex)) validOPVs[OPT]["delete"](opvCodex);
23314
+ }
23315
+ } else {
23235
23316
  ruleWasValidOnce = true;
23236
- if (m == 0) validOPVs[OPT] = _objectSpread$g({}, possibleOPVs);
23237
- opvCodex = opvCodex.slice(1);
23238
- if (possibleOPVs[opvCodex] != null) delete validOPVs[OPT][opvCodex];
23317
+ var opv = possibleOPVs.get(opvCodex);
23318
+ if (opv) validOPVs[OPT].set(opvCodex, opv);
23239
23319
  }
23240
- } else {
23241
- ruleWasValidOnce = true;
23242
- if (possibleOPVs[opvCodex] != null) validOPVs[OPT][opvCodex] = possibleOPVs[opvCodex];
23243
23320
  }
23244
- }
23245
- if (!ruleWasValidOnce) {
23246
- //add the rest
23247
- if (myDoc.Row[OPT][0].includes('!')) {
23248
- for (var opv in ops.visibleOptionValues) {
23249
- var doesNotExists = myDoc.Row[OPT].includes('!' + opv);
23250
- if (!doesNotExists) validOPVs[OPT][opv] = ops.visibleOptionValues[opv];
23321
+ if (!ruleWasValidOnce) {
23322
+ //add the rest
23323
+ if (myDoc.Row[OPT][0].includes('!')) {
23324
+ var negatedValues = new Set(myDoc.Row[OPT].map(function (v) {
23325
+ return v.slice(1);
23326
+ })); // remove the '!' from the value
23327
+ var _iterator9 = _createForOfIteratorHelper$8(ops.visibleOptionValues),
23328
+ _step9;
23329
+ try {
23330
+ for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
23331
+ var _step9$value = _slicedToArray__default["default"](_step9.value, 2),
23332
+ opvKey = _step9$value[0],
23333
+ _opv = _step9$value[1];
23334
+ if (!negatedValues.has(opvKey)) {
23335
+ validOPVs[OPT].set(opvKey, _opv);
23336
+ }
23337
+ }
23338
+ } catch (err) {
23339
+ _iterator9.e(err);
23340
+ } finally {
23341
+ _iterator9.f();
23342
+ }
23343
+ } else {
23344
+ validOPVs[OPT] = new Map(ops.visibleOptionValues);
23251
23345
  }
23252
- } else {
23253
- validOPVs[OPT] = Object.assign({}, ops.visibleOptionValues);
23254
23346
  }
23347
+ } else {
23348
+ validOPVs[OPT] = possibleOPVs;
23255
23349
  }
23256
- } else {
23257
- validOPVs[OPT] = possibleOPVs;
23258
23350
  }
23259
23351
  }
23260
- }
23261
- var schnittmenge = {};
23262
- for (var _key in possibleOPVs) {
23263
- if (validOPVs[OPT][_key]) {
23264
- schnittmenge[_key] = possibleOPVs[_key];
23352
+ var schnittmenge = new Map(Array.from(possibleOPVs).filter(function (_ref2) {
23353
+ var _ref3 = _slicedToArray__default["default"](_ref2, 1),
23354
+ key = _ref3[0];
23355
+ return validOPVs[OPT].has(key);
23356
+ }));
23357
+ ops.updateVisibleOptionValues(new Map(schnittmenge));
23358
+ var valCodex = ops.valCodex;
23359
+ if ((!valCodex || !schnittmenge.get(valCodex)) && ops.visibleOPVKeys.length > 0) {
23360
+ if (_this2.article.CatalogData.useDiomexConfigLogic) {
23361
+ _this2.clearOP(OPT, true);
23362
+ } else {
23363
+ _this2.updateArtOPV(_this2.article.getDefaultOpv(schnittmenge), OPT, ops, undefined);
23364
+ }
23265
23365
  }
23366
+ doAlsoCheckOPTs.push(OPT);
23367
+ //Hier führende Optionen prüfen
23368
+ };
23369
+ for (var p = 0; p < myDecision.Options.length; p++) {
23370
+ if (_loop2()) break;
23266
23371
  }
23267
- ops.updateVisibleOptionValues(_objectSpread$g({}, schnittmenge));
23268
- var valCodex = ops.valCodex;
23269
- if ((!valCodex || !schnittmenge[valCodex]) && ops.visibleOPVKeys.length > 0) {
23270
- if (this.article.CatalogData.useDiomexConfigLogic) {
23271
- this.clearOP(OPT, true);
23372
+ }
23373
+ }
23374
+ }, {
23375
+ key: "checkIfDocIsValid",
23376
+ value: function checkIfDocIsValid(myDoc, doAlsoCheckOPTs) {
23377
+ if (doAlsoCheckOPTs.length === 0) return true;
23378
+ for (var f = 0; f < doAlsoCheckOPTs.length; f++) {
23379
+ var _myDoc$Row2;
23380
+ var checkOptX = doAlsoCheckOPTs[f];
23381
+ var ops = this.article.getArticleOptionState(checkOptX);
23382
+ if (ops && (_myDoc$Row2 = myDoc.Row) !== null && _myDoc$Row2 !== void 0 && _myDoc$Row2[checkOptX] && ops.valCodex && !myDoc.Row[checkOptX].includes(ops.valCodex)) {
23383
+ if (!myDoc.Row[checkOptX].find(function (o) {
23384
+ return !o.startsWith('!');
23385
+ })) {
23386
+ //all is inverted
23387
+ if (myDoc.Row[checkOptX].includes('!' + ops.valCodex)) {
23388
+ return false;
23389
+ }
23272
23390
  } else {
23273
- this.updateArtOPV(this.article.getDefaultOpv(schnittmenge), OPT, ops, undefined);
23391
+ return false;
23274
23392
  }
23275
23393
  }
23276
- doAlsoCheckOPTs.push(OPT);
23277
- //Hier führende Optionen prüfen
23278
23394
  }
23395
+ return true;
23279
23396
  }
23280
23397
  }, {
23281
23398
  key: "evalType0Decision",
23282
23399
  value: function evalType0Decision(myDecision) {
23400
+ var _this3 = this;
23283
23401
  var invalidOPVs = {},
23284
23402
  doAlsoCheckOPTs = [];
23285
- if (myDecision.Options && myDecision.Options.length > 1 && myDecision.DOC) for (var p = 0; p < myDecision.Options.length; p++) {
23286
- var OPT = myDecision.Options[p];
23287
- var ops = this.article.getArticleOptionStateFlat(OPT);
23288
- if (!ops) break;
23289
- if (!invalidOPVs[OPT]) invalidOPVs[OPT] = {};
23290
- var possibleOPVs = ops.visibleOptionValues;
23291
- //Erste Option ist immer eine Bedingung!
23292
- if (p === myDecision.Options.length - 1 && myDecision.DOC) {
23293
- for (var j = 0; j < myDecision.DOC.length; j++) {
23294
- //DecisionOptionCombination
23295
- //wenn diese Row mehrere Optionen hat, dann müssen die bisher gesetzten schon übereinstimmen
23296
- // z.B. bei OPT2 muss OPT1 stimmen
23297
- // und bei OPT3 muss OPT1 und OPT2 stimmen
23298
- var doUseDoc = true,
23299
- myDoc = myDecision.DOC[j];
23300
- if (doAlsoCheckOPTs.length > 0) {
23301
- for (var f = 0; f < doAlsoCheckOPTs.length; f++) {
23302
- var _myDoc$Row3;
23303
- var checkOptX = doAlsoCheckOPTs[f];
23304
- var _ops4 = this.article.getArticleOptionState(checkOptX);
23305
- if (_ops4 && (_myDoc$Row3 = myDoc.Row) !== null && _myDoc$Row3 !== void 0 && _myDoc$Row3[checkOptX] && _ops4.valCodex && !myDoc.Row[checkOptX].includes(_ops4.valCodex)) {
23306
- doUseDoc = false;
23307
- break;
23403
+ if (myDecision.Options && myDecision.Options.length > 1 && myDecision.DOC) {
23404
+ var _loop3 = function _loop3() {
23405
+ var OPT = myDecision.Options[p];
23406
+ var ops = _this3.article.getArticleOptionStateFlat(OPT);
23407
+ if (!ops) return 1; // break
23408
+ if (!invalidOPVs[OPT]) invalidOPVs[OPT] = new Map();
23409
+ var possibleOPVs = ops.visibleOptionValues;
23410
+ //Erste Option ist immer eine Bedingung!
23411
+ if (p === myDecision.Options.length - 1 && myDecision.DOC) {
23412
+ for (var j = 0; j < myDecision.DOC.length; j++) {
23413
+ //DecisionOptionCombination
23414
+ //wenn diese Row mehrere Optionen hat, dann müssen die bisher gesetzten schon übereinstimmen
23415
+ // z.B. bei OPT2 muss OPT1 stimmen
23416
+ // und bei OPT3 muss OPT1 und OPT2 stimmen
23417
+ var doUseDoc = true,
23418
+ myDoc = myDecision.DOC[j];
23419
+ if (doAlsoCheckOPTs.length > 0) {
23420
+ for (var f = 0; f < doAlsoCheckOPTs.length; f++) {
23421
+ var _myDoc$Row3;
23422
+ var checkOptX = doAlsoCheckOPTs[f];
23423
+ var _ops3 = _this3.article.getArticleOptionState(checkOptX);
23424
+ if (_ops3 && (_myDoc$Row3 = myDoc.Row) !== null && _myDoc$Row3 !== void 0 && _myDoc$Row3[checkOptX] && _ops3.valCodex && !myDoc.Row[checkOptX].includes(_ops3.valCodex)) {
23425
+ doUseDoc = false;
23426
+ break;
23427
+ }
23308
23428
  }
23309
23429
  }
23310
- }
23311
- if (doUseDoc && myDoc.Row) {
23312
- myDecision.activeCombination = j;
23313
- if (myDoc.Row[OPT]) {
23314
- for (var m = 0; m < myDoc.Row[OPT].length; m++) {
23315
- var opvCodex = myDoc.Row[OPT][m];
23316
- var myOPVData = possibleOPVs[opvCodex];
23317
- if (myOPVData != null) {
23318
- invalidOPVs[OPT][opvCodex] = myOPVData; //wenn es eine DecisionType 0 ist muss ich diese OPV von den gültigen entfernen
23430
+ if (doUseDoc && myDoc.Row) {
23431
+ myDecision.activeCombination = j;
23432
+ if (myDoc.Row[OPT]) {
23433
+ for (var m = 0; m < myDoc.Row[OPT].length; m++) {
23434
+ var opvCodex = myDoc.Row[OPT][m];
23435
+ var myOPVData = possibleOPVs.get(opvCodex);
23436
+ if (myOPVData != null) {
23437
+ invalidOPVs[OPT].set(opvCodex, myOPVData); //wenn es eine DecisionType 0 ist muss ich diese OPV von den gültigen entfernen
23438
+ }
23319
23439
  }
23320
23440
  }
23321
23441
  }
23322
23442
  }
23323
- }
23324
- var schnittmenge = {};
23325
- for (var key in possibleOPVs) {
23326
- if (!invalidOPVs[OPT][key]) {
23327
- schnittmenge[key] = possibleOPVs[key];
23328
- }
23329
- }
23330
- // someDecisionExistsForOption = true;
23331
-
23332
- ops.updateVisibleOptionValues(_objectSpread$g({}, schnittmenge));
23333
- var valCodex = ops.valCodex;
23334
- if ((!valCodex || !schnittmenge[valCodex]) && ops.visibleOPVKeys.length > 0) {
23335
- if (this.article.CatalogData.useDiomexConfigLogic) {
23336
- this.clearOP(OPT, true);
23337
- } else {
23338
- this.updateArtOPV(this.article.getDefaultOpv(schnittmenge), OPT, ops, undefined);
23443
+ var schnittmenge = new Map(Array.from(possibleOPVs).filter(function (_ref4) {
23444
+ var _ref5 = _slicedToArray__default["default"](_ref4, 1),
23445
+ key = _ref5[0];
23446
+ return !invalidOPVs[OPT].has(key);
23447
+ }));
23448
+ ops.updateVisibleOptionValues(schnittmenge);
23449
+ var valCodex = ops.valCodex;
23450
+ if ((!valCodex || !schnittmenge.get(valCodex)) && ops.visibleOPVKeys.length > 0) {
23451
+ if (_this3.article.CatalogData.useDiomexConfigLogic) {
23452
+ _this3.clearOP(OPT, true);
23453
+ } else {
23454
+ _this3.updateArtOPV(_this3.article.getDefaultOpv(schnittmenge), OPT, ops, undefined);
23455
+ }
23339
23456
  }
23457
+ } else if (p < myDecision.Options.length - 1) {
23458
+ doAlsoCheckOPTs.push(OPT);
23340
23459
  }
23341
- } else if (p < myDecision.Options.length - 1) {
23342
- doAlsoCheckOPTs.push(OPT);
23460
+ };
23461
+ for (var p = 0; p < myDecision.Options.length; p++) {
23462
+ if (_loop3()) break;
23343
23463
  }
23344
23464
  }
23345
23465
  }
23346
23466
  }, {
23347
23467
  key: "evalShowOnlyWhenHasPrice",
23348
23468
  value: function evalShowOnlyWhenHasPrice() {
23349
- var _iterator4 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
23350
- _step4;
23469
+ var _iterator10 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
23470
+ _step10;
23351
23471
  try {
23352
- for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
23353
- var ops = _step4.value;
23472
+ for (_iterator10.s(); !(_step10 = _iterator10.n()).done;) {
23473
+ var ops = _step10.value;
23354
23474
  for (var jKey in ops.visibleOptionValues) {
23355
- var opv = ops.visibleOptionValues[jKey];
23475
+ var opv = ops.visibleOptionValues.get(jKey);
23356
23476
  if (opv.showOnlyWhenHasPrice && opv.price == 0) {
23357
- delete ops.visibleOptionValues[opv.codex];
23477
+ ops.visibleOptionValues["delete"](opv.codex);
23358
23478
  if (ops.valCodex === opv.codex) {
23359
23479
  this.assignOptionValue(ops.optionCodex, ops.visibleOPVKeys[0]);
23360
23480
  }
@@ -23362,9 +23482,9 @@ var DivaEngine = /*#__PURE__*/function () {
23362
23482
  }
23363
23483
  }
23364
23484
  } catch (err) {
23365
- _iterator4.e(err);
23485
+ _iterator10.e(err);
23366
23486
  } finally {
23367
- _iterator4.f();
23487
+ _iterator10.f();
23368
23488
  }
23369
23489
  }
23370
23490
 
@@ -23479,8 +23599,8 @@ var DivaEngine = /*#__PURE__*/function () {
23479
23599
  firstItem = null;
23480
23600
  if (this.article.getArticleOptionState(checkOPT)) {
23481
23601
  var ops = this.article.getArticleOptionState(checkOPT);
23482
- firstItem = ops === null || ops === void 0 ? void 0 : ops.visibleOptionValues[ops.visibleOPVKeys[0]]; //hole ersten eintrag für aus den Dictionary
23483
- if (checkOPV && ops !== null && ops !== void 0 && ops.visibleOptionValues[checkOPV]) foundItem = ops.visibleOptionValues[checkOPV];
23602
+ firstItem = ops === null || ops === void 0 ? void 0 : ops.visibleOptionValues.get(ops.visibleOPVKeys[0]); //hole ersten eintrag für aus den Dictionary
23603
+ if (checkOPV && ops !== null && ops !== void 0 && ops.visibleOptionValues.get(checkOPV)) foundItem = ops.visibleOptionValues.get(checkOPV);
23484
23604
  }
23485
23605
  return {
23486
23606
  foundItem: foundItem,
@@ -23606,20 +23726,20 @@ var DivaEngine = /*#__PURE__*/function () {
23606
23726
  key: "addPartilstToPartlistArticlesToLoad",
23607
23727
  value: function addPartilstToPartlistArticlesToLoad(myPartListPos, partlistArticlesToLoad, partlistGroup, newConfigValues, myDecisionVal, groupDecisionVal, decisionNumber) {
23608
23728
  var _myPartListPos$Option,
23609
- _this2 = this;
23729
+ _this4 = this;
23610
23730
  var allDecisions = this.article.catalogArticle.articleDecisions;
23611
23731
  var decisions = myPartListPos.PartListPosDecisionsAndPosCounts;
23612
23732
  var optionsForPrint = (_myPartListPos$Option = myPartListPos.OptionsForPrint) === null || _myPartListPos$Option === void 0 ? void 0 : _myPartListPos$Option.split(';');
23613
23733
  var optionImgForPrint = myPartListPos.OptionImgForPrint ? 'OPT' + myPartListPos.OptionImgForPrint : undefined;
23614
- var _loop3 = function _loop3() {
23734
+ var _loop4 = function _loop4() {
23615
23735
  var myRuleDesc = '';
23616
23736
  var myRuleDesc_locales = undefined;
23617
23737
  var articleCodex = myPartListPos.ItemRefArticles[d].ArticleCodex;
23618
23738
  var catalogCodex = myPartListPos.ItemRefArticles[d].CatalogCodex;
23619
23739
  var retailArticleNr = myPartListPos.RetailArticleNr && myPartListPos.RetailArticleNr != '' ? myPartListPos.RetailArticleNr : undefined;
23620
- if (myDecisionVal && (myDecisionVal.Rule && myDecisionVal.Rule != '' && _this2.article.CatalogData.doUseRuleDescForPartListArticles() || myPartListPos.RetailArticleNr == 'CUST')) {
23621
- myRuleDesc = DivaUtils__default["default"].getRuleDescription(myDecisionVal.Rule, _this2.article.articleOptionStates, _this2.article.set.api.ruleDescSeperator());
23622
- myRuleDesc_locales = DivaUtils__default["default"].getRuleDescription_locales(myDecisionVal.Rule, _this2.article.articleOptionStates, _this2.article.set.api.ruleDescSeperator());
23740
+ if (myDecisionVal && (myDecisionVal.Rule && myDecisionVal.Rule != '' && _this4.article.CatalogData.doUseRuleDescForPartListArticles() || myPartListPos.RetailArticleNr == 'CUST')) {
23741
+ myRuleDesc = DivaUtils__default["default"].getRuleDescription(myDecisionVal.Rule, _this4.article.articleOptionStates, _this4.article.set.api.ruleDescSeperator());
23742
+ myRuleDesc_locales = DivaUtils__default["default"].getRuleDescription_locales(myDecisionVal.Rule, _this4.article.articleOptionStates, _this4.article.set.api.ruleDescSeperator());
23623
23743
  }
23624
23744
  var initDecisions = decisions.filter(function (decision) {
23625
23745
  return decision.RelationType !== 'PosCount';
@@ -23629,7 +23749,7 @@ var DivaEngine = /*#__PURE__*/function () {
23629
23749
  });
23630
23750
  });
23631
23751
  var quanitity = 1;
23632
- if (_this2.article.CatalogData.useDecisionPosCountValue) {
23752
+ if (_this4.article.CatalogData.useDecisionPosCountValue) {
23633
23753
  var _decision$DOC;
23634
23754
  // get SetPosCountValue from decsion action if defined and else use myPartListPos.PosCountValue;
23635
23755
  var decision = decisionNumber ? allDecisions.find(function (d) {
@@ -23644,13 +23764,13 @@ var DivaEngine = /*#__PURE__*/function () {
23644
23764
  return a.SetPosCountValue !== undefined;
23645
23765
  })) === null || _decision$DOC === void 0 ? void 0 : _decision$DOC.SetPosCountValue;
23646
23766
  quanitity = setPosCountValue !== undefined ? setPosCountValue : myPartListPos.PosCountValue;
23647
- } else if (_this2.article.CatalogData.usePosCountValue) {
23767
+ } else if (_this4.article.CatalogData.usePosCountValue) {
23648
23768
  quanitity = myPartListPos.PosCountValue;
23649
23769
  }
23650
- quanitity = quanitity * _this2.article.quantity;
23651
- var previousPartlistArticle = _this2.article.getPreviousPartlistArticle(articleCodex);
23770
+ quanitity = quanitity * _this4.article.quantity;
23771
+ var previousPartlistArticle = _this4.article.getPreviousPartlistArticle(articleCodex);
23652
23772
  var initDecisionsFiltered = [];
23653
- var _loop4 = function _loop4(i) {
23773
+ var _loop5 = function _loop5(i) {
23654
23774
  if (initDecisions[i] && !initDecisionsFiltered.find(function (d) {
23655
23775
  return d.Number == initDecisions[i].Number;
23656
23776
  })) {
@@ -23658,18 +23778,18 @@ var DivaEngine = /*#__PURE__*/function () {
23658
23778
  }
23659
23779
  };
23660
23780
  for (var i = 0; i < initDecisions.length; i++) {
23661
- _loop4(i);
23781
+ _loop5(i);
23662
23782
  }
23663
23783
  if (quanitity >= 1) {
23664
23784
  var _myDecisionVal$Rule;
23665
23785
  partlistArticlesToLoad.push({
23666
- CatalogCodex: catalogCodex !== null && catalogCodex !== void 0 ? catalogCodex : _this2.article.catalogCodex,
23786
+ CatalogCodex: catalogCodex !== null && catalogCodex !== void 0 ? catalogCodex : _this4.article.catalogCodex,
23667
23787
  BasketID: previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.basketId,
23668
23788
  ArticleCodex: articleCodex,
23669
23789
  RetailArticleNr: retailArticleNr,
23670
23790
  RetailPrefix: myPartListPos.RetailPrefix,
23671
23791
  Quantity: quanitity,
23672
- PartlistRule: (groupDecisionVal ? groupDecisionVal.Rule + ' && ' : '') + myDecisionVal ? DivaUtils__default["default"].getOptionValuePairsByRule((_myDecisionVal$Rule = myDecisionVal === null || myDecisionVal === void 0 ? void 0 : myDecisionVal.Rule) !== null && _myDecisionVal$Rule !== void 0 ? _myDecisionVal$Rule : '', _this2.article.VariantValues) : undefined,
23792
+ PartlistRule: (groupDecisionVal ? groupDecisionVal.Rule + ' && ' : '') + myDecisionVal ? DivaUtils__default["default"].getOptionValuePairsByRule((_myDecisionVal$Rule = myDecisionVal === null || myDecisionVal === void 0 ? void 0 : myDecisionVal.Rule) !== null && _myDecisionVal$Rule !== void 0 ? _myDecisionVal$Rule : '', _this4.article.VariantValues) : undefined,
23673
23793
  partlistDecisionNo: decisionNumber,
23674
23794
  SupplierOrderCodex: myPartListPos.SupplierOrderCodex,
23675
23795
  initDecisions: initDecisionsFiltered,
@@ -23678,7 +23798,7 @@ var DivaEngine = /*#__PURE__*/function () {
23678
23798
  RuleDesc_locales: myRuleDesc_locales,
23679
23799
  PosInvisibility: myPartListPos.PosInvisibility,
23680
23800
  ConfigurationMode: myPartListPos.ConfigurationMode,
23681
- VariantValues: _this2.article.variantValuesForPla(myPartListPos.ConfigurationMode, previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.VariantValues, newConfigValues),
23801
+ VariantValues: _this4.article.variantValuesForPla(myPartListPos.ConfigurationMode, previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.VariantValues, newConfigValues),
23682
23802
  VariantItemData: previousPartlistArticle === null || previousPartlistArticle === void 0 ? void 0 : previousPartlistArticle.VariantItemData,
23683
23803
  optionImgForPrint: optionImgForPrint,
23684
23804
  optionsForPrint: optionsForPrint
@@ -23687,7 +23807,7 @@ var DivaEngine = /*#__PURE__*/function () {
23687
23807
  }
23688
23808
  };
23689
23809
  for (var d = 0; d < myPartListPos.ItemRefArticles.length; d++) {
23690
- _loop3();
23810
+ _loop4();
23691
23811
  }
23692
23812
  return partlistArticlesToLoad;
23693
23813
  }
@@ -23726,7 +23846,7 @@ var DivaEngine = /*#__PURE__*/function () {
23726
23846
  }, {
23727
23847
  key: "calcConfigPrice",
23728
23848
  value: function calcConfigPrice(maxPriceOfGroupCodex, digits) {
23729
- var _this3 = this,
23849
+ var _this5 = this,
23730
23850
  _this$article$catalog4;
23731
23851
  //Wenn im Planer für dieses Shape mehere Rules gibt, müssen wir diese jetzt prüfen, ob jetzt ein anderes shape gültig ist.
23732
23852
  //wenn ja, hier neues shape übergeben
@@ -23759,12 +23879,12 @@ var DivaEngine = /*#__PURE__*/function () {
23759
23879
  }
23760
23880
 
23761
23881
  //mengen und größenabhängige Preisberechungn.
23762
- var _iterator5 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
23763
- _step5;
23882
+ var _iterator11 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
23883
+ _step11;
23764
23884
  try {
23765
- for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
23885
+ for (_iterator11.s(); !(_step11 = _iterator11.n()).done;) {
23766
23886
  var _ops$addToMeasure;
23767
- var ops = _step5.value;
23887
+ var ops = _step11.value;
23768
23888
  var OP = ops.optionCodex;
23769
23889
  var mUnit = ops.measureUnit;
23770
23890
  var pUnit = ops.priceUnit;
@@ -23847,61 +23967,61 @@ var DivaEngine = /*#__PURE__*/function () {
23847
23967
  }
23848
23968
  //jetzt nochmal prozentuelle Preise mit TargetOption berechnen
23849
23969
  } catch (err) {
23850
- _iterator5.e(err);
23970
+ _iterator11.e(err);
23851
23971
  } finally {
23852
- _iterator5.f();
23972
+ _iterator11.f();
23853
23973
  }
23854
- var _iterator6 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
23855
- _step6;
23974
+ var _iterator12 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
23975
+ _step12;
23856
23976
  try {
23857
- for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
23858
- var _ops5 = _step6.value;
23859
- var targetPPGPrefixes = _ops5.targetPPGPrefixes;
23977
+ for (_iterator12.s(); !(_step12 = _iterator12.n()).done;) {
23978
+ var _ops4 = _step12.value;
23979
+ var targetPPGPrefixes = _ops4.targetPPGPrefixes;
23860
23980
  if (!targetPPGPrefixes) continue;
23861
- var _loop6 = function _loop6() {
23981
+ var _loop7 = function _loop7() {
23862
23982
  var targetPrefix = targetPPGPrefixes[_i6];
23863
- var priceRef = _this3.article.priceRefs.find(function (item) {
23983
+ var priceRef = _this5.article.priceRefs.find(function (item) {
23864
23984
  var _item$PPG;
23865
23985
  return ((_item$PPG = item.PPG) === null || _item$PPG === void 0 ? void 0 : _item$PPG.split('_')[0]) == targetPrefix;
23866
23986
  });
23867
23987
  if (priceRef) {
23868
- if (_ops5.isPercentage) {
23869
- priceRef.calcPrice = priceRef.Price * (1 + _ops5.calcPrice);
23988
+ if (_ops4.isPercentage) {
23989
+ priceRef.calcPrice = priceRef.Price * (1 + _ops4.calcPrice);
23870
23990
  }
23871
23991
  }
23872
23992
  };
23873
23993
  for (var _i6 = 0; _i6 < targetPPGPrefixes.length; _i6++) {
23874
- _loop6();
23994
+ _loop7();
23875
23995
  }
23876
23996
  }
23877
23997
  } catch (err) {
23878
- _iterator6.e(err);
23998
+ _iterator12.e(err);
23879
23999
  } finally {
23880
- _iterator6.f();
24000
+ _iterator12.f();
23881
24001
  }
23882
24002
  for (var _i3 = 0; _i3 < this.article.priceRefs.length; _i3++) {
23883
24003
  var basePriceRef = this.article.priceRefs[_i3];
23884
24004
  if (!basePriceRef.TargetPPGPrefixes) continue;
23885
- var _loop5 = function _loop5() {
24005
+ var _loop6 = function _loop6() {
23886
24006
  var targetPrefix = basePriceRef.TargetPPGPrefixes[_j];
23887
24007
  var myArtOpv;
23888
- var priceRef = _this3.article.priceRefs.find(function (item) {
24008
+ var priceRef = _this5.article.priceRefs.find(function (item) {
23889
24009
  return item.PPG && item.PPG.split('_')[0] == targetPrefix;
23890
24010
  });
23891
24011
  if (!priceRef) {
23892
- var _iterator7 = _createForOfIteratorHelper$8(_this3.article.articleOptionStates),
23893
- _step7;
24012
+ var _iterator13 = _createForOfIteratorHelper$8(_this5.article.articleOptionStates.values()),
24013
+ _step13;
23894
24014
  try {
23895
- for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {
23896
- var ops = _step7.value;
24015
+ for (_iterator13.s(); !(_step13 = _iterator13.n()).done;) {
24016
+ var ops = _step13.value;
23897
24017
  if (ops.ppg && ops.ppg.split('_')[0] == targetPrefix) {
23898
24018
  myArtOpv = ops;
23899
24019
  }
23900
24020
  }
23901
24021
  } catch (err) {
23902
- _iterator7.e(err);
24022
+ _iterator13.e(err);
23903
24023
  } finally {
23904
- _iterator7.f();
24024
+ _iterator13.f();
23905
24025
  }
23906
24026
  }
23907
24027
 
@@ -23917,7 +24037,7 @@ var DivaEngine = /*#__PURE__*/function () {
23917
24037
  }
23918
24038
  };
23919
24039
  for (var _j = 0; _j < basePriceRef.TargetPPGPrefixes.length; _j++) {
23920
- _loop5();
24040
+ _loop6();
23921
24041
  }
23922
24042
  }
23923
24043
  for (var _i4 = 0; _i4 < this.article.priceRefs.length; _i4++) {
@@ -23927,36 +24047,36 @@ var DivaEngine = /*#__PURE__*/function () {
23927
24047
  myArticleBasePrice += priceRef.Price ? DivaUtils__default["default"].decimalAdjust('round', (_priceRef$calcPrice = priceRef.calcPrice) !== null && _priceRef$calcPrice !== void 0 ? _priceRef$calcPrice : priceRef.Price, digits) : 0.0;
23928
24048
  }
23929
24049
  var articleUsedCalcPrice = myArticleBasePrice;
23930
- var _iterator8 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
23931
- _step8;
24050
+ var _iterator14 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
24051
+ _step14;
23932
24052
  try {
23933
- for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
23934
- var tmpOps = _step8.value;
24053
+ for (_iterator14.s(); !(_step14 = _iterator14.n()).done;) {
24054
+ var tmpOps = _step14.value;
23935
24055
  articleUsedCalcPrice = this.getOptionPrice(articleUsedCalcPrice, tmpOps.option, digits);
23936
24056
  }
23937
24057
 
23938
24058
  //jetzt nochmal prozentuelle Preise mit GLOBAL tarbetoption berechnen
23939
24059
  /* TODO ABklären mit Franz - ops hat nie die Optionen - targetPPGPrefixes - ich glaube hier sollte article.priceRefs durchlaufen werden. */
23940
24060
  } catch (err) {
23941
- _iterator8.e(err);
24061
+ _iterator14.e(err);
23942
24062
  } finally {
23943
- _iterator8.f();
24063
+ _iterator14.f();
23944
24064
  }
23945
- var _iterator9 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
23946
- _step9;
24065
+ var _iterator15 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
24066
+ _step15;
23947
24067
  try {
23948
- for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
23949
- var _ops6$targetPPGPrefix, _ops6$targetPPGPrefix2;
23950
- var _ops6 = _step9.value;
23951
- var targetOption = (_ops6$targetPPGPrefix = (_ops6$targetPPGPrefix2 = _ops6.targetPPGPrefixes) === null || _ops6$targetPPGPrefix2 === void 0 ? void 0 : _ops6$targetPPGPrefix2[0]) !== null && _ops6$targetPPGPrefix !== void 0 ? _ops6$targetPPGPrefix : _ops6.targetOption;
23952
- if (_ops6.isPercentage && targetOption == 'GLOBAL') {
23953
- articleUsedCalcPrice = articleUsedCalcPrice * (1 + _ops6.calcPrice);
24068
+ for (_iterator15.s(); !(_step15 = _iterator15.n()).done;) {
24069
+ var _ops5$targetPPGPrefix, _ops5$targetPPGPrefix2;
24070
+ var _ops5 = _step15.value;
24071
+ 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;
24072
+ if (_ops5.isPercentage && targetOption == 'GLOBAL') {
24073
+ articleUsedCalcPrice = articleUsedCalcPrice * (1 + _ops5.calcPrice);
23954
24074
  }
23955
24075
  }
23956
24076
  } catch (err) {
23957
- _iterator9.e(err);
24077
+ _iterator15.e(err);
23958
24078
  } finally {
23959
- _iterator9.f();
24079
+ _iterator15.f();
23960
24080
  }
23961
24081
  for (var _i5 = 0; _i5 < this.article.priceRefs.length; _i5++) {
23962
24082
  var _priceRef = this.article.priceRefs[_i5];
@@ -24098,22 +24218,22 @@ var DivaEngine = /*#__PURE__*/function () {
24098
24218
  if (a[i].trim() != '') {
24099
24219
  var searchOpt = 'OPT' + a[i].trim();
24100
24220
  //Optionsbaum des Artikels durchsuchen
24101
- var _iterator10 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
24102
- _step10;
24221
+ var _iterator16 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
24222
+ _step16;
24103
24223
  try {
24104
- for (_iterator10.s(); !(_step10 = _iterator10.n()).done;) {
24105
- var _ops7 = _step10.value;
24106
- if (_ops7.ocd == searchOpt || _ops7.optionCodex == searchOpt) {
24107
- if (_ops7 && _ops7.price > 0) {
24108
- myPercBasePrice += _ops7.price * _ops7.quantity;
24224
+ for (_iterator16.s(); !(_step16 = _iterator16.n()).done;) {
24225
+ var _ops6 = _step16.value;
24226
+ if (_ops6.ocd == searchOpt || _ops6.optionCodex == searchOpt) {
24227
+ if (_ops6 && _ops6.price > 0) {
24228
+ myPercBasePrice += _ops6.price * _ops6.quantity;
24109
24229
  break;
24110
24230
  }
24111
24231
  }
24112
24232
  }
24113
24233
  } catch (err) {
24114
- _iterator10.e(err);
24234
+ _iterator16.e(err);
24115
24235
  } finally {
24116
- _iterator10.f();
24236
+ _iterator16.f();
24117
24237
  }
24118
24238
  }
24119
24239
  }
@@ -24133,7 +24253,7 @@ var DivaEngine = /*#__PURE__*/function () {
24133
24253
  value: function updateConfigDependentMedia() {
24134
24254
  var _this$article$catalog5,
24135
24255
  _this$article$catalog6,
24136
- _this4 = this;
24256
+ _this6 = this;
24137
24257
  var catalogData = this.article.CatalogData;
24138
24258
  //articlebild berechnung
24139
24259
 
@@ -24159,38 +24279,48 @@ var DivaEngine = /*#__PURE__*/function () {
24159
24279
  }
24160
24280
 
24161
24281
  // this functions updates the images of OPVs that depend on rules
24162
- var _iterator11 = _createForOfIteratorHelper$8(this.article.articleOptionStates),
24163
- _step11;
24282
+ var _iterator17 = _createForOfIteratorHelper$8(this.article.articleOptionStates.values()),
24283
+ _step17;
24164
24284
  try {
24165
- for (_iterator11.s(); !(_step11 = _iterator11.n()).done;) {
24166
- var ops = _step11.value;
24167
- for (var jKey in ops.visibleOptionValues) {
24168
- var opv = ops.visibleOptionValues[jKey];
24169
- if (opv.images) {
24170
- var imageFound = false;
24171
- for (var _i8 = 0; _i8 < opv.images.length; _i8++) {
24172
- var image = opv.images[_i8];
24173
- var rule = image.jsFormula;
24174
- if (rule.includes('ARTICLECODEX')) {
24175
- rule = rule.replace(/ARTICLECODEX/g, "'" + this.article.articleCodex + "'");
24176
- }
24177
- if (rule && this.article.evalRule(rule)) {
24178
- ops.editVisibleOPVsImages(opv.codex, catalogData.getCatImageURL(image.fileName, ''));
24179
- imageFound = true;
24180
- break;
24285
+ for (_iterator17.s(); !(_step17 = _iterator17.n()).done;) {
24286
+ var ops = _step17.value;
24287
+ var _iterator18 = _createForOfIteratorHelper$8(ops.visibleOptionValues),
24288
+ _step18;
24289
+ try {
24290
+ for (_iterator18.s(); !(_step18 = _iterator18.n()).done;) {
24291
+ var _step18$value = _slicedToArray__default["default"](_step18.value, 2),
24292
+ jKey = _step18$value[0],
24293
+ opv = _step18$value[1];
24294
+ if (opv.images) {
24295
+ var imageFound = false;
24296
+ for (var _i8 = 0; _i8 < opv.images.length; _i8++) {
24297
+ var image = opv.images[_i8];
24298
+ var rule = image.jsFormula;
24299
+ if (rule.includes('ARTICLECODEX')) {
24300
+ rule = rule.replace(/ARTICLECODEX/g, "'" + this.article.articleCodex + "'");
24301
+ }
24302
+ if (rule && this.article.evalRule(rule)) {
24303
+ ops.editVisibleOPVsImages(opv.codex, catalogData.getCatImageURL(image.fileName, ''));
24304
+ imageFound = true;
24305
+ break;
24306
+ }
24181
24307
  }
24308
+ if (!imageFound) ops.editVisibleOPVsImages(opv.codex);
24182
24309
  }
24183
- if (!imageFound) ops.editVisibleOPVsImages(opv.codex);
24184
24310
  }
24311
+ } catch (err) {
24312
+ _iterator18.e(err);
24313
+ } finally {
24314
+ _iterator18.f();
24185
24315
  }
24186
24316
  }
24187
24317
 
24188
24318
  // this function calculates an Svg to the current configuration if neccessary (SVG Tausch)
24189
24319
  // if the Article has no SVG Tausch nothing is done
24190
24320
  } catch (err) {
24191
- _iterator11.e(err);
24321
+ _iterator17.e(err);
24192
24322
  } finally {
24193
- _iterator11.f();
24323
+ _iterator17.f();
24194
24324
  }
24195
24325
  var newSVGFile = null;
24196
24326
  var svgChangedViaSvgTausch = false;
@@ -24252,7 +24382,7 @@ var DivaEngine = /*#__PURE__*/function () {
24252
24382
  code: 'WC_0011',
24253
24383
  custom: {
24254
24384
  formulas: (_plannerCatArt$topSvg = plannerCatArt.topSvgsWithFormula) === null || _plannerCatArt$topSvg === void 0 ? void 0 : _plannerCatArt$topSvg.map(function (item) {
24255
- return DivaUtils__default["default"].getRuleByFormula(item.JsFormula, _this4.article.catalogCodex, catalogData.multiselectOptions);
24385
+ return DivaUtils__default["default"].getRuleByFormula(item.JsFormula, _this6.article.catalogCodex, catalogData.multiselectOptions);
24256
24386
  }),
24257
24387
  catalogName: catalogData.catalogName,
24258
24388
  catalogCodex: this.article.catalogCodex,
@@ -24277,8 +24407,8 @@ var DivaEngine = /*#__PURE__*/function () {
24277
24407
  }]);
24278
24408
  }();
24279
24409
 
24280
- function ownKeys$f(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; }
24281
- function _objectSpread$f(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$f(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$f(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
24410
+ function ownKeys$e(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; }
24411
+ function _objectSpread$e(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$e(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$e(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
24282
24412
  function _createForOfIteratorHelper$7(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$7(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
24283
24413
  function _unsupportedIterableToArray$7(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$7(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$7(r, a) : void 0; } }
24284
24414
  function _arrayLikeToArray$7(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
@@ -24333,12 +24463,12 @@ var IDMEngine = /*#__PURE__*/function () {
24333
24463
  decisions[i].disableHistory = [];
24334
24464
  decisions[i].activeCombination = undefined;
24335
24465
  }
24336
- var _iterator = _createForOfIteratorHelper$7(this.article.articleOptionStates),
24466
+ var _iterator = _createForOfIteratorHelper$7(this.article.articleOptionStates.values()),
24337
24467
  _step;
24338
24468
  try {
24339
24469
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
24340
24470
  var ops = _step.value;
24341
- ops.updateVisibleOptionValues(_objectSpread$f({}, ops.option.articleOptionValues));
24471
+ ops.updateVisibleOptionValues(ops.option.articleOptionValues);
24342
24472
  if (!ops.val) this.updateArtOPV(this.article.getDefaultOpv(ops.visibleOptionValues), ops.optionCodex, ops, undefined);
24343
24473
  ops.definedBySetFeatureFixed = false;
24344
24474
  }
@@ -24404,14 +24534,15 @@ var IDMEngine = /*#__PURE__*/function () {
24404
24534
  value: function sortFeatures(featureNos) {
24405
24535
  var _this = this;
24406
24536
  return featureNos.sort(function (a, b) {
24407
- var aIndex = _this.article.articleOptionStates.findIndex(function (ops) {
24537
+ var opsArray = Array.from(_this.article.articleOptionStates.values());
24538
+ var aIndex = opsArray.findIndex(function (ops) {
24408
24539
  return ops.optionCodex == a;
24409
24540
  });
24410
- var bIndex = _this.article.articleOptionStates.findIndex(function (ops) {
24541
+ var bIndex = opsArray.findIndex(function (ops) {
24411
24542
  return ops.optionCodex == b;
24412
24543
  });
24413
- if (aIndex == -1) aIndex = _this.article.articleOptionStates.length;
24414
- if (bIndex == -1) bIndex = _this.article.articleOptionStates.length;
24544
+ if (aIndex == -1) aIndex = opsArray.length;
24545
+ if (bIndex == -1) bIndex = opsArray.length;
24415
24546
  return aIndex - bIndex;
24416
24547
  });
24417
24548
  }
@@ -24427,7 +24558,7 @@ var IDMEngine = /*#__PURE__*/function () {
24427
24558
  var _loop = function _loop() {
24428
24559
  var featureNo = sortedDeatureRefs[p];
24429
24560
  var ops = _this2.article.getArticleOptionState(featureNo);
24430
- if (!validOptions[featureNo]) validOptions[featureNo] = {};
24561
+ if (!validOptions[featureNo]) validOptions[featureNo] = new Map();
24431
24562
  if (!ops) return 1; // break
24432
24563
  var possibleOPVs = ops.visibleOptionValues;
24433
24564
 
@@ -24489,12 +24620,12 @@ var IDMEngine = /*#__PURE__*/function () {
24489
24620
  }
24490
24621
  if (ruleValid) {
24491
24622
  ruleWasValidOnce = true;
24492
- validOptions[featureNo] = _objectSpread$f({}, possibleOPVs);
24493
- if (possibleOPVs[optionNo] != null) delete validOptions[featureNo][optionNo];
24623
+ validOptions[featureNo] = new Map(possibleOPVs);
24624
+ if (possibleOPVs.get(optionNo) != null) validOptions[featureNo]["delete"](optionNo);
24494
24625
  }
24495
24626
  } else {
24496
24627
  ruleWasValidOnce = true;
24497
- if (possibleOPVs[optionNo] != null) validOptions[featureNo][optionNo] = possibleOPVs[optionNo];
24628
+ if (possibleOPVs.get(optionNo) != null) validOptions[featureNo].set(optionNo, possibleOPVs.get(optionNo));
24498
24629
  }
24499
24630
  }
24500
24631
  if (!ruleWasValidOnce) {
@@ -24502,7 +24633,7 @@ var IDMEngine = /*#__PURE__*/function () {
24502
24633
  for (var x = 0; x < ops.visibleOPVKeys.length; x++) {
24503
24634
  var _opv = ops.visibleOPVKeys[x];
24504
24635
  var doesNotExists = !!(ref.options.includes(_opv) && (ref.operator == 1 || ref.operator == 3));
24505
- if (!doesNotExists) validOptions[featureNo][_opv] = ops.visibleOptionValues[_opv];
24636
+ if (!doesNotExists) validOptions[featureNo].set(_opv, ops.visibleOptionValues.get(_opv));
24506
24637
  }
24507
24638
  }
24508
24639
  } else {
@@ -24510,16 +24641,15 @@ var IDMEngine = /*#__PURE__*/function () {
24510
24641
  }
24511
24642
  }
24512
24643
  }
24513
- var schnittmenge = {};
24514
- for (var _key in possibleOPVs) {
24515
- if (validOptions[featureNo][_key]) {
24516
- schnittmenge[_key] = possibleOPVs[_key];
24517
- }
24518
- }
24644
+ var schnittmenge = new Map(Array.from(possibleOPVs).filter(function (_ref) {
24645
+ var _ref2 = _slicedToArray__default["default"](_ref, 1),
24646
+ key = _ref2[0];
24647
+ return validOptions[featureNo].has(key);
24648
+ }));
24519
24649
  possibleOPVs = schnittmenge;
24520
- ops.updateVisibleOptionValues(Object.assign({}, possibleOPVs));
24650
+ ops.updateVisibleOptionValues(possibleOPVs);
24521
24651
  var valCodex = ops.valCodex;
24522
- if ((!valCodex || !ops.visibleOptionValues[valCodex]) && ops.visibleOPVKeys.length > 0) {
24652
+ if ((!valCodex || !ops.visibleOptionValues.get(valCodex)) && ops.visibleOPVKeys.length > 0) {
24523
24653
  if (_this2.article.CatalogData.useDiomexConfigLogic) {
24524
24654
  _this2.clearOP(featureNo, true);
24525
24655
  } else {
@@ -24548,7 +24678,7 @@ var IDMEngine = /*#__PURE__*/function () {
24548
24678
  var featureNo = sortedDeatureRefs[p];
24549
24679
  var ops = _this3.article.getArticleOptionStateFlat(featureNo);
24550
24680
  if (!ops) return 1; // break
24551
- if (!invalidOptions[featureNo]) invalidOptions[featureNo] = {};
24681
+ if (!invalidOptions[featureNo]) invalidOptions[featureNo] = new Map();
24552
24682
  var possibleOPVs = ops.visibleOptionValues;
24553
24683
  //Erste Option ist immer eine Bedingung!
24554
24684
  if (p === sortedDeatureRefs.length - 1) {
@@ -24586,25 +24716,23 @@ var IDMEngine = /*#__PURE__*/function () {
24586
24716
  if (ref) {
24587
24717
  for (var i = 0; i < ref.options.length; i++) {
24588
24718
  var optionNo = ref.options[i];
24589
- var myOPVData = possibleOPVs[optionNo];
24719
+ var myOPVData = possibleOPVs.get(optionNo);
24590
24720
  if (myOPVData != null) {
24591
- invalidOptions[featureNo][optionNo] = myOPVData; //wenn es eine DecisionType 0 ist muss ich diese OPV von den gültigen entfernen
24721
+ invalidOptions[featureNo].set(optionNo, myOPVData); //wenn es eine DecisionType 0 ist muss ich diese OPV von den gültigen entfernen
24592
24722
  }
24593
24723
  }
24594
24724
  }
24595
24725
  }
24596
24726
  }
24597
- var schnittmenge = {};
24598
- for (var key in possibleOPVs) {
24599
- if (!invalidOptions[featureNo][key]) {
24600
- schnittmenge[key] = possibleOPVs[key];
24601
- }
24602
- }
24603
- // someDecisionExistsForOption = true;
24727
+ var schnittmenge = new Map(Array.from(possibleOPVs).filter(function (_ref3) {
24728
+ var _ref4 = _slicedToArray__default["default"](_ref3, 1),
24729
+ key = _ref4[0];
24730
+ return !invalidOptions[featureNo].has(key);
24731
+ }));
24604
24732
  possibleOPVs = schnittmenge;
24605
- ops.updateVisibleOptionValues(Object.assign({}, possibleOPVs));
24733
+ ops.updateVisibleOptionValues(possibleOPVs);
24606
24734
  var valCodex = ops.valCodex;
24607
- if ((!valCodex || !ops.visibleOptionValues[valCodex]) && ops.visibleOPVKeys.length > 0) {
24735
+ if ((!valCodex || !ops.visibleOptionValues.get(valCodex)) && ops.visibleOPVKeys.length > 0) {
24608
24736
  if (_this3.article.CatalogData.useDiomexConfigLogic) {
24609
24737
  _this3.clearOP(featureNo, true);
24610
24738
  } else {
@@ -24622,11 +24750,22 @@ var IDMEngine = /*#__PURE__*/function () {
24622
24750
  }, {
24623
24751
  key: "evalValueWithOperator",
24624
24752
  value: function evalValueWithOperator(op, value, check) {
24625
- if (op == 0 || op == 2) return value.includes(check);
24626
- if (op == 1 || op == 3) return !value.includes(check);
24627
- if (op == 4 || op == 5) throw new Error('gt and lt not implemented');
24628
- if (op == 6 || op == 7) throw new Error('ge and le not implemented');
24629
- throw new Error('decisions operator ' + op + ' not implemented');
24753
+ switch (op) {
24754
+ case 0:
24755
+ case 2:
24756
+ return value.includes(check);
24757
+ case 1:
24758
+ case 3:
24759
+ return !value.includes(check);
24760
+ case 4:
24761
+ case 5:
24762
+ throw new Error('gt and lt not implemented');
24763
+ case 6:
24764
+ case 7:
24765
+ throw new Error('ge and le not implemented');
24766
+ default:
24767
+ throw new Error('decisions operator ' + op + ' not implemented');
24768
+ }
24630
24769
  }
24631
24770
  }, {
24632
24771
  key: "evalType2Decision",
@@ -24634,9 +24773,9 @@ var IDMEngine = /*#__PURE__*/function () {
24634
24773
  var _decision$optionCombi2;
24635
24774
  var hasSetFeatureInvisible = {};
24636
24775
  if (!((_decision$optionCombi2 = decision.optionCombinations) !== null && _decision$optionCombi2 !== void 0 && _decision$optionCombi2.length)) return;
24637
- var _ref = this.getMatchingOptionCombination(decision.optionCombinations),
24638
- _ref2 = _slicedToArray__default["default"](_ref, 1),
24639
- combination = _ref2[0];
24776
+ var _ref5 = this.getMatchingOptionCombination(decision.optionCombinations),
24777
+ _ref6 = _slicedToArray__default["default"](_ref5, 1),
24778
+ combination = _ref6[0];
24640
24779
  if (combination) decision.activeCombination = combination.sequence;
24641
24780
  if (combination !== null && combination !== void 0 && combination.projectActions) {
24642
24781
  if (combination.projectActions.disableDecision) this.evalDisableDecision(combination.projectActions.disableDecision, decision, allDecisions, true);
@@ -24777,7 +24916,7 @@ var IDMEngine = /*#__PURE__*/function () {
24777
24916
  value: function assignOptionValue(featureNo, optionNo, setBy, freeText) {
24778
24917
  var ops = this.article.getArticleOptionState(featureNo);
24779
24918
  if (!ops) throw new Error('myOptionState ' + featureNo + ' is undefined');
24780
- var option = ops.visibleOptionValues[optionNo];
24919
+ var option = ops.visibleOptionValues.get(optionNo);
24781
24920
  if (option) {
24782
24921
  if (setBy == 'fix') ops.definedBySetFeatureFixed = true;
24783
24922
  ops.valueWasSet = true;
@@ -24883,7 +25022,7 @@ var IDMEngine = /*#__PURE__*/function () {
24883
25022
  nr: priceFeatureGroup.priceFeatureGroupNo,
24884
25023
  variantValues: this.article.VariantValues,
24885
25024
  text: DivaUtils__default["default"].getLocals(priceFeatureGroup.priceFeatureGroupText, this.article.set.api.getLanguage()) + ' ' + (finish ? (_this$article$catalog3 = this.article.catalogArticle.idmPrices) === null || _this$article$catalog3 === void 0 || (_this$article$catalog3 = _this$article$catalog3.prices['PRFG' + priceFeatureGroup.priceFeatureGroupNo + '_' + finish.priceField]) === null || _this$article$catalog3 === void 0 ? void 0 : _this$article$catalog3.toString() : ''),
24886
- priceFeatureGroup: _objectSpread$f(_objectSpread$f({}, priceFeatureGroup), {}, {
25025
+ priceFeatureGroup: _objectSpread$e(_objectSpread$e({}, priceFeatureGroup), {}, {
24887
25026
  activeCombination: finish === null || finish === void 0 ? void 0 : finish.sequence
24888
25027
  })
24889
25028
  });
@@ -24990,9 +25129,9 @@ var IDMEngine = /*#__PURE__*/function () {
24990
25129
  if (myPartListPos.decisionPosCount) {
24991
25130
  // get SetPosCountValue from decsion action if defined and else use myPartListPos.PosCountValue;
24992
25131
  var decision = this.article.CatalogData.getDecisionsByNo([myPartListPos.decisionPosCount])[0];
24993
- var _ref3 = this.getMatchingOptionCombination(decision.optionCombinations),
24994
- _ref4 = _slicedToArray__default["default"](_ref3, 1),
24995
- combination = _ref4[0];
25132
+ var _ref7 = this.getMatchingOptionCombination(decision.optionCombinations),
25133
+ _ref8 = _slicedToArray__default["default"](_ref7, 1),
25134
+ combination = _ref8[0];
24996
25135
  if (combination) {
24997
25136
  var _combination$projectA;
24998
25137
  var posCountValueAction = (_combination$projectA = combination.projectActions) === null || _combination$projectA === void 0 ? void 0 : _combination$projectA.setPosCountValue;
@@ -25111,7 +25250,7 @@ var IDMEngine = /*#__PURE__*/function () {
25111
25250
  key: "updateIDMSpecificFeatures",
25112
25251
  value: function updateIDMSpecificFeatures() {
25113
25252
  //updaten idm planner specific options
25114
- var _iterator6 = _createForOfIteratorHelper$7(this.article.articleOptionStates),
25253
+ var _iterator6 = _createForOfIteratorHelper$7(this.article.articleOptionStates.values()),
25115
25254
  _step6;
25116
25255
  try {
25117
25256
  for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
@@ -25122,7 +25261,7 @@ var IDMEngine = /*#__PURE__*/function () {
25122
25261
  }
25123
25262
  if (ops.visibleCount && ops.IsIDMSpecialFeature) {
25124
25263
  var _validOpv;
25125
- var validOpvs = Object.values(ops.visibleOptionValues);
25264
+ var validOpvs = Array.from(ops.visibleOptionValues.values());
25126
25265
  if (ops.val) validOpvs.unshift(ops.val);
25127
25266
  var validOpv = undefined;
25128
25267
  for (var i = 0; i < validOpvs.length; i++) {
@@ -25156,27 +25295,27 @@ var IDMEngine = /*#__PURE__*/function () {
25156
25295
  }
25157
25296
  if ([97, 1097].includes((_myArtOPS$option$idmV3 = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV3 !== void 0 ? _myArtOPS$option$idmV3 : 0)) {
25158
25297
  try {
25159
- var _ref5, _myArtOPS$measureValu;
25298
+ var _ref9, _myArtOPS$measureValu;
25160
25299
  this.article.doUpdatePlannerSize = true;
25161
- this.article.calcHeight = Math.round((Number((_ref5 = (_myArtOPS$measureValu = myArtOPS.measureValue) !== null && _myArtOPS$measureValu !== void 0 ? _myArtOPS$measureValu : myArtOPS.value) !== null && _ref5 !== void 0 ? _ref5 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25300
+ this.article.calcHeight = Math.round((Number((_ref9 = (_myArtOPS$measureValu = myArtOPS.measureValue) !== null && _myArtOPS$measureValu !== void 0 ? _myArtOPS$measureValu : myArtOPS.value) !== null && _ref9 !== void 0 ? _ref9 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25162
25301
  } catch (e) {
25163
25302
  LOG$f.warn('Invalid Planungdepth - IDMVariantenArt 97: ' + myArtOPS.option.name + ' ' + myArtOPS.valName, e);
25164
25303
  }
25165
25304
  }
25166
25305
  if ([96, 1096].includes((_myArtOPS$option$idmV4 = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV4 !== void 0 ? _myArtOPS$option$idmV4 : 0) || myArtOPS.option.diameter) {
25167
25306
  try {
25168
- var _ref6, _myArtOPS$measureValu2;
25307
+ var _ref10, _myArtOPS$measureValu2;
25169
25308
  this.article.doUpdatePlannerSize = true;
25170
- this.article.calcDepth = Math.round((Number((_ref6 = (_myArtOPS$measureValu2 = myArtOPS.measureValue) !== null && _myArtOPS$measureValu2 !== void 0 ? _myArtOPS$measureValu2 : myArtOPS.value) !== null && _ref6 !== void 0 ? _ref6 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25309
+ this.article.calcDepth = Math.round((Number((_ref10 = (_myArtOPS$measureValu2 = myArtOPS.measureValue) !== null && _myArtOPS$measureValu2 !== void 0 ? _myArtOPS$measureValu2 : myArtOPS.value) !== null && _ref10 !== void 0 ? _ref10 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25171
25310
  } catch (e) {
25172
25311
  LOG$f.warn('Invalid Planungdepth - IDMVariantenArt 96: ' + myArtOPS.option.name + ' ' + myArtOPS.valName, e);
25173
25312
  }
25174
25313
  }
25175
25314
  if ([95, 1095].includes((_myArtOPS$option$idmV5 = myArtOPS.option.idmVariantenArt) !== null && _myArtOPS$option$idmV5 !== void 0 ? _myArtOPS$option$idmV5 : 0) || myArtOPS.option.diameter) {
25176
25315
  try {
25177
- var _ref7, _myArtOPS$measureValu3;
25316
+ var _ref11, _myArtOPS$measureValu3;
25178
25317
  this.article.doUpdatePlannerSize = true;
25179
- this.article.calcWidth = Math.round((Number((_ref7 = (_myArtOPS$measureValu3 = myArtOPS.measureValue) !== null && _myArtOPS$measureValu3 !== void 0 ? _myArtOPS$measureValu3 : myArtOPS.value) !== null && _ref7 !== void 0 ? _ref7 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25318
+ this.article.calcWidth = Math.round((Number((_ref11 = (_myArtOPS$measureValu3 = myArtOPS.measureValue) !== null && _myArtOPS$measureValu3 !== void 0 ? _myArtOPS$measureValu3 : myArtOPS.value) !== null && _ref11 !== void 0 ? _ref11 : myArtOPS.valueFromName) + Number.EPSILON) * 100) / 100;
25180
25319
  } catch (e) {
25181
25320
  LOG$f.warn('Invalid Planungdepth - IDMVariantenArt 95: ' + myArtOPS.option.name + ' ' + myArtOPS.valName, e);
25182
25321
  }
@@ -25241,9 +25380,9 @@ var IDMEngine = /*#__PURE__*/function () {
25241
25380
  while (allKeys.find(function (key) {
25242
25381
  return formula.includes(key);
25243
25382
  })) {
25244
- var _key2 = allKeys.shift();
25245
- if (_key2 === undefined) break;
25246
- origFormula = origFormula.replaceAll(_key2, keysMap[_key2].toString());
25383
+ var _key = allKeys.shift();
25384
+ if (_key === undefined) break;
25385
+ origFormula = origFormula.replaceAll(_key, keysMap[_key].toString());
25247
25386
  }
25248
25387
  try {
25249
25388
  return eval(origFormula);
@@ -25295,40 +25434,50 @@ var IDMEngine = /*#__PURE__*/function () {
25295
25434
  }
25296
25435
 
25297
25436
  // this functions updates the images of OPVs that depend on rules
25298
- var _iterator8 = _createForOfIteratorHelper$7(this.article.articleOptionStates),
25437
+ var _iterator8 = _createForOfIteratorHelper$7(this.article.articleOptionStates.values()),
25299
25438
  _step8;
25300
25439
  try {
25301
25440
  for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
25302
25441
  var ops = _step8.value;
25303
- for (var jKey in ops.visibleOptionValues) {
25304
- var opv = ops.visibleOptionValues[jKey];
25305
- if (opv.images) {
25306
- var imageFound = false;
25307
- for (var _i2 = 0; _i2 < opv.images.length; _i2++) {
25308
- var _image$decisionNos2, _image$decisionNos3;
25309
- var _image = opv.images[_i2];
25310
- var _doUse = !((_image$decisionNos2 = _image.decisionNos) !== null && _image$decisionNos2 !== void 0 && _image$decisionNos2.length);
25311
- if ((_image$decisionNos3 = _image.decisionNos) !== null && _image$decisionNos3 !== void 0 && _image$decisionNos3.length) {
25312
- for (var _j2 = 0; _j2 < _image.decisionNos.length; _j2++) {
25313
- var _decision2 = catalogData.getDecisionByNo(_image.decisionNos[_j2]);
25314
- if (!_decision2) throw new Error('decision ' + _image.decisionNos[_j2] + ' not found');
25315
- var _this$getMatchingOpti9 = this.getMatchingOptionCombination(_decision2.optionCombinations),
25316
- _this$getMatchingOpti10 = _slicedToArray__default["default"](_this$getMatchingOpti9, 1),
25317
- _combination2 = _this$getMatchingOpti10[0];
25318
- if (_combination2) {
25319
- _doUse = true;
25320
- break;
25442
+ var _iterator9 = _createForOfIteratorHelper$7(ops.visibleOptionValues),
25443
+ _step9;
25444
+ try {
25445
+ for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
25446
+ var _step9$value = _slicedToArray__default["default"](_step9.value, 2),
25447
+ jKey = _step9$value[0],
25448
+ opv = _step9$value[1];
25449
+ if (opv.images) {
25450
+ var imageFound = false;
25451
+ for (var _i2 = 0; _i2 < opv.images.length; _i2++) {
25452
+ var _image$decisionNos2, _image$decisionNos3;
25453
+ var _image = opv.images[_i2];
25454
+ var _doUse = !((_image$decisionNos2 = _image.decisionNos) !== null && _image$decisionNos2 !== void 0 && _image$decisionNos2.length);
25455
+ if ((_image$decisionNos3 = _image.decisionNos) !== null && _image$decisionNos3 !== void 0 && _image$decisionNos3.length) {
25456
+ for (var _j2 = 0; _j2 < _image.decisionNos.length; _j2++) {
25457
+ var _decision2 = catalogData.getDecisionByNo(_image.decisionNos[_j2]);
25458
+ if (!_decision2) throw new Error('decision ' + _image.decisionNos[_j2] + ' not found');
25459
+ var _this$getMatchingOpti9 = this.getMatchingOptionCombination(_decision2.optionCombinations),
25460
+ _this$getMatchingOpti10 = _slicedToArray__default["default"](_this$getMatchingOpti9, 1),
25461
+ _combination2 = _this$getMatchingOpti10[0];
25462
+ if (_combination2) {
25463
+ _doUse = true;
25464
+ break;
25465
+ }
25321
25466
  }
25322
25467
  }
25468
+ if (_doUse) {
25469
+ ops.editVisibleOPVsImages(opv.codex, _image.url);
25470
+ imageFound = true;
25471
+ break;
25472
+ }
25323
25473
  }
25324
- if (_doUse) {
25325
- ops.editVisibleOPVsImages(opv.codex, _image.url);
25326
- imageFound = true;
25327
- break;
25328
- }
25474
+ if (!imageFound) ops.editVisibleOPVsImages(opv.codex);
25329
25475
  }
25330
- if (!imageFound) ops.editVisibleOPVsImages(opv.codex);
25331
25476
  }
25477
+ } catch (err) {
25478
+ _iterator9.e(err);
25479
+ } finally {
25480
+ _iterator9.f();
25332
25481
  }
25333
25482
  }
25334
25483
 
@@ -25434,8 +25583,8 @@ var IDMEngine = /*#__PURE__*/function () {
25434
25583
  function _createForOfIteratorHelper$6(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$6(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
25435
25584
  function _unsupportedIterableToArray$6(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$6(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$6(r, a) : void 0; } }
25436
25585
  function _arrayLikeToArray$6(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
25437
- function ownKeys$e(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; }
25438
- function _objectSpread$e(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$e(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$e(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
25586
+ function ownKeys$d(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; }
25587
+ function _objectSpread$d(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$d(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$d(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
25439
25588
  var LOG$e = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
25440
25589
  var DivaArticle = /*#__PURE__*/function () {
25441
25590
  function DivaArticle(set, _basketId, initParams, articleData, catalogData) {
@@ -25526,7 +25675,7 @@ var DivaArticle = /*#__PURE__*/function () {
25526
25675
  this.doorPlannerData = this.shelfPlanData.DoorPlannerData;
25527
25676
  }
25528
25677
  this.initPlannerData(articleData);
25529
- this.articleOptionStatesData = []; //Dieses Objekt speichert den aktuellen Werte, Zustand eines Optionsbaumes und Preise
25678
+ this.articleOptionStatesData = new Map(); //Dieses Objekt speichert den aktuellen Werte, Zustand eines Optionsbaumes und Preise
25530
25679
  }
25531
25680
  return _createClass__default["default"](DivaArticle, [{
25532
25681
  key: "initEngine",
@@ -25675,7 +25824,7 @@ var DivaArticle = /*#__PURE__*/function () {
25675
25824
  var partlistArticle = this.partlistArticles[basketId];
25676
25825
  if (!onlyVisible || partlistArticle.partlistArticleVisibleInTree || !excludeStandalonePla && partlistArticle.partlistArticleStandalone) partlistArticles[basketId] = partlistArticle;
25677
25826
  if (partlistArticle.hasPartlistArticle) {
25678
- partlistArticles = _objectSpread$e(_objectSpread$e({}, partlistArticles), partlistArticle.getRecursivePartlistArticles(onlyVisible, excludeStandalonePla));
25827
+ partlistArticles = _objectSpread$d(_objectSpread$d({}, partlistArticles), partlistArticle.getRecursivePartlistArticles(onlyVisible, excludeStandalonePla));
25679
25828
  }
25680
25829
  }
25681
25830
  return partlistArticles;
@@ -25684,8 +25833,8 @@ var DivaArticle = /*#__PURE__*/function () {
25684
25833
  key: "variantValuesForPla",
25685
25834
  value: function variantValuesForPla(configurationMode, previousPartlistArticleVariantValues, newConfigValues) {
25686
25835
  //if configurationMode is true its previous values are more important than the values of the parentelement because its standalone configurable
25687
- if (configurationMode) return _objectSpread$e(_objectSpread$e({}, newConfigValues !== null && newConfigValues !== void 0 ? newConfigValues : {}), previousPartlistArticleVariantValues !== null && previousPartlistArticleVariantValues !== void 0 ? previousPartlistArticleVariantValues : {});
25688
- return _objectSpread$e(_objectSpread$e({}, previousPartlistArticleVariantValues !== null && previousPartlistArticleVariantValues !== void 0 ? previousPartlistArticleVariantValues : {}), newConfigValues !== null && newConfigValues !== void 0 ? newConfigValues : {});
25836
+ if (configurationMode) return _objectSpread$d(_objectSpread$d({}, newConfigValues !== null && newConfigValues !== void 0 ? newConfigValues : {}), previousPartlistArticleVariantValues !== null && previousPartlistArticleVariantValues !== void 0 ? previousPartlistArticleVariantValues : {});
25837
+ return _objectSpread$d(_objectSpread$d({}, previousPartlistArticleVariantValues !== null && previousPartlistArticleVariantValues !== void 0 ? previousPartlistArticleVariantValues : {}), newConfigValues !== null && newConfigValues !== void 0 ? newConfigValues : {});
25689
25838
  }
25690
25839
  }, {
25691
25840
  key: "partlistArticlesAsArray",
@@ -25917,7 +26066,7 @@ var DivaArticle = /*#__PURE__*/function () {
25917
26066
  key: "getTabgroupsAsString",
25918
26067
  get: function get() {
25919
26068
  var ret = '';
25920
- var _iterator = _createForOfIteratorHelper$6(this.articleOptionStates),
26069
+ var _iterator = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
25921
26070
  _step;
25922
26071
  try {
25923
26072
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -25939,7 +26088,7 @@ var DivaArticle = /*#__PURE__*/function () {
25939
26088
  key: "articleVariantValues",
25940
26089
  get: function get() {
25941
26090
  var ret = '';
25942
- var _iterator2 = _createForOfIteratorHelper$6(this.articleOptionStates),
26091
+ var _iterator2 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
25943
26092
  _step2;
25944
26093
  try {
25945
26094
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
@@ -26015,26 +26164,18 @@ var DivaArticle = /*#__PURE__*/function () {
26015
26164
  }, {
26016
26165
  key: "getArticleOptionStatesWithOptionsForPrint",
26017
26166
  value: function getArticleOptionStatesWithOptionsForPrint() {
26018
- var _this2 = this;
26019
- var opsArray = _toConsumableArray__default["default"](this.articleOptionStates);
26167
+ var opsMap = new Map(this.articleOptionStates);
26020
26168
  var optionsForPrint = this.optionsForPrint;
26021
26169
  if (optionsForPrint) {
26022
- var _loop = function _loop() {
26023
- var ops = _this2.getArticleOptionState(optionsForPrint[i]);
26170
+ for (var i = 0; i < optionsForPrint.length; i++) {
26171
+ var ops = this.getArticleOptionState(optionsForPrint[i]);
26024
26172
  if (ops) {
26025
- if (opsArray.find(function (o) {
26026
- return o.optionCodex == ops.optionCodex;
26027
- })) opsArray.splice(opsArray.findIndex(function (o) {
26028
- return o.optionCodex == ops.optionCodex;
26029
- }));
26030
- opsArray.push(ops);
26173
+ if (opsMap.has(ops.optionCodex)) opsMap["delete"](ops.optionCodex);
26174
+ opsMap.set(ops.optionCodex, ops);
26031
26175
  }
26032
- };
26033
- for (var i = 0; i < optionsForPrint.length; i++) {
26034
- _loop();
26035
26176
  }
26036
26177
  }
26037
- return opsArray;
26178
+ return opsMap;
26038
26179
  }
26039
26180
  }, {
26040
26181
  key: "articleVariantDesc",
@@ -26042,7 +26183,7 @@ var DivaArticle = /*#__PURE__*/function () {
26042
26183
  var newLine = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ', ';
26043
26184
  var articleOptions = this.getArticleOptionStatesWithOptionsForPrint();
26044
26185
  var ret = '';
26045
- var _iterator3 = _createForOfIteratorHelper$6(articleOptions),
26186
+ var _iterator3 = _createForOfIteratorHelper$6(articleOptions.values()),
26046
26187
  _step3;
26047
26188
  try {
26048
26189
  for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
@@ -26075,7 +26216,7 @@ var DivaArticle = /*#__PURE__*/function () {
26075
26216
  value: function articleVariantDesc_locales() {
26076
26217
  var newLine = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ', ';
26077
26218
  var ret = {};
26078
- var _iterator4 = _createForOfIteratorHelper$6(this.articleOptionStates),
26219
+ var _iterator4 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
26079
26220
  _step4;
26080
26221
  try {
26081
26222
  for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
@@ -26281,8 +26422,7 @@ var DivaArticle = /*#__PURE__*/function () {
26281
26422
  }, {
26282
26423
  key: "hasArticleOptionStates",
26283
26424
  get: function get() {
26284
- var _this$articleOptionSt;
26285
- return !!((_this$articleOptionSt = this.articleOptionStatesData) !== null && _this$articleOptionSt !== void 0 && _this$articleOptionSt.length);
26425
+ return this.articleOptionStatesData.size > 0;
26286
26426
  }
26287
26427
  }, {
26288
26428
  key: "articleOptionStates",
@@ -26292,25 +26432,23 @@ var DivaArticle = /*#__PURE__*/function () {
26292
26432
  }, {
26293
26433
  key: "articleOptionStatesKeys",
26294
26434
  get: function get() {
26295
- return this.articleOptionStatesData.map(function (ops) {
26296
- return ops.optionCodex;
26297
- });
26435
+ return Array.from(this.articleOptionStatesData.keys());
26298
26436
  }
26299
26437
  }, {
26300
26438
  key: "articleOptionStatesWithParents",
26301
26439
  get: function get() {
26302
- return [].concat(_toConsumableArray__default["default"](this.getReqursiveArticleOptionStates()), _toConsumableArray__default["default"](this.articleOptionStatesData));
26440
+ return [].concat(_toConsumableArray__default["default"](this.getReqursiveArticleOptionStates()), _toConsumableArray__default["default"](this.articleOptionStates.values()));
26303
26441
  }
26304
26442
  }, {
26305
26443
  key: "getReqursiveArticleOptionStates",
26306
26444
  value: function getReqursiveArticleOptionStates() {
26307
26445
  var _this$partListParentA5, _this$partListParentA6, _this$partListParentA7, _this$partListParentA8, _this$accessoireParen3, _this$accessoireParen4, _this$accessoireParen5, _this$accessoireParen6;
26308
- return [].concat(_toConsumableArray__default["default"]((_this$partListParentA5 = (_this$partListParentA6 = this.partListParentArticle) === null || _this$partListParentA6 === void 0 ? void 0 : _this$partListParentA6.articleOptionStatesData) !== null && _this$partListParentA5 !== void 0 ? _this$partListParentA5 : []), _toConsumableArray__default["default"]((_this$partListParentA7 = (_this$partListParentA8 = this.partListParentArticle) === null || _this$partListParentA8 === void 0 ? void 0 : _this$partListParentA8.getReqursiveArticleOptionStates()) !== null && _this$partListParentA7 !== void 0 ? _this$partListParentA7 : []), _toConsumableArray__default["default"]((_this$accessoireParen3 = (_this$accessoireParen4 = this.accessoireParentArticle) === null || _this$accessoireParen4 === void 0 ? void 0 : _this$accessoireParen4.articleOptionStatesData) !== null && _this$accessoireParen3 !== void 0 ? _this$accessoireParen3 : []), _toConsumableArray__default["default"]((_this$accessoireParen5 = (_this$accessoireParen6 = this.accessoireParentArticle) === null || _this$accessoireParen6 === void 0 ? void 0 : _this$accessoireParen6.getReqursiveArticleOptionStates()) !== null && _this$accessoireParen5 !== void 0 ? _this$accessoireParen5 : []));
26446
+ return [].concat(_toConsumableArray__default["default"]((_this$partListParentA5 = (_this$partListParentA6 = this.partListParentArticle) === null || _this$partListParentA6 === void 0 ? void 0 : _this$partListParentA6.articleOptionStates.values()) !== null && _this$partListParentA5 !== void 0 ? _this$partListParentA5 : []), _toConsumableArray__default["default"]((_this$partListParentA7 = (_this$partListParentA8 = this.partListParentArticle) === null || _this$partListParentA8 === void 0 ? void 0 : _this$partListParentA8.getReqursiveArticleOptionStates()) !== null && _this$partListParentA7 !== void 0 ? _this$partListParentA7 : []), _toConsumableArray__default["default"]((_this$accessoireParen3 = (_this$accessoireParen4 = this.accessoireParentArticle) === null || _this$accessoireParen4 === void 0 ? void 0 : _this$accessoireParen4.articleOptionStates.values()) !== null && _this$accessoireParen3 !== void 0 ? _this$accessoireParen3 : []), _toConsumableArray__default["default"]((_this$accessoireParen5 = (_this$accessoireParen6 = this.accessoireParentArticle) === null || _this$accessoireParen6 === void 0 ? void 0 : _this$accessoireParen6.getReqursiveArticleOptionStates()) !== null && _this$accessoireParen5 !== void 0 ? _this$accessoireParen5 : []));
26309
26447
  }
26310
26448
  }, {
26311
26449
  key: "getAllArticleOptionsStates",
26312
26450
  value: function getAllArticleOptionsStates() {
26313
- var opss = _toConsumableArray__default["default"](this.articleOptionStates);
26451
+ var opss = _toConsumableArray__default["default"](this.articleOptionStates.values());
26314
26452
  for (var key in this.partlistArticles) {
26315
26453
  opss = [].concat(_toConsumableArray__default["default"](opss), _toConsumableArray__default["default"](this.partlistArticles[key].getAllArticleOptionsStates()));
26316
26454
  }
@@ -26319,7 +26457,7 @@ var DivaArticle = /*#__PURE__*/function () {
26319
26457
  }, {
26320
26458
  key: "clearArticleOptionStates",
26321
26459
  value: function clearArticleOptionStates() {
26322
- this.articleOptionStatesData = [];
26460
+ this.articleOptionStatesData.clear();
26323
26461
  }
26324
26462
  }, {
26325
26463
  key: "articleGUID",
@@ -26334,17 +26472,13 @@ var DivaArticle = /*#__PURE__*/function () {
26334
26472
  }, {
26335
26473
  key: "getArticleOptionStateFlat",
26336
26474
  value: function getArticleOptionStateFlat(codex) {
26337
- return this.articleOptionStatesData.find(function (ops) {
26338
- return ops.optionCodex == codex;
26339
- });
26475
+ return this.articleOptionStatesData.get(codex);
26340
26476
  }
26341
26477
  }, {
26342
26478
  key: "getArticleOptionState",
26343
26479
  value: function getArticleOptionState(codex, from, checkOnAccessoireParent) {
26344
26480
  var _this$partlistArticle3;
26345
- var firstMatch = this.articleOptionStatesData.find(function (ops) {
26346
- return ops.optionCodex == codex;
26347
- });
26481
+ var firstMatch = this.articleOptionStatesData.get(codex);
26348
26482
  if (firstMatch) return firstMatch;
26349
26483
  var parentArticle = this.partListParentArticle;
26350
26484
  if (from !== (parentArticle === null || parentArticle === void 0 ? void 0 : parentArticle.basketId) && parentArticle !== null && parentArticle !== void 0 && parentArticle.getArticleOptionState(codex, undefined, checkOnAccessoireParent)) {
@@ -26359,7 +26493,7 @@ var DivaArticle = /*#__PURE__*/function () {
26359
26493
  if (_ops) return _ops;
26360
26494
  }
26361
26495
  }
26362
- var _iterator5 = _createForOfIteratorHelper$6(this.articleOptionStatesData),
26496
+ var _iterator5 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
26363
26497
  _step5;
26364
26498
  try {
26365
26499
  for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
@@ -26391,7 +26525,7 @@ var DivaArticle = /*#__PURE__*/function () {
26391
26525
  }, {
26392
26526
  key: "getValueByMeasureKey",
26393
26527
  value: function getValueByMeasureKey(measureKey) {
26394
- var _iterator6 = _createForOfIteratorHelper$6(this.articleOptionStates),
26528
+ var _iterator6 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
26395
26529
  _step6;
26396
26530
  try {
26397
26531
  for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
@@ -26416,10 +26550,7 @@ var DivaArticle = /*#__PURE__*/function () {
26416
26550
  }, {
26417
26551
  key: "uploadOptionState",
26418
26552
  value: function uploadOptionState(articleOptionState) {
26419
- var oldIndex = this.articleOptionStatesData.findIndex(function (ops) {
26420
- return ops.optionCodex == articleOptionState.optionCodex;
26421
- });
26422
- if (oldIndex !== -1) this.articleOptionStatesData[oldIndex] = articleOptionState;else this.articleOptionStatesData.push(articleOptionState);
26553
+ this.articleOptionStatesData.set(articleOptionState.optionCodex, articleOptionState);
26423
26554
  }
26424
26555
  }, {
26425
26556
  key: "partlistArticlesRules",
@@ -26478,7 +26609,7 @@ var DivaArticle = /*#__PURE__*/function () {
26478
26609
  key: "typeNr",
26479
26610
  get: function get() {
26480
26611
  if (this.supplierOrderCodex) return this.supplierOrderCodex;
26481
- var _iterator7 = _createForOfIteratorHelper$6(this.articleOptionStates),
26612
+ var _iterator7 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
26482
26613
  _step7;
26483
26614
  try {
26484
26615
  for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {
@@ -27046,7 +27177,7 @@ var DivaArticle = /*#__PURE__*/function () {
27046
27177
  key: "VariantValues",
27047
27178
  get: function get() {
27048
27179
  var ret = {};
27049
- var _iterator8 = _createForOfIteratorHelper$6(this.articleOptionStates),
27180
+ var _iterator8 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27050
27181
  _step8;
27051
27182
  try {
27052
27183
  for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
@@ -27069,7 +27200,7 @@ var DivaArticle = /*#__PURE__*/function () {
27069
27200
  key: "snapshot",
27070
27201
  get: function get() {
27071
27202
  var ret = {};
27072
- var _iterator9 = _createForOfIteratorHelper$6(this.articleOptionStates),
27203
+ var _iterator9 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27073
27204
  _step9;
27074
27205
  try {
27075
27206
  for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
@@ -27147,7 +27278,7 @@ var DivaArticle = /*#__PURE__*/function () {
27147
27278
  key: "VariantValuesWithoutFreetext",
27148
27279
  get: function get() {
27149
27280
  var ret = {};
27150
- var _iterator12 = _createForOfIteratorHelper$6(this.articleOptionStates),
27281
+ var _iterator12 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27151
27282
  _step12;
27152
27283
  try {
27153
27284
  for (_iterator12.s(); !(_step12 = _iterator12.n()).done;) {
@@ -27167,7 +27298,7 @@ var DivaArticle = /*#__PURE__*/function () {
27167
27298
  key: "VariantValuesParentOption",
27168
27299
  get: function get() {
27169
27300
  var ret = {};
27170
- var _iterator13 = _createForOfIteratorHelper$6(this.articleOptionStates),
27301
+ var _iterator13 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27171
27302
  _step13;
27172
27303
  try {
27173
27304
  for (_iterator13.s(); !(_step13 = _iterator13.n()).done;) {
@@ -27202,7 +27333,7 @@ var DivaArticle = /*#__PURE__*/function () {
27202
27333
  }, {
27203
27334
  key: "setDifferentOptions",
27204
27335
  value: function setDifferentOptions(options) {
27205
- var _iterator14 = _createForOfIteratorHelper$6(this.articleOptionStates),
27336
+ var _iterator14 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27206
27337
  _step14;
27207
27338
  try {
27208
27339
  for (_iterator14.s(); !(_step14 = _iterator14.n()).done;) {
@@ -27236,7 +27367,7 @@ var DivaArticle = /*#__PURE__*/function () {
27236
27367
  get: function get() {
27237
27368
  var hash = this.catalogCodex + '_' + this.articleCodex + '_' + this.quantity + '_';
27238
27369
  var variantValues = [];
27239
- var _iterator15 = _createForOfIteratorHelper$6(this.articleOptionStates),
27370
+ var _iterator15 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27240
27371
  _step15;
27241
27372
  try {
27242
27373
  for (_iterator15.s(); !(_step15 = _iterator15.n()).done;) {
@@ -27257,7 +27388,7 @@ var DivaArticle = /*#__PURE__*/function () {
27257
27388
  key: "VariantValuesWithoutOPTandOPV",
27258
27389
  get: function get() {
27259
27390
  var ret = {};
27260
- var _iterator16 = _createForOfIteratorHelper$6(this.articleOptionStates),
27391
+ var _iterator16 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27261
27392
  _step16;
27262
27393
  try {
27263
27394
  for (_iterator16.s(); !(_step16 = _iterator16.n()).done;) {
@@ -27291,7 +27422,7 @@ var DivaArticle = /*#__PURE__*/function () {
27291
27422
  key: "getVariantValuesTillOPT",
27292
27423
  value: function getVariantValuesTillOPT(opt) {
27293
27424
  var ret = {};
27294
- var _iterator17 = _createForOfIteratorHelper$6(this.articleOptionStates),
27425
+ var _iterator17 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27295
27426
  _step17;
27296
27427
  try {
27297
27428
  for (_iterator17.s(); !(_step17 = _iterator17.n()).done;) {
@@ -27315,14 +27446,14 @@ var DivaArticle = /*#__PURE__*/function () {
27315
27446
  key: "areAllOptionsDefined",
27316
27447
  get: function get() {
27317
27448
  if (this.CatalogData.ignoreIsDefinedCheck) return true;
27318
- return !this.articleOptionStates.find(function (ops) {
27449
+ return !Array.from(this.articleOptionStates.values()).find(function (ops) {
27319
27450
  return !ops.isDefined;
27320
27451
  });
27321
27452
  }
27322
27453
  }, {
27323
27454
  key: "optionStatesWithAddToMeasure",
27324
27455
  value: function optionStatesWithAddToMeasure(opt) {
27325
- return this.articleOptionStates.filter(function (ops) {
27456
+ return Array.from(this.articleOptionStates.values()).filter(function (ops) {
27326
27457
  var _ops$addToMeasure, _ops$addToMeasure2;
27327
27458
  return ((_ops$addToMeasure = ops.addToMeasure) === null || _ops$addToMeasure === void 0 ? void 0 : _ops$addToMeasure.find(function (o) {
27328
27459
  return o.opt == opt;
@@ -27333,7 +27464,7 @@ var DivaArticle = /*#__PURE__*/function () {
27333
27464
  key: "requiredUserInputOptions",
27334
27465
  get: function get() {
27335
27466
  var options = [];
27336
- var _iterator18 = _createForOfIteratorHelper$6(this.articleOptionStates),
27467
+ var _iterator18 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27337
27468
  _step18;
27338
27469
  try {
27339
27470
  for (_iterator18.s(); !(_step18 = _iterator18.n()).done;) {
@@ -27433,7 +27564,7 @@ var DivaArticle = /*#__PURE__*/function () {
27433
27564
  key: "getMetaData",
27434
27565
  value: function getMetaData(locales) {
27435
27566
  var metaDatas = locales ? this.article.catalogArticle.metaData_locales : this.article.catalogArticle.metaData;
27436
- var _iterator19 = _createForOfIteratorHelper$6(this.articleOptionStates),
27567
+ var _iterator19 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27437
27568
  _step19;
27438
27569
  try {
27439
27570
  for (_iterator19.s(); !(_step19 = _iterator19.n()).done;) {
@@ -27505,46 +27636,67 @@ var DivaArticle = /*#__PURE__*/function () {
27505
27636
  opvDoesExist = false;
27506
27637
  var opvsInOption = refOptData.articleOptionValues;
27507
27638
  if (refOptData.hasOPG && opvsInOption) {
27508
- for (var iKey in opvsInOption) {
27509
- if (opvIsValid && anyDoShowFound) break;
27510
- var opg = opvsInOption[iKey];
27511
- var opvsFromOpg = opg.articleOptionValues;
27512
- if (!opvsFromOpg) continue;
27513
- if (refOps.visibleOptionValues[iKey]) {
27514
- anyDoShowFound = true;
27515
- }
27516
- for (var jKey in opvsFromOpg) {
27517
- if (refOps.visibleOptionValues[iKey]) {
27518
- var parentName = opvsFromOpg[jKey].parentName;
27519
- if (parentName) {
27520
- alternativeOPV[jKey] = parentName;
27521
- } else {
27522
- alternativeOPV[jKey] = opvsFromOpg[jKey].name;
27523
- }
27639
+ var _iterator20 = _createForOfIteratorHelper$6(opvsInOption),
27640
+ _step20;
27641
+ try {
27642
+ for (_iterator20.s(); !(_step20 = _iterator20.n()).done;) {
27643
+ var _step20$value = _slicedToArray__default["default"](_step20.value, 2),
27644
+ iKey = _step20$value[0],
27645
+ opg = _step20$value[1];
27646
+ if (opvIsValid && anyDoShowFound) break;
27647
+ var opvsFromOpg = opg.articleOptionValues;
27648
+ if (!opvsFromOpg) continue;
27649
+ if (refOps.visibleOptionValues.get(iKey)) {
27650
+ anyDoShowFound = true;
27524
27651
  }
27525
- if (jKey == curOpvValue) {
27526
- //Der Artikel darf den Optionswert von der BaseOption übernehmen
27527
- opvDoesExist = true;
27528
- if (refOps.visibleOptionValues[iKey]) {
27529
- refOps.defaultOPV = curOpvValue;
27530
- optToChange[refOptCodex] = curOpvValue;
27531
- opvIsValid = true;
27652
+ var _iterator21 = _createForOfIteratorHelper$6(opvsFromOpg),
27653
+ _step21;
27654
+ try {
27655
+ for (_iterator21.s(); !(_step21 = _iterator21.n()).done;) {
27656
+ var _step21$value = _slicedToArray__default["default"](_step21.value, 2),
27657
+ jKey = _step21$value[0],
27658
+ opv = _step21$value[1];
27659
+ if (refOps.visibleOptionValues.get(iKey)) {
27660
+ var parentName = opv.parentName;
27661
+ if (parentName) {
27662
+ alternativeOPV[jKey] = parentName;
27663
+ } else {
27664
+ alternativeOPV[jKey] = opv.name;
27665
+ }
27666
+ }
27667
+ if (jKey == curOpvValue) {
27668
+ //Der Artikel darf den Optionswert von der BaseOption übernehmen
27669
+ opvDoesExist = true;
27670
+ if (refOps.visibleOptionValues.get(iKey)) {
27671
+ refOps.defaultOPV = curOpvValue;
27672
+ optToChange[refOptCodex] = curOpvValue;
27673
+ opvIsValid = true;
27674
+ }
27675
+ break;
27676
+ }
27532
27677
  }
27533
- break;
27678
+ } catch (err) {
27679
+ _iterator21.e(err);
27680
+ } finally {
27681
+ _iterator21.f();
27534
27682
  }
27535
27683
  }
27684
+ } catch (err) {
27685
+ _iterator20.e(err);
27686
+ } finally {
27687
+ _iterator20.f();
27536
27688
  }
27537
27689
  } else if (opvsInOption) {
27538
27690
  for (var _iKey in opvsInOption) {
27539
27691
  if (opvIsValid && anyDoShowFound) break;
27540
- if (refOps.visibleOptionValues[_iKey]) {
27692
+ if (refOps.visibleOptionValues.get(_iKey)) {
27541
27693
  anyDoShowFound = true;
27542
- alternativeOPV[_iKey] = opvsInOption[_iKey].name;
27694
+ alternativeOPV[_iKey] = opvsInOption.get(_iKey).name;
27543
27695
  }
27544
27696
  if (_iKey == curOpvValue || this.hasType1Dependencies && curOpvValue.replace('OPV' + opt.substring(3), '') == _iKey.replace('OPV' + refOps.optionCodex.substring(3), '')) {
27545
27697
  //Der Artikel darf den Optionswert von der BaseOption übernehmen
27546
27698
  opvDoesExist = true;
27547
- if (refOps.visibleOptionValues[_iKey]) {
27699
+ if (refOps.visibleOptionValues.get(_iKey)) {
27548
27700
  refOps.defaultOPV = _iKey;
27549
27701
  optToChange[refOptCodex] = _iKey;
27550
27702
  if (optToChange[opt + '_val']) {
@@ -27603,11 +27755,11 @@ var DivaArticle = /*#__PURE__*/function () {
27603
27755
  for (var _i3 = 0; _i3 < articles.length; _i3++) {
27604
27756
  var variantValues = {};
27605
27757
  var accessoire = articles[_i3];
27606
- var _iterator20 = _createForOfIteratorHelper$6(accessoire.articleOptionStates),
27607
- _step20;
27758
+ var _iterator22 = _createForOfIteratorHelper$6(accessoire.articleOptionStates.values()),
27759
+ _step22;
27608
27760
  try {
27609
- for (_iterator20.s(); !(_step20 = _iterator20.n()).done;) {
27610
- var ops = _step20.value;
27761
+ for (_iterator22.s(); !(_step22 = _iterator22.n()).done;) {
27762
+ var ops = _step22.value;
27611
27763
  if (singleOpts.includes(ops.optionCodex)) {
27612
27764
  if (accessoire.hasType1Dependencies) {
27613
27765
  variantValues[ops.optionCodex] = curOpvValue.replace('OPV' + opt.substring(3), 'OPV' + ops.optionCodex.substring(3));
@@ -27617,9 +27769,9 @@ var DivaArticle = /*#__PURE__*/function () {
27617
27769
  }
27618
27770
  }
27619
27771
  } catch (err) {
27620
- _iterator20.e(err);
27772
+ _iterator22.e(err);
27621
27773
  } finally {
27622
- _iterator20.f();
27774
+ _iterator22.f();
27623
27775
  }
27624
27776
  if (Object.entries(variantValues).length > 0) accessoiresToUpdate[accessoire.basketId] = {
27625
27777
  accessoire: accessoire,
@@ -27635,11 +27787,11 @@ var DivaArticle = /*#__PURE__*/function () {
27635
27787
  value: function getGlobalOptions() {
27636
27788
  var ret = {};
27637
27789
  var opss = this.articleOptionStatesWithParents;
27638
- var _iterator21 = _createForOfIteratorHelper$6(opss),
27639
- _step21;
27790
+ var _iterator23 = _createForOfIteratorHelper$6(opss),
27791
+ _step23;
27640
27792
  try {
27641
- for (_iterator21.s(); !(_step21 = _iterator21.n()).done;) {
27642
- var ops = _step21.value;
27793
+ for (_iterator23.s(); !(_step23 = _iterator23.n()).done;) {
27794
+ var ops = _step23.value;
27643
27795
  var value = ops.option.isDefaultValueForOptions;
27644
27796
  if (value) {
27645
27797
  var entires = value.split(';');
@@ -27648,9 +27800,9 @@ var DivaArticle = /*#__PURE__*/function () {
27648
27800
  }
27649
27801
  }
27650
27802
  } catch (err) {
27651
- _iterator21.e(err);
27803
+ _iterator23.e(err);
27652
27804
  } finally {
27653
- _iterator21.f();
27805
+ _iterator23.f();
27654
27806
  }
27655
27807
  return ret;
27656
27808
  }
@@ -27690,34 +27842,34 @@ var DivaArticle = /*#__PURE__*/function () {
27690
27842
  }
27691
27843
  if (Object.keys(ret.opt).length === 0) {
27692
27844
  //nicht gefunden - jetzt OCD kontrollieren
27693
- var _iterator22 = _createForOfIteratorHelper$6(this.articleOptionStates),
27694
- _step22;
27845
+ var _iterator24 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27846
+ _step24;
27695
27847
  try {
27696
- for (_iterator22.s(); !(_step22 = _iterator22.n()).done;) {
27697
- var _ops4 = _step22.value;
27848
+ for (_iterator24.s(); !(_step24 = _iterator24.n()).done;) {
27849
+ var _ops4 = _step24.value;
27698
27850
  if (_ops4.option.ocd == optionCodex && _ops4.isDoShow && (parentOptionCodex == '' || parentOptionCodex == _ops4.option.parentOptionCodex)) {
27699
27851
  ret = this.checkOptionSearchOPV(_ops4.option, optionValueCodex, ret);
27700
27852
  }
27701
27853
  }
27702
27854
  //fallback for pfister classification usecase
27703
27855
  } catch (err) {
27704
- _iterator22.e(err);
27856
+ _iterator24.e(err);
27705
27857
  } finally {
27706
- _iterator22.f();
27858
+ _iterator24.f();
27707
27859
  }
27708
- var _iterator23 = _createForOfIteratorHelper$6(this.articleOptionStates),
27709
- _step23;
27860
+ var _iterator25 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27861
+ _step25;
27710
27862
  try {
27711
- for (_iterator23.s(); !(_step23 = _iterator23.n()).done;) {
27712
- var _ops5 = _step23.value;
27863
+ for (_iterator25.s(); !(_step25 = _iterator25.n()).done;) {
27864
+ var _ops5 = _step25.value;
27713
27865
  if (_ops5.option.ocd == optionCodex && optionCodex !== null && optionCodex !== void 0 && optionCodex.startsWith('OPTOPT') && (parentOptionCodex == '' || parentOptionCodex == _ops5.option.parentOptionCodex)) {
27714
27866
  return this.checkOptionSearchOPV(_ops5.option, optionValueCodex, ret);
27715
27867
  }
27716
27868
  }
27717
27869
  } catch (err) {
27718
- _iterator23.e(err);
27870
+ _iterator25.e(err);
27719
27871
  } finally {
27720
- _iterator23.f();
27872
+ _iterator25.f();
27721
27873
  }
27722
27874
  }
27723
27875
  }
@@ -27733,46 +27885,89 @@ var DivaArticle = /*#__PURE__*/function () {
27733
27885
  }
27734
27886
  if (myOPT.hasOPG) {
27735
27887
  var myOPGs = myOPT.articleOptionValues;
27736
- for (var iKey in myOPGs) {
27737
- var myOPVs = myOPGs[iKey].articleOptionValues;
27738
- if (myOPVs && myOPVs[optionValueCodex]) {
27739
- ret.opv = myOPVs[optionValueCodex];
27740
- found = true;
27741
- }
27742
- if (!found) {
27743
- for (var jKey in myOPVs) {
27744
- if (myOPVs[jKey].ocd == optionValueCodex || myOPVs[jKey].codex == optionValueCodex || optionValueCodex === 'OPVOPV_NICHT_RELEVANT' && jKey.startsWith('OPVOPV_NICHT_RELEVANT')) {
27745
- ret.opv = myOPVs[jKey];
27746
- found = true;
27747
- break;
27888
+ var _iterator26 = _createForOfIteratorHelper$6(myOPGs),
27889
+ _step26;
27890
+ try {
27891
+ for (_iterator26.s(); !(_step26 = _iterator26.n()).done;) {
27892
+ var _step26$value = _slicedToArray__default["default"](_step26.value, 2),
27893
+ iKey = _step26$value[0],
27894
+ opg = _step26$value[1];
27895
+ var myOPVs = opg.articleOptionValues;
27896
+ if (myOPVs && myOPVs.get(optionValueCodex)) {
27897
+ ret.opv = myOPVs.get(optionValueCodex);
27898
+ found = true;
27899
+ }
27900
+ if (!found) {
27901
+ var _iterator27 = _createForOfIteratorHelper$6(myOPVs),
27902
+ _step27;
27903
+ try {
27904
+ for (_iterator27.s(); !(_step27 = _iterator27.n()).done;) {
27905
+ var _step27$value = _slicedToArray__default["default"](_step27.value, 2),
27906
+ jKey = _step27$value[0],
27907
+ opv = _step27$value[1];
27908
+ if (opv.ocd == optionValueCodex || opv.codex == optionValueCodex || optionValueCodex === 'OPVOPV_NICHT_RELEVANT' && jKey.startsWith('OPVOPV_NICHT_RELEVANT')) {
27909
+ ret.opv = opv;
27910
+ found = true;
27911
+ break;
27912
+ }
27913
+ }
27914
+ } catch (err) {
27915
+ _iterator27.e(err);
27916
+ } finally {
27917
+ _iterator27.f();
27748
27918
  }
27749
27919
  }
27750
- }
27751
- if (!found && myOPT.parentOptionCodex) {
27752
- for (var _jKey in myOPVs) {
27753
- var opv = myOPVs[_jKey];
27754
- if (opv.ocd && opv.ocd.startsWith(optionValueCodex) || opv.codex.startsWith(optionValueCodex)) {
27755
- ret.opv = myOPVs[_jKey];
27756
- found = true;
27757
- break;
27920
+ if (!found && myOPT.parentOptionCodex) {
27921
+ var _iterator28 = _createForOfIteratorHelper$6(myOPVs),
27922
+ _step28;
27923
+ try {
27924
+ for (_iterator28.s(); !(_step28 = _iterator28.n()).done;) {
27925
+ var _step28$value = _slicedToArray__default["default"](_step28.value, 2),
27926
+ _jKey = _step28$value[0],
27927
+ _opv = _step28$value[1];
27928
+ if (_opv.ocd && _opv.ocd.startsWith(optionValueCodex) || _opv.codex.startsWith(optionValueCodex)) {
27929
+ ret.opv = _opv;
27930
+ found = true;
27931
+ break;
27932
+ }
27933
+ }
27934
+ } catch (err) {
27935
+ _iterator28.e(err);
27936
+ } finally {
27937
+ _iterator28.f();
27758
27938
  }
27759
27939
  }
27940
+ if (ret.opv && Object.entries(ret.opv).length != 0) break;
27760
27941
  }
27761
- if (ret.opv && Object.entries(ret.opv).length != 0) break;
27942
+ } catch (err) {
27943
+ _iterator26.e(err);
27944
+ } finally {
27945
+ _iterator26.f();
27762
27946
  }
27763
27947
  } else {
27764
27948
  var _myOPVs = myOPT.articleOptionValues;
27765
- if (_myOPVs && _myOPVs[optionValueCodex]) {
27766
- ret.opv = _myOPVs[optionValueCodex];
27949
+ if (_myOPVs && _myOPVs.get(optionValueCodex)) {
27950
+ ret.opv = _myOPVs.get(optionValueCodex);
27767
27951
  found = true;
27768
27952
  }
27769
27953
  if (!found) {
27770
- for (var _jKey2 in _myOPVs) {
27771
- if (_myOPVs[_jKey2].ocd == optionValueCodex || optionValueCodex === 'OPVOPV_NICHT_RELEVANT' && _jKey2.startsWith('OPVOPV_NICHT_RELEVANT')) {
27772
- ret.opv = _myOPVs[_jKey2];
27773
- found = true;
27774
- break;
27954
+ var _iterator29 = _createForOfIteratorHelper$6(_myOPVs),
27955
+ _step29;
27956
+ try {
27957
+ for (_iterator29.s(); !(_step29 = _iterator29.n()).done;) {
27958
+ var _step29$value = _slicedToArray__default["default"](_step29.value, 2),
27959
+ _jKey2 = _step29$value[0],
27960
+ _opv2 = _step29$value[1];
27961
+ if (_opv2.ocd == optionValueCodex || optionValueCodex === 'OPVOPV_NICHT_RELEVANT' && _jKey2.startsWith('OPVOPV_NICHT_RELEVANT')) {
27962
+ ret.opv = _opv2;
27963
+ found = true;
27964
+ break;
27965
+ }
27775
27966
  }
27967
+ } catch (err) {
27968
+ _iterator29.e(err);
27969
+ } finally {
27970
+ _iterator29.f();
27776
27971
  }
27777
27972
  }
27778
27973
  }
@@ -27782,11 +27977,11 @@ var DivaArticle = /*#__PURE__*/function () {
27782
27977
  key: "getArticleJsonVariantValues",
27783
27978
  value: function getArticleJsonVariantValues() {
27784
27979
  var retval = {};
27785
- var _iterator24 = _createForOfIteratorHelper$6(this.articleOptionStates),
27786
- _step24;
27980
+ var _iterator30 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
27981
+ _step30;
27787
27982
  try {
27788
- for (_iterator24.s(); !(_step24 = _iterator24.n()).done;) {
27789
- var ops = _step24.value;
27983
+ for (_iterator30.s(); !(_step30 = _iterator30.n()).done;) {
27984
+ var ops = _step30.value;
27790
27985
  if (ops.valCodex) {
27791
27986
  retval[ops.optionCodex] = ops.valCodex;
27792
27987
  var opsVal = this.getArticleOptionStateFlat(ops.optionCodex + '_val');
@@ -27799,9 +27994,9 @@ var DivaArticle = /*#__PURE__*/function () {
27799
27994
  }
27800
27995
  }
27801
27996
  } catch (err) {
27802
- _iterator24.e(err);
27997
+ _iterator30.e(err);
27803
27998
  } finally {
27804
- _iterator24.f();
27999
+ _iterator30.f();
27805
28000
  }
27806
28001
  return retval;
27807
28002
  }
@@ -27819,13 +28014,13 @@ var DivaArticle = /*#__PURE__*/function () {
27819
28014
  }, {
27820
28015
  key: "handleMultiselect",
27821
28016
  value: function handleMultiselect(ops, newConfigValues, key) {
27822
- var _this3 = this;
28017
+ var _this2 = this;
27823
28018
  var _this$parentOptionCod3 = this.parentOptionCodex(key),
27824
28019
  optionCodex = _this$parentOptionCod3.optionCodex,
27825
28020
  partenOptionCodex = _this$parentOptionCod3.partenOptionCodex;
27826
28021
  var codexes = newConfigValues[key].split(';');
27827
28022
  var values = codexes.map(function (c) {
27828
- return _this3.checkOptionAndOptionValue(optionCodex, c, partenOptionCodex);
28023
+ return _this2.checkOptionAndOptionValue(optionCodex, c, partenOptionCodex);
27829
28024
  }).filter(function (c) {
27830
28025
  return Object.keys(c.opv).length;
27831
28026
  });
@@ -27848,10 +28043,11 @@ var DivaArticle = /*#__PURE__*/function () {
27848
28043
  if (codexes[0] === 'EMPTY_MULTISELECT') {
27849
28044
  var firstOPV;
27850
28045
  if (ops.option.hasOPG) {
27851
- var opg = ops.option.articleOptionValues[Object.keys(ops.option.articleOptionValues)[0]];
27852
- firstOPV = opg.articleOptionValues[Object.keys(opg.articleOptionValues)[0]];
28046
+ var _opg$articleOptionVal, _opg$articleOptionVal2;
28047
+ var opg = Array.from(ops.option.articleOptionValues.values())[0];
28048
+ firstOPV = Array.from((_opg$articleOptionVal = (_opg$articleOptionVal2 = opg.articleOptionValues) === null || _opg$articleOptionVal2 === void 0 ? void 0 : _opg$articleOptionVal2.values()) !== null && _opg$articleOptionVal !== void 0 ? _opg$articleOptionVal : [])[0];
27853
28049
  } else {
27854
- firstOPV = ops.option.articleOptionValues[Object.keys(ops.option.articleOptionValues)[0]];
28050
+ firstOPV = Array.from(ops.option.articleOptionValues.values())[0];
27855
28051
  }
27856
28052
  ops.multiSelects = [firstOPV];
27857
28053
  newConfigValues[ops.option.codex] = firstOPV.codex;
@@ -27885,28 +28081,47 @@ var DivaArticle = /*#__PURE__*/function () {
27885
28081
  var _this$checkOptionAndO = this.checkOptionAndOptionValue(optionCodex, newConfigValues[key], partenOptionCodex),
27886
28082
  opv = _this$checkOptionAndO.opv;
27887
28083
  if (!Object.keys(opv).length) {
27888
- var _opv = this.findFreeTextOpv(ops);
27889
- if (_opv) newConfigValues[key] = _opv.codex;
28084
+ var _opv3 = this.findFreeTextOpv(ops);
28085
+ if (_opv3) newConfigValues[key] = _opv3.codex;
27890
28086
  }
27891
28087
  }
27892
28088
  }
27893
28089
  }, {
27894
28090
  key: "findFreeTextOpv",
27895
28091
  value: function findFreeTextOpv(ops) {
27896
- for (var key in ops.visibleOptionValues) {
27897
- var opv = ops.visibleOptionValues[key];
27898
- if (opv.isFreeText) {
27899
- return opv;
28092
+ var _iterator31 = _createForOfIteratorHelper$6(ops.visibleOptionValues),
28093
+ _step31;
28094
+ try {
28095
+ for (_iterator31.s(); !(_step31 = _iterator31.n()).done;) {
28096
+ var _step31$value = _slicedToArray__default["default"](_step31.value, 2),
28097
+ key = _step31$value[0],
28098
+ opv = _step31$value[1];
28099
+ if (opv.isFreeText) {
28100
+ return opv;
28101
+ }
27900
28102
  }
28103
+ } catch (err) {
28104
+ _iterator31.e(err);
28105
+ } finally {
28106
+ _iterator31.f();
27901
28107
  }
27902
28108
  return undefined;
27903
28109
  }
27904
28110
  }, {
27905
28111
  key: "defineAllOptions",
27906
28112
  value: function defineAllOptions() {
27907
- this.articleOptionStates.map(function (ops) {
27908
- return ops.isDefined = true;
27909
- });
28113
+ var _iterator32 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
28114
+ _step32;
28115
+ try {
28116
+ for (_iterator32.s(); !(_step32 = _iterator32.n()).done;) {
28117
+ var ops = _step32.value;
28118
+ ops.isDefined = true;
28119
+ }
28120
+ } catch (err) {
28121
+ _iterator32.e(err);
28122
+ } finally {
28123
+ _iterator32.f();
28124
+ }
27910
28125
  }
27911
28126
  }, {
27912
28127
  key: "defineOP",
@@ -27917,22 +28132,32 @@ var DivaArticle = /*#__PURE__*/function () {
27917
28132
  }, {
27918
28133
  key: "getDefaultOpv",
27919
28134
  value: function getDefaultOpv(visibleOptionValues) {
27920
- for (var iKey in visibleOptionValues) {
27921
- var opv = visibleOptionValues[iKey];
27922
- if (opv.isOPVG) {
27923
- var _opv$articleOptionVal;
27924
- var defaultOPV = Object.values((_opv$articleOptionVal = opv.articleOptionValues) !== null && _opv$articleOptionVal !== void 0 ? _opv$articleOptionVal : {}).find(function (opv) {
27925
- return opv.defaultValue;
27926
- });
27927
- if (defaultOPV) {
27928
- return defaultOPV;
28135
+ var _iterator33 = _createForOfIteratorHelper$6(visibleOptionValues),
28136
+ _step33;
28137
+ try {
28138
+ for (_iterator33.s(); !(_step33 = _iterator33.n()).done;) {
28139
+ var _step33$value = _slicedToArray__default["default"](_step33.value, 2),
28140
+ iKey = _step33$value[0],
28141
+ opv = _step33$value[1];
28142
+ if (opv.isOPVG) {
28143
+ var _opv$articleOptionVal, _opv$articleOptionVal2;
28144
+ var defaultOPV = Array.from((_opv$articleOptionVal = (_opv$articleOptionVal2 = opv.articleOptionValues) === null || _opv$articleOptionVal2 === void 0 ? void 0 : _opv$articleOptionVal2.values()) !== null && _opv$articleOptionVal !== void 0 ? _opv$articleOptionVal : []).find(function (opv) {
28145
+ return opv.defaultValue;
28146
+ });
28147
+ if (defaultOPV) {
28148
+ return defaultOPV;
28149
+ }
28150
+ }
28151
+ if (opv.defaultValue) {
28152
+ return opv;
27929
28153
  }
27930
28154
  }
27931
- if (opv.defaultValue) {
27932
- return opv;
27933
- }
28155
+ } catch (err) {
28156
+ _iterator33.e(err);
28157
+ } finally {
28158
+ _iterator33.f();
27934
28159
  }
27935
- return visibleOptionValues[Object.keys(visibleOptionValues)[0]];
28160
+ return Array.from(visibleOptionValues.values())[0];
27936
28161
  }
27937
28162
  }, {
27938
28163
  key: "getVariantValuesInfluencingOptions",
@@ -27959,7 +28184,7 @@ var DivaArticle = /*#__PURE__*/function () {
27959
28184
  var newVvs2 = this.engine.getValuesInfluencingOPT(key, vv[key]);
27960
28185
  if (newVvs2.length) {
27961
28186
  for (var j = 0; j < newVvs2.length; j++) {
27962
- newVvs[j] = _objectSpread$e(_objectSpread$e({}, vv), newVvs2[j]);
28187
+ newVvs[j] = _objectSpread$d(_objectSpread$d({}, vv), newVvs2[j]);
27963
28188
  }
27964
28189
  }
27965
28190
  }
@@ -28038,7 +28263,7 @@ var DivaArticle = /*#__PURE__*/function () {
28038
28263
  break;
28039
28264
  }
28040
28265
  _context.next = 4;
28041
- return Promise.resolve().then(function () { return require('./ShelfPlanner-33014e25.js'); });
28266
+ return Promise.resolve().then(function () { return require('./ShelfPlanner-d409ac3e.js'); });
28042
28267
  case 4:
28043
28268
  _yield$import = _context.sent;
28044
28269
  ShelfPlanner = _yield$import["default"];
@@ -28115,11 +28340,19 @@ var DivaArticle = /*#__PURE__*/function () {
28115
28340
  value: function afterInit() {
28116
28341
  if (!this.CatalogData.useDiomexConfigLogic) return {};
28117
28342
  var variantValues = {};
28118
- for (var i = 0; i < this.articleOptionStates.length; i++) {
28119
- var ops = this.articleOptionStates[i];
28120
- if (ops.val === undefined && ops.visibleOPVKeys.length && !ops.isInvisible) {
28121
- variantValues[ops.optionCodex] = ops.visibleOPVKeys[0];
28343
+ var _iterator34 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
28344
+ _step34;
28345
+ try {
28346
+ for (_iterator34.s(); !(_step34 = _iterator34.n()).done;) {
28347
+ var ops = _step34.value;
28348
+ if (ops.val === undefined && ops.visibleOPVKeys.length && !ops.isInvisible) {
28349
+ variantValues[ops.optionCodex] = ops.visibleOPVKeys[0];
28350
+ }
28122
28351
  }
28352
+ } catch (err) {
28353
+ _iterator34.e(err);
28354
+ } finally {
28355
+ _iterator34.f();
28123
28356
  }
28124
28357
  return variantValues;
28125
28358
  }
@@ -28143,30 +28376,40 @@ var DivaArticle = /*#__PURE__*/function () {
28143
28376
  for (var _key in myValues) {
28144
28377
  var ops = this.getArticleOptionState(_key);
28145
28378
  if (!ops) continue;
28146
- var opv = ops === null || ops === void 0 ? void 0 : ops.visibleOptionValues[myValues[_key]];
28379
+ var opv = ops === null || ops === void 0 ? void 0 : ops.visibleOptionValues.get(myValues[_key]);
28147
28380
  if (opv) {
28148
28381
  var value = opv.setConfig;
28149
28382
  if (value) {
28150
28383
  for (var _i4 = 0; _i4 < value.split(';').length; _i4++) {
28151
28384
  var opt = (!this.CatalogData.isIDMFormat ? 'OPT' : '') + value.split(';')[_i4].split(':')[0];
28152
- var _opv2 = (!this.CatalogData.isIDMFormat ? 'OPV' : '') + value.split(';')[_i4].split(':')[1];
28385
+ var _opv4 = (!this.CatalogData.isIDMFormat ? 'OPV' : '') + value.split(';')[_i4].split(':')[1];
28153
28386
  if (!myValues[opt] || setConfigDoesOverWrite) {
28154
- myValues[opt] = _opv2;
28387
+ myValues[opt] = _opv4;
28155
28388
  }
28156
28389
  }
28157
28390
  }
28158
28391
  }
28159
- var catalogopv = ops.option.articleOptionValues[myValues[_key]];
28392
+ var catalogopv = ops.option.articleOptionValues.get(myValues[_key]);
28160
28393
  if (catalogopv !== null && catalogopv !== void 0 && catalogopv.sameopv) {
28161
28394
  var opvs = ops.option.articleOptionValues;
28162
- for (var opvKey in opvs) {
28163
- var checkingOpv = opvs[opvKey];
28164
- if (opvKey === catalogopv.codex) continue;
28165
- if (checkingOpv !== null && checkingOpv !== void 0 && checkingOpv.sameopv && catalogopv.sameopv == checkingOpv.sameopv) {
28166
- if (!ops.visibleOptionValues[catalogopv.codex] && ops.visibleOptionValues[checkingOpv.codex]) {
28167
- myValues[_key] = checkingOpv.codex;
28395
+ var _iterator35 = _createForOfIteratorHelper$6(opvs),
28396
+ _step35;
28397
+ try {
28398
+ for (_iterator35.s(); !(_step35 = _iterator35.n()).done;) {
28399
+ var _step35$value = _slicedToArray__default["default"](_step35.value, 2),
28400
+ opvKey = _step35$value[0],
28401
+ checkingOpv = _step35$value[1];
28402
+ if (opvKey === catalogopv.codex) continue;
28403
+ if (checkingOpv !== null && checkingOpv !== void 0 && checkingOpv.sameopv && catalogopv.sameopv == checkingOpv.sameopv) {
28404
+ if (!ops.visibleOptionValues.get(catalogopv.codex) && ops.visibleOptionValues.get(checkingOpv.codex)) {
28405
+ myValues[_key] = checkingOpv.codex;
28406
+ }
28168
28407
  }
28169
28408
  }
28409
+ } catch (err) {
28410
+ _iterator35.e(err);
28411
+ } finally {
28412
+ _iterator35.f();
28170
28413
  }
28171
28414
  }
28172
28415
  }
@@ -28177,20 +28420,20 @@ var DivaArticle = /*#__PURE__*/function () {
28177
28420
  } else if (_key2.endsWith('_val') && this.getArticleOptionState(_key2.replace(/_val/g, ''))) {
28178
28421
  validValues[_key2] = myValues[_key2];
28179
28422
  } else {
28180
- var _iterator25 = _createForOfIteratorHelper$6(this.articleOptionStates),
28181
- _step25;
28423
+ var _iterator36 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
28424
+ _step36;
28182
28425
  try {
28183
- for (_iterator25.s(); !(_step25 = _iterator25.n()).done;) {
28184
- var _ops7 = _step25.value;
28426
+ for (_iterator36.s(); !(_step36 = _iterator36.n()).done;) {
28427
+ var _ops7 = _step36.value;
28185
28428
  if (_ops7.optionOcd == _key2) {
28186
28429
  var values = this.checkOptionSearchOPV(_ops7.option, myValues[_key2], {});
28187
28430
  if (values !== null && values !== void 0 && values.opv) validValues[_ops7.optionCodex] = values.opv.codex;
28188
28431
  }
28189
28432
  }
28190
28433
  } catch (err) {
28191
- _iterator25.e(err);
28434
+ _iterator36.e(err);
28192
28435
  } finally {
28193
- _iterator25.f();
28436
+ _iterator36.f();
28194
28437
  }
28195
28438
  }
28196
28439
  //for classification usecase when suboption and option have the same name like OPTOPT_MATERIAL_1_00 and OPTOPT_MATERIAL_1_00.OPTOPT_MATERIAL_1_00
@@ -28254,17 +28497,17 @@ var DivaArticle = /*#__PURE__*/function () {
28254
28497
  key: "addOptionStateFromArticleToPlannerData",
28255
28498
  value: function addOptionStateFromArticleToPlannerData(ret, alternateRenderInfo) {
28256
28499
  var articleOptions = this.getArticleOptionStatesWithOptionsForPrint();
28257
- var _iterator26 = _createForOfIteratorHelper$6(articleOptions),
28258
- _step26;
28500
+ var _iterator37 = _createForOfIteratorHelper$6(articleOptions.values()),
28501
+ _step37;
28259
28502
  try {
28260
- for (_iterator26.s(); !(_step26 = _iterator26.n()).done;) {
28261
- var ops = _step26.value;
28503
+ for (_iterator37.s(); !(_step37 = _iterator37.n()).done;) {
28504
+ var ops = _step37.value;
28262
28505
  this.addOptionStateToPlannerData(ret, ops, alternateRenderInfo);
28263
28506
  }
28264
28507
  } catch (err) {
28265
- _iterator26.e(err);
28508
+ _iterator37.e(err);
28266
28509
  } finally {
28267
- _iterator26.f();
28510
+ _iterator37.f();
28268
28511
  }
28269
28512
  for (var key in this.article.partlistArticles) {
28270
28513
  var partlistArticle = this.article.partlistArticles[key];
@@ -28316,11 +28559,11 @@ var DivaArticle = /*#__PURE__*/function () {
28316
28559
  key: "getAccessoireMATData",
28317
28560
  value: function getAccessoireMATData(onString) {
28318
28561
  var MAT = [];
28319
- var _iterator27 = _createForOfIteratorHelper$6(this.articleOptionStates),
28320
- _step27;
28562
+ var _iterator38 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
28563
+ _step38;
28321
28564
  try {
28322
- for (_iterator27.s(); !(_step27 = _iterator27.n()).done;) {
28323
- var ops = _step27.value;
28565
+ for (_iterator38.s(); !(_step38 = _iterator38.n()).done;) {
28566
+ var ops = _step38.value;
28324
28567
  var opt = void 0;
28325
28568
  if (!ops.val) continue;
28326
28569
  opt = ops.optionCodex;
@@ -28333,9 +28576,9 @@ var DivaArticle = /*#__PURE__*/function () {
28333
28576
  });
28334
28577
  }
28335
28578
  } catch (err) {
28336
- _iterator27.e(err);
28579
+ _iterator38.e(err);
28337
28580
  } finally {
28338
- _iterator27.f();
28581
+ _iterator38.f();
28339
28582
  }
28340
28583
  return MAT;
28341
28584
  }
@@ -28377,11 +28620,11 @@ var DivaArticle = /*#__PURE__*/function () {
28377
28620
  value: function getVariantBasketData() {
28378
28621
  var variantBasketData = [];
28379
28622
  var articleOptions = this.getArticleOptionStatesWithOptionsForPrint();
28380
- var _iterator28 = _createForOfIteratorHelper$6(articleOptions),
28381
- _step28;
28623
+ var _iterator39 = _createForOfIteratorHelper$6(articleOptions.values()),
28624
+ _step39;
28382
28625
  try {
28383
- for (_iterator28.s(); !(_step28 = _iterator28.n()).done;) {
28384
- var ops = _step28.value;
28626
+ for (_iterator39.s(); !(_step39 = _iterator39.n()).done;) {
28627
+ var ops = _step39.value;
28385
28628
  var OP = ops.optionCodex;
28386
28629
  if (ops) {
28387
28630
  var _ops$idmVariantenArt2;
@@ -28448,9 +28691,9 @@ var DivaArticle = /*#__PURE__*/function () {
28448
28691
  }
28449
28692
  }
28450
28693
  } catch (err) {
28451
- _iterator28.e(err);
28694
+ _iterator39.e(err);
28452
28695
  } finally {
28453
- _iterator28.f();
28696
+ _iterator39.f();
28454
28697
  }
28455
28698
  return variantBasketData;
28456
28699
  }
@@ -28619,19 +28862,19 @@ var DivaArticle = /*#__PURE__*/function () {
28619
28862
  }, {
28620
28863
  key: "cloneArticle",
28621
28864
  value: function cloneArticle(set) {
28622
- var clonedArticle = new DivaArticle(set, this.basketId, _objectSpread$e({}, this.article), this.article.catalogArticle, set.CatalogData);
28623
- clonedArticle.articleOptionStatesData = [];
28624
- var _iterator29 = _createForOfIteratorHelper$6(this.articleOptionStates),
28625
- _step29;
28865
+ var clonedArticle = new DivaArticle(set, this.basketId, _objectSpread$d({}, this.article), this.article.catalogArticle, set.CatalogData);
28866
+ clonedArticle.articleOptionStatesData = new Map();
28867
+ var _iterator40 = _createForOfIteratorHelper$6(this.articleOptionStates.values()),
28868
+ _step40;
28626
28869
  try {
28627
- for (_iterator29.s(); !(_step29 = _iterator29.n()).done;) {
28628
- var ops = _step29.value;
28629
- clonedArticle.articleOptionStatesData.push(ops.cloneOptionState(clonedArticle.getIsConfigSingle));
28870
+ for (_iterator40.s(); !(_step40 = _iterator40.n()).done;) {
28871
+ var ops = _step40.value;
28872
+ clonedArticle.articleOptionStatesData.set(ops.optionCodex, ops.cloneOptionState(clonedArticle.getIsConfigSingle));
28630
28873
  }
28631
28874
  } catch (err) {
28632
- _iterator29.e(err);
28875
+ _iterator40.e(err);
28633
28876
  } finally {
28634
- _iterator29.f();
28877
+ _iterator40.f();
28635
28878
  }
28636
28879
  clonedArticle.initEngine();
28637
28880
  clonedArticle.article.partlistArticles = {};
@@ -28647,8 +28890,8 @@ var DivaArticle = /*#__PURE__*/function () {
28647
28890
  function _createForOfIteratorHelper$5(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$5(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
28648
28891
  function _unsupportedIterableToArray$5(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$5(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$5(r, a) : void 0; } }
28649
28892
  function _arrayLikeToArray$5(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
28650
- function ownKeys$d(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; }
28651
- function _objectSpread$d(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$d(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$d(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
28893
+ function ownKeys$c(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; }
28894
+ function _objectSpread$c(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$c(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$c(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
28652
28895
  var LOG$d = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
28653
28896
 
28654
28897
  //Diese Klasse verwaltet den Optionsbaum und ladelogik etc. eines Artikels
@@ -28667,7 +28910,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
28667
28910
  while (1) switch (_context.prev = _context.next) {
28668
28911
  case 0:
28669
28912
  _context.next = 2;
28670
- return this.preLoadArticles(set, [_objectSpread$d(_objectSpread$d({}, initParams), {}, {
28913
+ return this.preLoadArticles(set, [_objectSpread$c(_objectSpread$c({}, initParams), {}, {
28671
28914
  articleCodex: articleCodex
28672
28915
  })]);
28673
28916
  case 2:
@@ -28927,7 +29170,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
28927
29170
  return _context6.abrupt("continue", 37);
28928
29171
  case 12:
28929
29172
  if (targetArticlesWithNewValues.includes(targetArticlesToUpdate[i])) {
28930
- valuesArray[i] = actArticle.getValidValues(_objectSpread$d({}, myValues), actArticle.CatalogData.mergeOptionsToSameOption);
29173
+ valuesArray[i] = actArticle.getValidValues(_objectSpread$c({}, myValues), actArticle.CatalogData.mergeOptionsToSameOption);
28931
29174
  }
28932
29175
 
28933
29176
  //only set config if valuesArray are not empty or the article is initializing
@@ -29131,7 +29374,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29131
29374
  for (var key in articles) {
29132
29375
  var checkArticle = articles[key];
29133
29376
  //und jetzt in allen Optionsbäumen nach GroupedUsedOPVs suchen
29134
- var _iterator = _createForOfIteratorHelper$5(checkArticle.articleOptionStates),
29377
+ var _iterator = _createForOfIteratorHelper$5(checkArticle.articleOptionStates.values()),
29135
29378
  _step;
29136
29379
  try {
29137
29380
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -29180,7 +29423,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29180
29423
  for (var i = keys.length - 1; i >= 0; i--) {
29181
29424
  var article = articles[keys[i]];
29182
29425
  if (article.hasArticleOptionStates) {
29183
- var _iterator2 = _createForOfIteratorHelper$5(article.articleOptionStates),
29426
+ var _iterator2 = _createForOfIteratorHelper$5(article.articleOptionStates.values()),
29184
29427
  _step2;
29185
29428
  try {
29186
29429
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
@@ -29209,50 +29452,24 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29209
29452
  var _initCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee9(article, variantValues,
29210
29453
  // Werte aus einem Basiskonfigurat,
29211
29454
  variantItems) {
29212
- var myCatalogArticleOptions, _loop2, i, attr, foundItem, _foundItem$opt, freeText, opss, _i, ops, opv, _iterator3, _step3, _ops, value, optionValueCodex, _i2, variantItem, possibleValues, j, possibleValue, _i3, _variantItem, val;
29213
- return _regeneratorRuntime__default["default"].wrap(function _callee9$(_context11) {
29214
- while (1) switch (_context11.prev = _context11.next) {
29455
+ var myCatalogArticleOptions, i, _article$set$ViewConf, attr, foundItem, _foundItem$opt, freeText, opss, _i, ops, opv, _iterator3, _step3, _ops, value, optionValueCodex, _i2, variantItem, possibleValues, j, possibleValue, _i3, _variantItem, val;
29456
+ return _regeneratorRuntime__default["default"].wrap(function _callee9$(_context10) {
29457
+ while (1) switch (_context10.prev = _context10.next) {
29215
29458
  case 0:
29216
29459
  myCatalogArticleOptions = Object.values(article.catalogArticleOptions).sort(function (a, b) {
29217
29460
  var _a$sequenceNo, _b$sequenceNo;
29218
29461
  return ((_a$sequenceNo = a.sequenceNo) !== null && _a$sequenceNo !== void 0 ? _a$sequenceNo : 0) - ((_b$sequenceNo = b.sequenceNo) !== null && _b$sequenceNo !== void 0 ? _b$sequenceNo : 0);
29219
29462
  });
29220
- if (!myCatalogArticleOptions) {
29221
- _context11.next = 9;
29222
- break;
29223
- }
29224
- _loop2 = /*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _loop2(i) {
29225
- var _article$set$ViewConf, optionState;
29226
- return _regeneratorRuntime__default["default"].wrap(function _loop2$(_context10) {
29227
- while (1) switch (_context10.prev = _context10.next) {
29228
- case 0:
29229
- //Hier wird mal geschaut, ob der aktuelle Artikel alle Optionen schon initialisiert hat.
29230
- if (!article.articleOptionStates.find(function (ops) {
29231
- return ops.optionCodex == myCatalogArticleOptions[i].codex;
29232
- })) {
29233
- optionState = new ArticleOptionStateData(myCatalogArticleOptions[i], article.getIsConfigSingle, undefined, (_article$set$ViewConf = article.set.ViewConfig) === null || _article$set$ViewConf === void 0 ? void 0 : _article$set$ViewConf.useIsOptionDefinedWarning);
29234
- article.uploadOptionState(optionState); //alle Optionen erstellen
29235
- }
29236
- case 1:
29237
- case "end":
29238
- return _context10.stop();
29463
+ if (myCatalogArticleOptions) {
29464
+ for (i = 0; i < myCatalogArticleOptions.length; i++) {
29465
+ //Hier wird mal geschaut, ob der aktuelle Artikel alle Optionen schon initialisiert hat.
29466
+ if (!article.articleOptionStates.has(myCatalogArticleOptions[i].codex)) {
29467
+ article.uploadOptionState(new ArticleOptionStateData(myCatalogArticleOptions[i], article.getIsConfigSingle, undefined, (_article$set$ViewConf = article.set.ViewConfig) === null || _article$set$ViewConf === void 0 ? void 0 : _article$set$ViewConf.useIsOptionDefinedWarning)); //alle Optionen erstellen
29239
29468
  }
29240
- }, _loop2);
29241
- });
29242
- i = 0;
29243
- case 4:
29244
- if (!(i < myCatalogArticleOptions.length)) {
29245
- _context11.next = 9;
29246
- break;
29469
+ }
29247
29470
  }
29248
- return _context11.delegateYield(_loop2(i), "t0", 6);
29249
- case 6:
29250
- i++;
29251
- _context11.next = 4;
29252
- break;
29253
- case 9:
29254
- if (!article.articleOptionStates.length) {
29255
- _context11.next = 33;
29471
+ if (!article.articleOptionStates.size) {
29472
+ _context10.next = 26;
29256
29473
  break;
29257
29474
  }
29258
29475
  //infos eines Basisconfigurats initialisieren
@@ -29281,23 +29498,23 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29281
29498
  }
29282
29499
 
29283
29500
  //defaultValues for FreeText
29284
- _iterator3 = _createForOfIteratorHelper$5(article.articleOptionStates);
29285
- _context11.prev = 12;
29501
+ _iterator3 = _createForOfIteratorHelper$5(article.articleOptionStates.values());
29502
+ _context10.prev = 5;
29286
29503
  _iterator3.s();
29287
- case 14:
29504
+ case 7:
29288
29505
  if ((_step3 = _iterator3.n()).done) {
29289
- _context11.next = 25;
29506
+ _context10.next = 18;
29290
29507
  break;
29291
29508
  }
29292
29509
  _ops = _step3.value;
29293
29510
  if (!variantValues[_ops.optionCodex + '_val']) {
29294
- _context11.next = 18;
29511
+ _context10.next = 11;
29295
29512
  break;
29296
29513
  }
29297
- return _context11.abrupt("continue", 23);
29298
- case 18:
29514
+ return _context10.abrupt("continue", 16);
29515
+ case 11:
29299
29516
  value = undefined;
29300
- optionValueCodex = Object.keys(_ops.option.articleOptionValues)[0];
29517
+ optionValueCodex = Array.from(_ops.option.articleOptionValues.values())[0].codex;
29301
29518
  if (variantItems && _ops.isFreeText && _ops.measureUnit) {
29302
29519
  for (_i2 = 0; _i2 < variantItems.length && value == undefined; _i2++) {
29303
29520
  variantItem = variantItems[_i2];
@@ -29334,28 +29551,28 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29334
29551
  _ops.freeText = val;
29335
29552
  }
29336
29553
  }
29337
- if (value != undefined) article.engine.setOP(_ops.option.codex, _ops.option.articleOptionValues[optionValueCodex], value, true);
29338
- case 23:
29339
- _context11.next = 14;
29554
+ if (value != undefined) article.engine.setOP(_ops.option.codex, _ops.option.articleOptionValues.get(optionValueCodex), value, true);
29555
+ case 16:
29556
+ _context10.next = 7;
29340
29557
  break;
29341
- case 25:
29342
- _context11.next = 30;
29558
+ case 18:
29559
+ _context10.next = 23;
29343
29560
  break;
29344
- case 27:
29345
- _context11.prev = 27;
29346
- _context11.t1 = _context11["catch"](12);
29347
- _iterator3.e(_context11.t1);
29348
- case 30:
29349
- _context11.prev = 30;
29561
+ case 20:
29562
+ _context10.prev = 20;
29563
+ _context10.t0 = _context10["catch"](5);
29564
+ _iterator3.e(_context10.t0);
29565
+ case 23:
29566
+ _context10.prev = 23;
29350
29567
  _iterator3.f();
29351
- return _context11.finish(30);
29352
- case 33:
29568
+ return _context10.finish(23);
29569
+ case 26:
29353
29570
  if (article.plannerData) article.plannerData.varaintValuesInfluencingAVLAVRFilter = article.getVariantValuesInfluencingOptions([(!article.CatalogData.isIDMFormat ? 'OPT' : '') + '89', (!article.CatalogData.isIDMFormat ? 'OPT' : '') + '90']);
29354
- case 34:
29571
+ case 27:
29355
29572
  case "end":
29356
- return _context11.stop();
29573
+ return _context10.stop();
29357
29574
  }
29358
- }, _callee9, null, [[12, 27, 30, 33]]);
29575
+ }, _callee9, null, [[5, 20, 23, 26]]);
29359
29576
  }));
29360
29577
  function initCfgValues(_x24, _x25, _x26) {
29361
29578
  return _initCfgValues.apply(this, arguments);
@@ -29377,8 +29594,8 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29377
29594
  value: (function () {
29378
29595
  var _updateCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee10(article, newConfigValues, alreadyInitializedValues, dontCalcPrice, dontLoadPartlist, calcVariantPrice, onlyUpdateOnce) {
29379
29596
  var maxPriceOfGroupCodex, setByFeatureVariantValues, key, partlistArticlesToLoad;
29380
- return _regeneratorRuntime__default["default"].wrap(function _callee10$(_context12) {
29381
- while (1) switch (_context12.prev = _context12.next) {
29597
+ return _regeneratorRuntime__default["default"].wrap(function _callee10$(_context11) {
29598
+ while (1) switch (_context11.prev = _context11.next) {
29382
29599
  case 0:
29383
29600
  if (!!article.CatalogData.bundleRules) dontLoadPartlist = true;
29384
29601
  //es wird versucht die neuen Optionswerte zu setzten
@@ -29404,24 +29621,24 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29404
29621
  article.engine.evalDecisions(onlyUpdateOnce);
29405
29622
  }
29406
29623
  if (calcVariantPrice) {
29407
- _context12.next = 9;
29624
+ _context11.next = 9;
29408
29625
  break;
29409
29626
  }
29410
- _context12.next = 9;
29627
+ _context11.next = 9;
29411
29628
  return article.updateShelfPlannerState(newConfigValues);
29412
29629
  case 9:
29413
29630
  if (!(!dontCalcPrice && !calcVariantPrice)) {
29414
- _context12.next = 12;
29631
+ _context11.next = 12;
29415
29632
  break;
29416
29633
  }
29417
- _context12.next = 12;
29634
+ _context11.next = 12;
29418
29635
  return this.updateLastElement(article);
29419
29636
  case 12:
29420
- _context12.next = 14;
29637
+ _context11.next = 14;
29421
29638
  return this.evalAndLoadPartlistArticles(article, dontLoadPartlist, newConfigValues);
29422
29639
  case 14:
29423
- partlistArticlesToLoad = _context12.sent;
29424
- _context12.next = 17;
29640
+ partlistArticlesToLoad = _context11.sent;
29641
+ _context11.next = 17;
29425
29642
  return this.evalOpvsOnOpvsConstructionRules(article);
29426
29643
  case 17:
29427
29644
  //danach Preise berechnen
@@ -29432,10 +29649,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29432
29649
  article.engine.updateConfigDependentMedia();
29433
29650
  }
29434
29651
  }
29435
- return _context12.abrupt("return", partlistArticlesToLoad);
29652
+ return _context11.abrupt("return", partlistArticlesToLoad);
29436
29653
  case 19:
29437
29654
  case "end":
29438
- return _context12.stop();
29655
+ return _context11.stop();
29439
29656
  }
29440
29657
  }, _callee10, this);
29441
29658
  }));
@@ -29449,17 +29666,17 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29449
29666
  value: function () {
29450
29667
  var _updateLastElement = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee11(article) {
29451
29668
  var isIDM, opsLastElement, lastElement, opsLastPlannedAccessoire, opsFirstAccessoire, _article$accessoirePa, _article$accessoirePa2, accessoires, i;
29452
- return _regeneratorRuntime__default["default"].wrap(function _callee11$(_context13) {
29453
- while (1) switch (_context13.prev = _context13.next) {
29669
+ return _regeneratorRuntime__default["default"].wrap(function _callee11$(_context12) {
29670
+ while (1) switch (_context12.prev = _context12.next) {
29454
29671
  case 0:
29455
29672
  isIDM = article.CatalogData.isIDMFormat;
29456
29673
  opsLastElement = article.getArticleOptionState((!isIDM ? 'OPT' : '') + 'ELEMENTPOSITION');
29457
29674
  if (opsLastElement) {
29458
29675
  lastElement = setHandlerInstance.getLastElementInGroup(article);
29459
29676
  if (lastElement && lastElement.elementId == article.elementId) {
29460
- opsLastElement.val = opsLastElement.visibleOptionValues[(!isIDM ? 'OPV' : '') + 'LASTELEMENT'];
29677
+ opsLastElement.val = opsLastElement.visibleOptionValues.get((!isIDM ? 'OPV' : '') + 'LASTELEMENT');
29461
29678
  } else {
29462
- opsLastElement.val = opsLastElement.visibleOptionValues[(!isIDM ? 'OPV' : '') + 'NOTLASTELEMENT'];
29679
+ opsLastElement.val = opsLastElement.visibleOptionValues.get((!isIDM ? 'OPV' : '') + 'NOTLASTELEMENT');
29463
29680
  }
29464
29681
  }
29465
29682
  opsLastPlannedAccessoire = article.getArticleOptionState((!isIDM ? 'OPT' : '') + 'LASTSTACKEDARTICLE');
@@ -29467,32 +29684,32 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29467
29684
  if (Object.values(article.accessoires).find(function (accessoire) {
29468
29685
  return accessoire.hasCatalogPlannerArticle;
29469
29686
  })) {
29470
- opsLastPlannedAccessoire.val = opsLastPlannedAccessoire.visibleOptionValues[(!isIDM ? 'OPV' : '') + 'NOTLASTSTACKEDARTICLE'];
29687
+ opsLastPlannedAccessoire.val = opsLastPlannedAccessoire.visibleOptionValues.get((!isIDM ? 'OPV' : '') + 'NOTLASTSTACKEDARTICLE');
29471
29688
  } else {
29472
- opsLastPlannedAccessoire.val = opsLastPlannedAccessoire.visibleOptionValues[(!isIDM ? 'OPV' : '') + 'LASTSTACKEDARTICLE'];
29689
+ opsLastPlannedAccessoire.val = opsLastPlannedAccessoire.visibleOptionValues.get((!isIDM ? 'OPV' : '') + 'LASTSTACKEDARTICLE');
29473
29690
  }
29474
29691
  }
29475
29692
  opsFirstAccessoire = article.getArticleOptionState((!isIDM ? 'OPT' : '') + 'FIRSTACCESSOIRE');
29476
29693
  if (!opsFirstAccessoire) {
29477
- _context13.next = 15;
29694
+ _context12.next = 15;
29478
29695
  break;
29479
29696
  }
29480
29697
  accessoires = (_article$accessoirePa = (_article$accessoirePa2 = article.accessoireParentArticle) === null || _article$accessoirePa2 === void 0 ? void 0 : _article$accessoirePa2.getAccessoireByArticleCodex(article.articleCodex)) !== null && _article$accessoirePa !== void 0 ? _article$accessoirePa : [];
29481
29698
  i = 0;
29482
29699
  case 9:
29483
29700
  if (!(i < accessoires.length)) {
29484
- _context13.next = 15;
29701
+ _context12.next = 15;
29485
29702
  break;
29486
29703
  }
29487
- _context13.next = 12;
29704
+ _context12.next = 12;
29488
29705
  return this.updateOption(accessoires[i], (!isIDM ? 'OPT' : '') + 'FIRSTACCESSOIRE', (!isIDM ? 'OPV' : '') + (i + 1).toString(), i === 0 ? (!isIDM ? 'OPV' : '') + 'FIRSTACCESSOIRE' : (!isIDM ? 'OPV' : '') + 'NOTFIRSTACCESSOIRE');
29489
29706
  case 12:
29490
29707
  i++;
29491
- _context13.next = 9;
29708
+ _context12.next = 9;
29492
29709
  break;
29493
29710
  case 15:
29494
29711
  case "end":
29495
- return _context13.stop();
29712
+ return _context12.stop();
29496
29713
  }
29497
29714
  }, _callee11, this);
29498
29715
  }));
@@ -29507,34 +29724,34 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29507
29724
  var _updateOption = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee12(article, optionCodex, newCodex, fallbackNewCodex) {
29508
29725
  var _ops$val, _ops$visibleOptionVal;
29509
29726
  var ops, oldCodex, newVal;
29510
- return _regeneratorRuntime__default["default"].wrap(function _callee12$(_context14) {
29511
- while (1) switch (_context14.prev = _context14.next) {
29727
+ return _regeneratorRuntime__default["default"].wrap(function _callee12$(_context13) {
29728
+ while (1) switch (_context13.prev = _context13.next) {
29512
29729
  case 0:
29513
29730
  ops = article.getArticleOptionState(optionCodex);
29514
29731
  if (ops) {
29515
- _context14.next = 3;
29732
+ _context13.next = 3;
29516
29733
  break;
29517
29734
  }
29518
- return _context14.abrupt("return");
29735
+ return _context13.abrupt("return");
29519
29736
  case 3:
29520
29737
  oldCodex = (_ops$val = ops.val) === null || _ops$val === void 0 ? void 0 : _ops$val.codex;
29521
- newVal = (_ops$visibleOptionVal = ops.visibleOptionValues[newCodex]) !== null && _ops$visibleOptionVal !== void 0 ? _ops$visibleOptionVal : fallbackNewCodex ? ops.visibleOptionValues[fallbackNewCodex] : undefined;
29738
+ newVal = (_ops$visibleOptionVal = ops.visibleOptionValues.get(newCodex)) !== null && _ops$visibleOptionVal !== void 0 ? _ops$visibleOptionVal : fallbackNewCodex ? ops.visibleOptionValues.get(fallbackNewCodex) : undefined;
29522
29739
  if (!(oldCodex === (newVal === null || newVal === void 0 ? void 0 : newVal.codex))) {
29523
- _context14.next = 7;
29740
+ _context13.next = 7;
29524
29741
  break;
29525
29742
  }
29526
- return _context14.abrupt("return");
29743
+ return _context13.abrupt("return");
29527
29744
  case 7:
29528
29745
  if (!newVal) {
29529
- _context14.next = 11;
29746
+ _context13.next = 11;
29530
29747
  break;
29531
29748
  }
29532
29749
  ops.val = newVal;
29533
- _context14.next = 11;
29750
+ _context13.next = 11;
29534
29751
  return setHandlerInstance.updateArticlesOptionStatesOfActSet(article.set, {}, []);
29535
29752
  case 11:
29536
29753
  case "end":
29537
- return _context14.stop();
29754
+ return _context13.stop();
29538
29755
  }
29539
29756
  }, _callee12);
29540
29757
  }));
@@ -29550,12 +29767,12 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29550
29767
  value: (function () {
29551
29768
  var _evalAndLoadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee13(article, dontLoadPartlist, newConfigValues) {
29552
29769
  var partlistArticlesToLoad;
29553
- return _regeneratorRuntime__default["default"].wrap(function _callee13$(_context15) {
29554
- while (1) switch (_context15.prev = _context15.next) {
29770
+ return _regeneratorRuntime__default["default"].wrap(function _callee13$(_context14) {
29771
+ while (1) switch (_context14.prev = _context14.next) {
29555
29772
  case 0:
29556
29773
  partlistArticlesToLoad = [];
29557
29774
  if (!article.hasPartlistArticle) {
29558
- _context15.next = 9;
29775
+ _context14.next = 9;
29559
29776
  break;
29560
29777
  }
29561
29778
  article.deletePartlistArticles(); //alle aktellen PartlistArticles des Articles löschen!
@@ -29565,10 +29782,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29565
29782
  return ((_a$sequenceNo2 = a.sequenceNo) !== null && _a$sequenceNo2 !== void 0 ? _a$sequenceNo2 : 0) - ((_b$sequenceNo2 = b.sequenceNo) !== null && _b$sequenceNo2 !== void 0 ? _b$sequenceNo2 : 0);
29566
29783
  });
29567
29784
  if (dontLoadPartlist) {
29568
- _context15.next = 9;
29785
+ _context14.next = 9;
29569
29786
  break;
29570
29787
  }
29571
- _context15.next = 8;
29788
+ _context14.next = 8;
29572
29789
  return this.loadPartlistArticles(partlistArticlesToLoad, article, article.VariantValues);
29573
29790
  case 8:
29574
29791
  partlistArticlesToLoad = [];
@@ -29577,10 +29794,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29577
29794
  partlistArticlesToLoad = this.bundlePartlistArticles(partlistArticlesToLoad, article.bundleRules, _defineProperty__default["default"]({}, article.basketId, article));
29578
29795
  }
29579
29796
  article.hasPartlistArticleInitialized = true;
29580
- return _context15.abrupt("return", partlistArticlesToLoad);
29797
+ return _context14.abrupt("return", partlistArticlesToLoad);
29581
29798
  case 12:
29582
29799
  case "end":
29583
- return _context15.stop();
29800
+ return _context14.stop();
29584
29801
  }
29585
29802
  }, _callee13, this);
29586
29803
  }));
@@ -29595,10 +29812,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29595
29812
  var _loadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee14(partlistArticlesToLoad, article, newConfigValues) {
29596
29813
  var _this = this;
29597
29814
  var i;
29598
- return _regeneratorRuntime__default["default"].wrap(function _callee14$(_context16) {
29599
- while (1) switch (_context16.prev = _context16.next) {
29815
+ return _regeneratorRuntime__default["default"].wrap(function _callee14$(_context15) {
29816
+ while (1) switch (_context15.prev = _context15.next) {
29600
29817
  case 0:
29601
- _context16.next = 2;
29818
+ _context15.next = 2;
29602
29819
  return this.preLoadArticles(article.set, partlistArticlesToLoad.map(function (p) {
29603
29820
  return _this.partlistArticleInitData(article, p);
29604
29821
  }));
@@ -29606,20 +29823,20 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29606
29823
  i = 0;
29607
29824
  case 3:
29608
29825
  if (!(i < partlistArticlesToLoad.length)) {
29609
- _context16.next = 9;
29826
+ _context15.next = 9;
29610
29827
  break;
29611
29828
  }
29612
- _context16.next = 6;
29829
+ _context15.next = 6;
29613
29830
  return this.loadPartlistArticle(partlistArticlesToLoad[i], article, newConfigValues);
29614
29831
  case 6:
29615
29832
  i++;
29616
- _context16.next = 3;
29833
+ _context15.next = 3;
29617
29834
  break;
29618
29835
  case 9:
29619
29836
  article.sortPartlistArticles(partlistArticlesToLoad);
29620
29837
  case 10:
29621
29838
  case "end":
29622
- return _context16.stop();
29839
+ return _context15.stop();
29623
29840
  }
29624
29841
  }, _callee14, this);
29625
29842
  }));
@@ -29634,25 +29851,25 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29634
29851
  value: function () {
29635
29852
  var _loadPartlistArticle = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee15(doLoadItem, article, newConfigValues) {
29636
29853
  var nArticle, _doLoadItem$VariantVa;
29637
- return _regeneratorRuntime__default["default"].wrap(function _callee15$(_context17) {
29638
- while (1) switch (_context17.prev = _context17.next) {
29854
+ return _regeneratorRuntime__default["default"].wrap(function _callee15$(_context16) {
29855
+ while (1) switch (_context16.prev = _context16.next) {
29639
29856
  case 0:
29640
- _context17.next = 2;
29857
+ _context16.next = 2;
29641
29858
  return this.loadArticle(article.set, doLoadItem.ArticleCodex, this.partlistArticleInitData(article, doLoadItem));
29642
29859
  case 2:
29643
- nArticle = _context17.sent;
29860
+ nArticle = _context16.sent;
29644
29861
  if (!nArticle) {
29645
- _context17.next = 8;
29862
+ _context16.next = 8;
29646
29863
  break;
29647
29864
  }
29648
29865
  doLoadItem.BasketID = nArticle.basketId;
29649
- _context17.next = 7;
29866
+ _context16.next = 7;
29650
29867
  return this.toDoAfterArticleLoaded(nArticle, {}, nArticle.variantValuesForPla(nArticle.partlistArticleStandalone, (_doLoadItem$VariantVa = doLoadItem.VariantValues) !== null && _doLoadItem$VariantVa !== void 0 ? _doLoadItem$VariantVa : {}, newConfigValues !== null && newConfigValues !== void 0 ? newConfigValues : {}), 'initializingPartlist', doLoadItem.VariantItemData);
29651
29868
  case 7:
29652
29869
  article.addPartlistArticle(nArticle);
29653
29870
  case 8:
29654
29871
  case "end":
29655
- return _context17.stop();
29872
+ return _context16.stop();
29656
29873
  }
29657
29874
  }, _callee15, this);
29658
29875
  }));
@@ -29698,9 +29915,9 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29698
29915
  value: (function () {
29699
29916
  var _evalOpvsOnOpvsConstructionRules = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee16(article) {
29700
29917
  var _article$CatalogData$;
29701
- var somethingChanged, previousRules, _key, actRules, item, _iterator4, _step4, ops, myOPVs, key2, opv, opvGroupName, _article$catalogArtic, _article$catalogArtic2, disable, onOpv, onOpvArr, invaliOPVs, invalidOPVArr, j, opvRule, ops2, i, invalidOpv, ops3, key, constructionRule, notifications, _i4, _item;
29702
- return _regeneratorRuntime__default["default"].wrap(function _callee16$(_context18) {
29703
- while (1) switch (_context18.prev = _context18.next) {
29918
+ var somethingChanged, previousRules, _key, actRules, item, _iterator4, _step4, ops, myOPVs, _iterator5, _step5, _step5$value, key2, opv, opvGroupName, _article$catalogArtic, _article$catalogArtic2, disable, onOpv, onOpvArr, invaliOPVs, invalidOPVArr, j, opvRule, ops2, i, invalidOpv, ops3, key, constructionRule, notifications, _i4, _item;
29919
+ return _regeneratorRuntime__default["default"].wrap(function _callee16$(_context17) {
29920
+ while (1) switch (_context17.prev = _context17.next) {
29704
29921
  case 0:
29705
29922
  somethingChanged = false;
29706
29923
  previousRules = {};
@@ -29719,52 +29936,59 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29719
29936
  }
29720
29937
  }
29721
29938
  }
29722
- _iterator4 = _createForOfIteratorHelper$5(article.articleOptionStates);
29939
+ _iterator4 = _createForOfIteratorHelper$5(article.articleOptionStates.values());
29723
29940
  try {
29724
29941
  for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
29725
29942
  ops = _step4.value;
29726
29943
  if (ops.optionCodex.toUpperCase().endsWith('OPTCONSTRUCTIONRULES')) {
29727
29944
  myOPVs = ops.option.articleOptionValues;
29728
- for (key2 in myOPVs) {
29729
- opv = myOPVs[key2];
29730
- opvGroupName = opv.groupName;
29731
- if (opvGroupName && opvGroupName.startsWith('ON_OPV_SET_OPV')) {
29732
- disable = false;
29733
- if (opvGroupName.endsWith('DISABLE')) {
29734
- disable = true;
29735
- }
29736
- onOpv = (_article$catalogArtic = article.catalogArticle.onConfigOption) !== null && _article$catalogArtic !== void 0 ? _article$catalogArtic : '';
29737
- onOpvArr = onOpv.split(',');
29738
- invaliOPVs = (_article$catalogArtic2 = article.catalogArticle.onSetConfigOtpion) !== null && _article$catalogArtic2 !== void 0 ? _article$catalogArtic2 : '';
29739
- invalidOPVArr = invaliOPVs.split(',');
29740
- for (j = 0; j < onOpvArr.length; j++) {
29741
- //alle OPVs auf welche zu prüfen ist durchlaufen
29742
- opvRule = onOpvArr[j].split(':');
29743
- ops2 = article.getArticleOptionStateFlat(opvRule[0]);
29744
- if (ops2) {
29745
- if (ops2.valCodex == opvRule[1]) {
29746
- for (i = 0; i < invalidOPVArr.length; i++) {
29747
- //alle zu deaktivierende OPVs durchgehen
29748
- invalidOpv = invalidOPVArr[i].split(':');
29749
- ops3 = article.getArticleOptionStateFlat(invalidOpv[0]);
29750
- if (ops3) {
29751
- key = onOpvArr[j];
29752
- constructionRule = {
29753
- message: {
29754
- DE: opv.name,
29755
- IT: opv.name,
29756
- FR: opv.name
29757
- },
29758
- type: disable ? 'DISABLE' : 'WARNING'
29759
- };
29760
- article.addUpdatedOPVbyOPVConstructionRules(key, article.updateOPVConstruction(invalidOpv[0], invalidOpv[1], constructionRule));
29761
- somethingChanged = true;
29945
+ _iterator5 = _createForOfIteratorHelper$5(myOPVs);
29946
+ try {
29947
+ for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
29948
+ _step5$value = _slicedToArray__default["default"](_step5.value, 2), key2 = _step5$value[0], opv = _step5$value[1];
29949
+ opvGroupName = opv.groupName;
29950
+ if (opvGroupName && opvGroupName.startsWith('ON_OPV_SET_OPV')) {
29951
+ disable = false;
29952
+ if (opvGroupName.endsWith('DISABLE')) {
29953
+ disable = true;
29954
+ }
29955
+ onOpv = (_article$catalogArtic = article.catalogArticle.onConfigOption) !== null && _article$catalogArtic !== void 0 ? _article$catalogArtic : '';
29956
+ onOpvArr = onOpv.split(',');
29957
+ invaliOPVs = (_article$catalogArtic2 = article.catalogArticle.onSetConfigOtpion) !== null && _article$catalogArtic2 !== void 0 ? _article$catalogArtic2 : '';
29958
+ invalidOPVArr = invaliOPVs.split(',');
29959
+ for (j = 0; j < onOpvArr.length; j++) {
29960
+ //alle OPVs auf welche zu prüfen ist durchlaufen
29961
+ opvRule = onOpvArr[j].split(':');
29962
+ ops2 = article.getArticleOptionStateFlat(opvRule[0]);
29963
+ if (ops2) {
29964
+ if (ops2.valCodex == opvRule[1]) {
29965
+ for (i = 0; i < invalidOPVArr.length; i++) {
29966
+ //alle zu deaktivierende OPVs durchgehen
29967
+ invalidOpv = invalidOPVArr[i].split(':');
29968
+ ops3 = article.getArticleOptionStateFlat(invalidOpv[0]);
29969
+ if (ops3) {
29970
+ key = onOpvArr[j];
29971
+ constructionRule = {
29972
+ message: {
29973
+ DE: opv.name,
29974
+ IT: opv.name,
29975
+ FR: opv.name
29976
+ },
29977
+ type: disable ? 'DISABLE' : 'WARNING'
29978
+ };
29979
+ article.addUpdatedOPVbyOPVConstructionRules(key, article.updateOPVConstruction(invalidOpv[0], invalidOpv[1], constructionRule));
29980
+ somethingChanged = true;
29981
+ }
29762
29982
  }
29763
29983
  }
29764
29984
  }
29765
29985
  }
29766
29986
  }
29767
29987
  }
29988
+ } catch (err) {
29989
+ _iterator5.e(err);
29990
+ } finally {
29991
+ _iterator5.f();
29768
29992
  }
29769
29993
  }
29770
29994
  }
@@ -29774,26 +29998,26 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29774
29998
  _iterator4.f();
29775
29999
  }
29776
30000
  if (!((_article$CatalogData$ = article.CatalogData.warningRules) !== null && _article$CatalogData$ !== void 0 && _article$CatalogData$.length)) {
29777
- _context18.next = 20;
30001
+ _context17.next = 20;
29778
30002
  break;
29779
30003
  }
29780
30004
  notifications = this.checkNotificationRules(article.CatalogData.warningRules, _defineProperty__default["default"]({}, article.basketId, article), {});
29781
30005
  if (!(notifications !== null && notifications !== void 0 && notifications.length)) {
29782
- _context18.next = 20;
30006
+ _context17.next = 20;
29783
30007
  break;
29784
30008
  }
29785
30009
  _i4 = 0;
29786
30010
  case 11:
29787
30011
  if (!(_i4 < notifications.length)) {
29788
- _context18.next = 19;
30012
+ _context17.next = 19;
29789
30013
  break;
29790
30014
  }
29791
30015
  _item = notifications[_i4];
29792
30016
  if (_item.showAsWarning) {
29793
- _context18.next = 15;
30017
+ _context17.next = 15;
29794
30018
  break;
29795
30019
  }
29796
- return _context18.abrupt("continue", 16);
30020
+ return _context17.abrupt("continue", 16);
29797
30021
  case 15:
29798
30022
  article.addUpdatedOPVbyOPVConstructionRules(_item.showAsWarning.option + ';' + _item.showAsWarning.optionValue, article.updateOPVConstruction((!article.CatalogData.isIDMFormat ? 'OPT' : '') + _item.showAsWarning.option, (!article.CatalogData.isIDMFormat ? 'OPV' : '') + _item.showAsWarning.optionValue, {
29799
30023
  message: _item.message,
@@ -29801,20 +30025,20 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29801
30025
  }));
29802
30026
  case 16:
29803
30027
  _i4++;
29804
- _context18.next = 11;
30028
+ _context17.next = 11;
29805
30029
  break;
29806
30030
  case 19:
29807
30031
  somethingChanged = true;
29808
30032
  case 20:
29809
30033
  if (!(somethingChanged && JSON.stringify(previousRules) != JSON.stringify(article.updatedOPVbyOPVConstructionRules))) {
29810
- _context18.next = 23;
30034
+ _context17.next = 23;
29811
30035
  break;
29812
30036
  }
29813
- _context18.next = 23;
30037
+ _context17.next = 23;
29814
30038
  return this.updateCfgValues(article, {}, {});
29815
30039
  case 23:
29816
30040
  case "end":
29817
- return _context18.stop();
30041
+ return _context17.stop();
29818
30042
  }
29819
30043
  }, _callee16, this);
29820
30044
  }));
@@ -29853,7 +30077,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29853
30077
  if (ruleValid) break;
29854
30078
  }
29855
30079
  if (ruleValid) {
29856
- returnValue.push(_objectSpread$d(_objectSpread$d({}, entry), {}, {
30080
+ returnValue.push(_objectSpread$c(_objectSpread$c({}, entry), {}, {
29857
30081
  index: i
29858
30082
  }));
29859
30083
  break;
@@ -29926,7 +30150,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29926
30150
  value: function checkIfAllOptionsAreDefined(articles) {
29927
30151
  var articleNames = [];
29928
30152
  var options = [];
29929
- var _loop3 = function _loop3(baksetId) {
30153
+ var _loop2 = function _loop2(baksetId) {
29930
30154
  var article = articles[baksetId];
29931
30155
  if (!article.areAllOptionsDefined) {
29932
30156
  var requiredUserInputOptions = article.requiredUserInputOptions;
@@ -29942,7 +30166,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29942
30166
  }
29943
30167
  };
29944
30168
  for (var baksetId in articles) {
29945
- _loop3(baksetId);
30169
+ _loop2(baksetId);
29946
30170
  }
29947
30171
  return {
29948
30172
  articleNames: articleNames,
@@ -29970,8 +30194,8 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29970
30194
  var filter = article.plannerData.AVLFilter[i];
29971
30195
  if (dockedToArticle.plannerData.AVRFilter.includes(filter)) {
29972
30196
  var ops = article.getArticleOptionState((!article.CatalogData.isIDMFormat ? 'OPT' : '') + '89');
29973
- if (ops !== null && ops !== void 0 && ops.visibleOptionValues[(!article.CatalogData.isIDMFormat ? 'OPV' : '') + filter]) {
29974
- article.engine.setOP(ops.optionCodex, ops.visibleOptionValues[(!article.CatalogData.isIDMFormat ? 'OPV' : '') + filter]);
30197
+ if (ops !== null && ops !== void 0 && ops.visibleOptionValues.get((!article.CatalogData.isIDMFormat ? 'OPV' : '') + filter)) {
30198
+ article.engine.setOP(ops.optionCodex, ops.visibleOptionValues.get((!article.CatalogData.isIDMFormat ? 'OPV' : '') + filter));
29975
30199
  somethingChanged = true;
29976
30200
  break;
29977
30201
  }
@@ -29983,8 +30207,8 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29983
30207
  var _filter = article.plannerData.AVRFilter[_i5];
29984
30208
  if (dockedToArticle.plannerData.AVLFilter.includes(_filter)) {
29985
30209
  var _ops2 = article.getArticleOptionState((!article.CatalogData.isIDMFormat ? 'OPT' : '') + '90');
29986
- if (_ops2 !== null && _ops2 !== void 0 && _ops2.visibleOptionValues[(!article.CatalogData.isIDMFormat ? 'OPV' : '') + _filter]) {
29987
- article.engine.setOP(_ops2.optionCodex, _ops2.visibleOptionValues[(!article.CatalogData.isIDMFormat ? 'OPV' : '') + _filter]);
30210
+ if (_ops2 !== null && _ops2 !== void 0 && _ops2.visibleOptionValues.get((!article.CatalogData.isIDMFormat ? 'OPV' : '') + _filter)) {
30211
+ article.engine.setOP(_ops2.optionCodex, _ops2.visibleOptionValues.get((!article.CatalogData.isIDMFormat ? 'OPV' : '') + _filter));
29988
30212
  somethingChanged = true;
29989
30213
  break;
29990
30214
  }
@@ -29999,25 +30223,25 @@ var DivaArticleHandler = /*#__PURE__*/function () {
29999
30223
  value: function () {
30000
30224
  var _triggerShelfplannerVisibility = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee17(artices, gridGroup) {
30001
30225
  var key, _artice$shelfPlanner, artice;
30002
- return _regeneratorRuntime__default["default"].wrap(function _callee17$(_context19) {
30003
- while (1) switch (_context19.prev = _context19.next) {
30226
+ return _regeneratorRuntime__default["default"].wrap(function _callee17$(_context18) {
30227
+ while (1) switch (_context18.prev = _context18.next) {
30004
30228
  case 0:
30005
- _context19.t0 = _regeneratorRuntime__default["default"].keys(artices);
30229
+ _context18.t0 = _regeneratorRuntime__default["default"].keys(artices);
30006
30230
  case 1:
30007
- if ((_context19.t1 = _context19.t0()).done) {
30008
- _context19.next = 8;
30231
+ if ((_context18.t1 = _context18.t0()).done) {
30232
+ _context18.next = 8;
30009
30233
  break;
30010
30234
  }
30011
- key = _context19.t1.value;
30235
+ key = _context18.t1.value;
30012
30236
  artice = artices[key];
30013
- _context19.next = 6;
30237
+ _context18.next = 6;
30014
30238
  return (_artice$shelfPlanner = artice.shelfPlanner) === null || _artice$shelfPlanner === void 0 ? void 0 : _artice$shelfPlanner.triggerVisibility(gridGroup);
30015
30239
  case 6:
30016
- _context19.next = 1;
30240
+ _context18.next = 1;
30017
30241
  break;
30018
30242
  case 8:
30019
30243
  case "end":
30020
- return _context19.stop();
30244
+ return _context18.stop();
30021
30245
  }
30022
30246
  }, _callee17);
30023
30247
  }));
@@ -30043,7 +30267,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30043
30267
  var hasFavorites = arguments.length > 3 ? arguments[3] : undefined;
30044
30268
  var ret = [];
30045
30269
  if (Object.values(articles).length == 0) return ret;
30046
- var _loop4 = function _loop4() {
30270
+ var _loop3 = function _loop3() {
30047
30271
  var _article$shelfPlanner3, _article$shelfPlanner4, _article$doorPlanner;
30048
30272
  var article = articles[key];
30049
30273
  var catalogData = article.CatalogData;
@@ -30127,7 +30351,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30127
30351
  ret = ret.concat(_this2.getOptiontreeAccessoiresArr(article.set.getSetId(), article));
30128
30352
  };
30129
30353
  for (var key in articles) {
30130
- _loop4();
30354
+ _loop3();
30131
30355
  }
30132
30356
  return ret;
30133
30357
  }
@@ -30172,11 +30396,11 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30172
30396
  value: function getOptiontreeAccessoiresArr(setId, article) {
30173
30397
  var s = 0;
30174
30398
  var accessoires = [];
30175
- var _iterator5 = _createForOfIteratorHelper$5(article.articleOptionStates),
30176
- _step5;
30399
+ var _iterator6 = _createForOfIteratorHelper$5(article.articleOptionStates.values()),
30400
+ _step6;
30177
30401
  try {
30178
- for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
30179
- var ops = _step5.value;
30402
+ for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
30403
+ var ops = _step6.value;
30180
30404
  if (ops.option.articlePlaceholder) {
30181
30405
  //ArticlePlaceholder bestimmt, ob Optionswert als eigene SAPOrderline ausgegeben wird
30182
30406
  if (ops.isAccessoirArtNr && ops.isAccessoirArtNr != '') {
@@ -30192,9 +30416,9 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30192
30416
  }
30193
30417
  }
30194
30418
  } catch (err) {
30195
- _iterator5.e(err);
30419
+ _iterator6.e(err);
30196
30420
  } finally {
30197
- _iterator5.f();
30421
+ _iterator6.f();
30198
30422
  }
30199
30423
  return accessoires;
30200
30424
  }
@@ -30293,20 +30517,20 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30293
30517
  key: "correctPartlistArticlesByGlobalRules",
30294
30518
  value: (function () {
30295
30519
  var _correctPartlistArticlesByGlobalRules = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee18(set, partlistArticlesToLoad, bundleRules, doChangeRetailArticleNumbers) {
30296
- var _loop5, i, article;
30297
- return _regeneratorRuntime__default["default"].wrap(function _callee18$(_context21) {
30298
- while (1) switch (_context21.prev = _context21.next) {
30520
+ var _loop4, i, article;
30521
+ return _regeneratorRuntime__default["default"].wrap(function _callee18$(_context20) {
30522
+ while (1) switch (_context20.prev = _context20.next) {
30299
30523
  case 0:
30300
30524
  if (bundleRules) partlistArticlesToLoad = this.bundlePartlistArticles(partlistArticlesToLoad, bundleRules, set.getDivaArticles());
30301
30525
  //Correct RetailArticleNumbers
30302
30526
  if (!(doChangeRetailArticleNumbers !== null && doChangeRetailArticleNumbers !== void 0 && doChangeRetailArticleNumbers.doChange && doChangeRetailArticleNumbers.retailArticleRules)) {
30303
- _context21.next = 9;
30527
+ _context20.next = 9;
30304
30528
  break;
30305
30529
  }
30306
- _loop5 = /*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _loop5(i) {
30530
+ _loop4 = /*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _loop4(i) {
30307
30531
  var rule;
30308
- return _regeneratorRuntime__default["default"].wrap(function _loop5$(_context20) {
30309
- while (1) switch (_context20.prev = _context20.next) {
30532
+ return _regeneratorRuntime__default["default"].wrap(function _loop4$(_context19) {
30533
+ while (1) switch (_context19.prev = _context19.next) {
30310
30534
  case 0:
30311
30535
  //Run through articleCodexes to repair:
30312
30536
  rule = doChangeRetailArticleNumbers.retailArticleRules.find(function (item) {
@@ -30318,30 +30542,30 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30318
30542
  }
30319
30543
  case 2:
30320
30544
  case "end":
30321
- return _context20.stop();
30545
+ return _context19.stop();
30322
30546
  }
30323
- }, _loop5);
30547
+ }, _loop4);
30324
30548
  });
30325
30549
  i = 0;
30326
30550
  case 4:
30327
30551
  if (!(i < partlistArticlesToLoad.length)) {
30328
- _context21.next = 9;
30552
+ _context20.next = 9;
30329
30553
  break;
30330
30554
  }
30331
- return _context21.delegateYield(_loop5(i), "t0", 6);
30555
+ return _context20.delegateYield(_loop4(i), "t0", 6);
30332
30556
  case 6:
30333
30557
  i++;
30334
- _context21.next = 4;
30558
+ _context20.next = 4;
30335
30559
  break;
30336
30560
  case 9:
30337
30561
  article = Object.values(set.getDivaArticles()).find(function (article) {
30338
30562
  return article.hasPartlistArticle && !article.deleted;
30339
30563
  });
30340
- _context21.next = 12;
30564
+ _context20.next = 12;
30341
30565
  return this.loadPartlistArticles(partlistArticlesToLoad, article, {});
30342
30566
  case 12:
30343
30567
  case "end":
30344
- return _context21.stop();
30568
+ return _context20.stop();
30345
30569
  }
30346
30570
  }, _callee18, this);
30347
30571
  }));
@@ -30354,7 +30578,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30354
30578
  key: "bundlePartlistArticles",
30355
30579
  value: function bundlePartlistArticles(partlistArticlesToLoad, bundleRules, articles) {
30356
30580
  var partlistArticlesToLoadGrouped = [];
30357
- var _loop6 = function _loop6(i) {
30581
+ var _loop5 = function _loop5(i) {
30358
30582
  var index = partlistArticlesToLoadGrouped.findIndex(function (item, j) {
30359
30583
  if (item.CatalogCodex == partlistArticlesToLoad[i].CatalogCodex && item.ArticleCodex == partlistArticlesToLoad[i].ArticleCodex && item.RetailArticleNr == partlistArticlesToLoad[i].RetailArticleNr && item.RetailPrefix == partlistArticlesToLoad[i].RetailPrefix) {
30360
30584
  return true;
@@ -30368,7 +30592,7 @@ var DivaArticleHandler = /*#__PURE__*/function () {
30368
30592
  }
30369
30593
  };
30370
30594
  for (var i = 0; i < partlistArticlesToLoad.length; i++) {
30371
- _loop6(i);
30595
+ _loop5(i);
30372
30596
  }
30373
30597
  //bundle Partlistarticles
30374
30598
  for (var _i6 = 0; _i6 < bundleRules.length; _i6++) {
@@ -31233,8 +31457,8 @@ var DivaConfigTreeData = /*#__PURE__*/function () {
31233
31457
  function _createForOfIteratorHelper$4(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$4(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
31234
31458
  function _unsupportedIterableToArray$4(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$4(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$4(r, a) : void 0; } }
31235
31459
  function _arrayLikeToArray$4(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
31236
- function ownKeys$c(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; }
31237
- function _objectSpread$c(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$c(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$c(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
31460
+ function ownKeys$b(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; }
31461
+ function _objectSpread$b(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$b(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$b(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
31238
31462
  var LOG$b = DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
31239
31463
  //plz delete me
31240
31464
  var DivaSet = /*#__PURE__*/function () {
@@ -31334,7 +31558,7 @@ var DivaSet = /*#__PURE__*/function () {
31334
31558
  _context.next = 10;
31335
31559
  break;
31336
31560
  }
31337
- validValues = repairVariantValuesAndPlanner ? article.getValidValues(_objectSpread$c({}, variantValues), article.CatalogData.mergeOptionsToSameOption) : {};
31561
+ validValues = repairVariantValuesAndPlanner ? article.getValidValues(_objectSpread$b({}, variantValues), article.CatalogData.mergeOptionsToSameOption) : {};
31338
31562
  _context.t0 = partlistArticlesToLoad;
31339
31563
  _context.next = 8;
31340
31564
  return articleHandlerInstance.updateCfgValues(article, repairVariantValuesAndPlanner ? validValues : variantValues, {}, undefined, loadPlas);
@@ -31904,8 +32128,8 @@ var DivaSet = /*#__PURE__*/function () {
31904
32128
  var articles = {};
31905
32129
  for (var basketId in this.divaArticles) {
31906
32130
  articles[basketId] = this.divaArticles[basketId];
31907
- if (allPartlistArticlesAlso) articles = _objectSpread$c(_objectSpread$c({}, articles), articles[basketId].getRecursivePartlistArticles());
31908
- if (visiblePartlistArticlesAlso) articles = _objectSpread$c(_objectSpread$c({}, articles), articles[basketId].getRecursivePartlistArticles(true));
32131
+ if (allPartlistArticlesAlso) articles = _objectSpread$b(_objectSpread$b({}, articles), articles[basketId].getRecursivePartlistArticles());
32132
+ if (visiblePartlistArticlesAlso) articles = _objectSpread$b(_objectSpread$b({}, articles), articles[basketId].getRecursivePartlistArticles(true));
31909
32133
  }
31910
32134
  return articles;
31911
32135
  }
@@ -32065,7 +32289,7 @@ var DivaSet = /*#__PURE__*/function () {
32065
32289
  var cleanedDimensions = [];
32066
32290
  for (var basketId in articles) {
32067
32291
  var artice = articles[basketId];
32068
- var _iterator3 = _createForOfIteratorHelper$4(artice.articleOptionStates),
32292
+ var _iterator3 = _createForOfIteratorHelper$4(artice.articleOptionStates.values()),
32069
32293
  _step3;
32070
32294
  try {
32071
32295
  var _loop2 = function _loop2() {
@@ -32276,7 +32500,7 @@ var DivaSet = /*#__PURE__*/function () {
32276
32500
  var options = [];
32277
32501
  for (var key in this.divaArticles) {
32278
32502
  var article = this.divaArticles[key];
32279
- var _iterator4 = _createForOfIteratorHelper$4(article.articleOptionStates),
32503
+ var _iterator4 = _createForOfIteratorHelper$4(article.articleOptionStates.values()),
32280
32504
  _step4;
32281
32505
  try {
32282
32506
  for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
@@ -32537,7 +32761,7 @@ var DivaSet = /*#__PURE__*/function () {
32537
32761
  break;
32538
32762
  }
32539
32763
  _context5.next = 3;
32540
- return Promise.resolve().then(function () { return require('./DoorPlanner-10e97f07.js'); });
32764
+ return Promise.resolve().then(function () { return require('./DoorPlanner-f5c079a9.js'); });
32541
32765
  case 3:
32542
32766
  _yield$import = _context5.sent;
32543
32767
  DoorPlanner = _yield$import["default"];
@@ -32726,8 +32950,8 @@ var DivaSet = /*#__PURE__*/function () {
32726
32950
  }, {
32727
32951
  key: "cloneSet",
32728
32952
  value: function cloneSet() {
32729
- var clonedSet = new DivaSet(this.CatalogData, this.setId, {}, _objectSpread$c({}, this.setState));
32730
- clonedSet.setData = _objectSpread$c({}, this.setData);
32953
+ var clonedSet = new DivaSet(this.CatalogData, this.setId, {}, _objectSpread$b({}, this.setState));
32954
+ clonedSet.setData = _objectSpread$b({}, this.setData);
32731
32955
  clonedSet.configSingle = this.configSingle;
32732
32956
  clonedSet.logTotalStateForVariants = this.logTotalStateForVariants;
32733
32957
  var articles = this.getDivaArticles();
@@ -32760,7 +32984,7 @@ var SummaryHandler = /*#__PURE__*/function () {
32760
32984
  for (var basketId in articles) {
32761
32985
  //add config Steps
32762
32986
  var article = articles[basketId];
32763
- var _iterator = _createForOfIteratorHelper$3(article.articleOptionStates),
32987
+ var _iterator = _createForOfIteratorHelper$3(article.articleOptionStates.values()),
32764
32988
  _step;
32765
32989
  try {
32766
32990
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -33574,8 +33798,8 @@ var SummaryHandler = /*#__PURE__*/function () {
33574
33798
  }();
33575
33799
  var summaryHandlerInstance = new SummaryHandler();
33576
33800
 
33577
- function ownKeys$b(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; }
33578
- function _objectSpread$b(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$b(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$b(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
33801
+ function ownKeys$a(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; }
33802
+ function _objectSpread$a(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$a(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$a(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
33579
33803
  DivaUtils__default["default"].initLog('Planner', 'WEB-PLANNER-LOGIC');
33580
33804
  var DivaFavoritesHandler = /*#__PURE__*/function () {
33581
33805
  function DivaFavoritesHandler() {
@@ -34264,7 +34488,7 @@ var DivaFavoritesHandler = /*#__PURE__*/function () {
34264
34488
  if (targetArticle[opt] && !variantValues[opt]) variantValues[opt] = targetArticle[opt];
34265
34489
  }
34266
34490
  }
34267
- configVariant = new basketModel.ConfigVariantData(variant.id, set.setName, set.setName_locales, setImage, (_hQRenderScript = hQRenderScript) === null || _hQRenderScript === void 0 ? void 0 : _hQRenderScript._id, DivaUtils__default["default"].encodeBase64(set.plannerHandler.getProject3D(set.getSetId())), set.getVariantsDescription(), set.SetArticleNr, set.getSetPrice(), set.setHash, 1, set.getVariantBasketData(), articleHandlerInstance.getCompactOrderLine(_objectSpread$b(_objectSpread$b({}, set.getDivaArticles()), set.getPartlistArticlesOfSet())), variantValues, summaryHandlerInstance.convertSummaryItemsToSummaryInfo(set), plannerData != undefined ? DivaUtils__default["default"].encodeBase64(JSON.stringify(plannerData)) : '', urlToPlanning2D, setHandlerInstance.getBBoxObject(set, dimensions), set.getBruttoSetPrice(), undefined, undefined, set.MetaData, set.MetaData_locales, DivaUtils__default["default"].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);
34491
+ configVariant = new basketModel.ConfigVariantData(variant.id, set.setName, set.setName_locales, setImage, (_hQRenderScript = hQRenderScript) === null || _hQRenderScript === void 0 ? void 0 : _hQRenderScript._id, DivaUtils__default["default"].encodeBase64(set.plannerHandler.getProject3D(set.getSetId())), set.getVariantsDescription(), set.SetArticleNr, set.getSetPrice(), set.setHash, 1, set.getVariantBasketData(), articleHandlerInstance.getCompactOrderLine(_objectSpread$a(_objectSpread$a({}, set.getDivaArticles()), set.getPartlistArticlesOfSet())), variantValues, summaryHandlerInstance.convertSummaryItemsToSummaryInfo(set), plannerData != undefined ? DivaUtils__default["default"].encodeBase64(JSON.stringify(plannerData)) : '', urlToPlanning2D, setHandlerInstance.getBBoxObject(set, dimensions), set.getBruttoSetPrice(), undefined, undefined, set.MetaData, set.MetaData_locales, DivaUtils__default["default"].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);
34268
34492
  set.basketConfigVariants.push(configVariant);
34269
34493
  case 31:
34270
34494
  case "end":
@@ -34359,8 +34583,6 @@ var DivaFavoritesHandler = /*#__PURE__*/function () {
34359
34583
  }();
34360
34584
  var favoritesHandlerInstance = new DivaFavoritesHandler();
34361
34585
 
34362
- function ownKeys$a(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; }
34363
- function _objectSpread$a(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$a(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$a(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
34364
34586
  function _createForOfIteratorHelper$2(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$2(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
34365
34587
  function _unsupportedIterableToArray$2(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$2(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$2(r, a) : void 0; } }
34366
34588
  function _arrayLikeToArray$2(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
@@ -34460,7 +34682,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34460
34682
  for (var basketId in optionStatesOfArticles) {
34461
34683
  //hier evtl. die Article mit einer gewissen reihenfolge durchlaufen!
34462
34684
  var optionsStates = optionStatesOfArticles[basketId];
34463
- var _iterator = _createForOfIteratorHelper$2(optionsStates),
34685
+ var _iterator = _createForOfIteratorHelper$2(optionsStates.values()),
34464
34686
  _step;
34465
34687
  try {
34466
34688
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -34699,7 +34921,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34699
34921
  if (o && !!o.isDifferentOption && !((_o$valCodex = o.valCodex) !== null && _o$valCodex !== void 0 && _o$valCodex.includes('OPVSUB'))) {
34700
34922
  return true;
34701
34923
  }
34702
- var rul = (_ops$visibleOptionVal = ops.visibleOptionValues[ops.visibleOPVKeys[0]]) === null || _ops$visibleOptionVal === void 0 ? void 0 : _ops$visibleOptionVal.rul;
34924
+ var rul = (_ops$visibleOptionVal = ops.visibleOptionValues.get(ops.visibleOPVKeys[0])) === null || _ops$visibleOptionVal === void 0 ? void 0 : _ops$visibleOptionVal.rul;
34703
34925
  if (rul) {
34704
34926
  var parentOptions = DivaUtils__default["default"].getOptionsByRule(rul);
34705
34927
  return !!parentOptions.find(function (o) {
@@ -34767,7 +34989,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34767
34989
  key: "getConifgItemsForView",
34768
34990
  value: function () {
34769
34991
  var _getConifgItemsForView = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee(set, configStepKey) {
34770
- var articles, step, retValues, optionCodex, configItems, selectedItems, optionState, key, _configItem$parent$oc, configItem, configItemsInOPG, retVal, _retVal, totalTime, configStepOPG, configStepOPV, targetArticle, opg, ops, selectedOpv, originalVariantValues, seomethingChanged, variantValues, _key, _set$favorites$Varian, _set$favorites, startTime, alreadyCalcedVisibleOPVs, i, _ops$optionOcd2, _retVal2, clonedConfigItemsForView, _i, timeDiff, _configItems;
34992
+ var articles, step, retValues, optionCodex, configItems, selectedItems, optionState, _iterator2, _step2, _configItem$parent$oc, key, configItem, configItemsInOPG, retVal, _retVal, totalTime, configStepOPG, configStepOPV, targetArticle, opg, ops, selectedOpv, originalVariantValues, seomethingChanged, variantValues, _iterator3, _step3, _set$favorites$Varian, _set$favorites, _key, startTime, alreadyCalcedVisibleOPVs, _i, _ops$optionOcd2, _retVal2, clonedConfigItemsForView, i, timeDiff;
34771
34993
  return _regeneratorRuntime__default["default"].wrap(function _callee$(_context) {
34772
34994
  while (1) switch (_context.prev = _context.next) {
34773
34995
  case 0:
@@ -34776,7 +34998,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34776
34998
  retValues = this.getConfigItems(configStepKey, articles, set.configTree);
34777
34999
  optionCodex = undefined;
34778
35000
  if (!(retValues && step != null)) {
34779
- _context.next = 65;
35001
+ _context.next = 95;
34780
35002
  break;
34781
35003
  }
34782
35004
  configItems = [];
@@ -34790,115 +35012,157 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34790
35012
  case 10:
34791
35013
  optionCodex = optionState.optionCodex;
34792
35014
  if (!retValues.isOPG) {
34793
- _context.next = 15;
35015
+ _context.next = 35;
34794
35016
  break;
34795
35017
  }
34796
- for (key in retValues.configItems) {
34797
- configItem = retValues.configItems[key];
34798
- optionCodex = (_configItem$parent$oc = configItem.parent.ocd) !== null && _configItem$parent$oc !== void 0 ? _configItem$parent$oc : configItem.parent.codex;
34799
- configItemsInOPG = configItem.articleOptionValues;
34800
- if (configItemsInOPG) {
34801
- retVal = this.prepareConfigItemsForView(set, optionState, configItemsInOPG, retValues.constructionRules, selectedItems, step.configStep.targetArticles, optionCodex);
34802
- configItems = configItems.concat(retVal.myConfigItemsForView);
34803
- }
35018
+ _iterator2 = _createForOfIteratorHelper$2(retValues.configItems.keys());
35019
+ _context.prev = 13;
35020
+ _iterator2.s();
35021
+ case 15:
35022
+ if ((_step2 = _iterator2.n()).done) {
35023
+ _context.next = 25;
35024
+ break;
35025
+ }
35026
+ key = _step2.value;
35027
+ configItem = retValues.configItems.get(key);
35028
+ if (configItem) {
35029
+ _context.next = 20;
35030
+ break;
34804
35031
  }
34805
- _context.next = 62;
35032
+ throw new Error('configItem ' + key + ' not found in retValues.configItems');
35033
+ case 20:
35034
+ optionCodex = (_configItem$parent$oc = configItem.parent.ocd) !== null && _configItem$parent$oc !== void 0 ? _configItem$parent$oc : configItem.parent.codex;
35035
+ configItemsInOPG = configItem.articleOptionValues;
35036
+ if (configItemsInOPG) {
35037
+ retVal = this.prepareConfigItemsForView(set, optionState, configItemsInOPG, retValues.constructionRules, selectedItems, step.configStep.targetArticles, optionCodex);
35038
+ configItems = configItems.concat(retVal.myConfigItemsForView);
35039
+ }
35040
+ case 23:
35041
+ _context.next = 15;
34806
35042
  break;
34807
- case 15:
35043
+ case 25:
35044
+ _context.next = 30;
35045
+ break;
35046
+ case 27:
35047
+ _context.prev = 27;
35048
+ _context.t0 = _context["catch"](13);
35049
+ _iterator2.e(_context.t0);
35050
+ case 30:
35051
+ _context.prev = 30;
35052
+ _iterator2.f();
35053
+ return _context.finish(30);
35054
+ case 33:
35055
+ _context.next = 92;
35056
+ break;
35057
+ case 35:
34808
35058
  if (!(step.optionStep.mergesToOPG == undefined)) {
34809
- _context.next = 20;
35059
+ _context.next = 40;
34810
35060
  break;
34811
35061
  }
34812
35062
  _retVal = this.prepareConfigItemsForView(set, optionState, retValues.configItems, retValues.constructionRules, selectedItems, step.configStep.targetArticles, undefined, undefined, undefined, undefined, retValues.freeTextValue, retValues.freeTextLang);
34813
35063
  configItems = _retVal.myConfigItemsForView;
34814
- _context.next = 62;
35064
+ _context.next = 92;
34815
35065
  break;
34816
- case 20:
35066
+ case 40:
34817
35067
  if (!(typeof step.optionStep.mergesToOPG == 'string' && step.tabGroup.options[step.optionStep.mergesToOPG])) {
34818
- _context.next = 62;
35068
+ _context.next = 92;
34819
35069
  break;
34820
35070
  }
34821
35071
  //IDM Bezugschritte werden zusammengefasst zu OPG und OPV
34822
35072
  totalTime = Date.now();
34823
35073
  configStepOPG = step.configStep, configStepOPV = set.configTree.getConfigStepBasketIdAndOptionCodex(configStepOPG.targetArticles[0], step.optionStep.mergesToOPG); //falls mehrere Artikel im Schritt sind werden trotzdem nur die Values des erster verwendet um die z.B. OPT2 und OPT3 zu vereinen
34824
35074
  if (!configStepOPV) {
34825
- _context.next = 62;
35075
+ _context.next = 92;
34826
35076
  break;
34827
35077
  }
34828
35078
  targetArticle = articles[configStepOPG.targetArticles[0]];
34829
35079
  opg = targetArticle.getArticleOptionState(configStepOPG.option);
34830
35080
  ops = targetArticle.getArticleOptionState(configStepOPV.option);
34831
35081
  if (opg) {
34832
- _context.next = 29;
35082
+ _context.next = 49;
34833
35083
  break;
34834
35084
  }
34835
35085
  throw new Error('myOptionState ' + configStepOPG.option + ' is undefined');
34836
- case 29:
35086
+ case 49:
34837
35087
  if (ops) {
34838
- _context.next = 31;
35088
+ _context.next = 51;
34839
35089
  break;
34840
35090
  }
34841
35091
  throw new Error('myOptionState ' + configStepOPV.option + ' is undefined');
34842
- case 31:
35092
+ case 51:
34843
35093
  selectedOpv = ops.val;
34844
35094
  originalVariantValues = targetArticle.VariantValues;
34845
35095
  seomethingChanged = false;
34846
35096
  variantValues = {};
34847
- _context.t0 = _regeneratorRuntime__default["default"].keys(opg.visibleOptionValues);
34848
- case 36:
34849
- if ((_context.t1 = _context.t0()).done) {
34850
- _context.next = 56;
35097
+ _iterator3 = _createForOfIteratorHelper$2(opg.visibleOptionValues.keys());
35098
+ _context.prev = 56;
35099
+ _iterator3.s();
35100
+ case 58:
35101
+ if ((_step3 = _iterator3.n()).done) {
35102
+ _context.next = 78;
34851
35103
  break;
34852
35104
  }
34853
- _key = _context.t1.value;
35105
+ _key = _step3.value;
34854
35106
  startTime = Date.now(); //die sichtbaren gruppen werden nun nacheinander beim Artikel gesetzt und die Validen bezüge jeder gruppe geholt -> visibleOptionValues;
34855
- variantValues[opg.optionCodex] = opg.visibleOptionValues[_key].codex;
34856
- alreadyCalcedVisibleOPVs = targetArticle.getMergesToOPG(opg.optionCodex + '_' + opg.visibleOptionValues[_key].codex, JSON.stringify(targetArticle.getVariantValuesTillOPT(opg.optionCodex)));
35107
+ variantValues[opg.optionCodex] = opg.visibleOptionValues.get(_key).codex;
35108
+ alreadyCalcedVisibleOPVs = targetArticle.getMergesToOPG(opg.optionCodex + '_' + opg.visibleOptionValues.get(_key).codex, JSON.stringify(targetArticle.getVariantValuesTillOPT(opg.optionCodex)));
34857
35109
  if (!(alreadyCalcedVisibleOPVs != undefined && Object.keys((_set$favorites$Varian = (_set$favorites = set.favorites) === null || _set$favorites === void 0 ? void 0 : _set$favorites.VariantValues) !== null && _set$favorites$Varian !== void 0 ? _set$favorites$Varian : {}).length == 0)) {
34858
- _context.next = 46;
35110
+ _context.next = 68;
34859
35111
  break;
34860
35112
  }
34861
35113
  //die merged OPG wurde bereist ausgerechnet und kann wiederverwendet werden. nur die Selected value muss repariert werden
34862
- if ((originalVariantValues === null || originalVariantValues === void 0 ? void 0 : originalVariantValues[opg.optionCodex]) == opg.visibleOptionValues[_key].codex) {
34863
- for (i = 0; i < alreadyCalcedVisibleOPVs.length; i++) {
34864
- if (alreadyCalcedVisibleOPVs[i].codex == ops.valCodex) {
34865
- alreadyCalcedVisibleOPVs[i].sel = true;
35114
+ if ((originalVariantValues === null || originalVariantValues === void 0 ? void 0 : originalVariantValues[opg.optionCodex]) == opg.visibleOptionValues.get(_key).codex) {
35115
+ for (_i = 0; _i < alreadyCalcedVisibleOPVs.length; _i++) {
35116
+ if (alreadyCalcedVisibleOPVs[_i].codex == ops.valCodex) {
35117
+ alreadyCalcedVisibleOPVs[_i].sel = true;
34866
35118
  }
34867
35119
  }
34868
35120
  }
34869
35121
  configItems = configItems.concat(alreadyCalcedVisibleOPVs);
34870
- _context.next = 53;
35122
+ _context.next = 75;
34871
35123
  break;
34872
- case 46:
35124
+ case 68:
34873
35125
  seomethingChanged = true;
34874
- _context.next = 49;
35126
+ _context.next = 71;
34875
35127
  return articleHandlerInstance.updateCfgValues(targetArticle, variantValues, {}, true, true, true, true);
34876
- case 49:
34877
- _retVal2 = this.prepareConfigItemsForView(set, optionState, targetArticle.getArticleOptionState(ops.optionCodex).visibleOptionValues, retValues.constructionRules, [], step.configStep.targetArticles, (_ops$optionOcd2 = ops.optionOcd) !== null && _ops$optionOcd2 !== void 0 ? _ops$optionOcd2 : ops.optionCodex, opg.visibleOptionValues[_key].name, opg.visibleOptionValues[_key].codex, opg.optionCodex);
35128
+ case 71:
35129
+ _retVal2 = this.prepareConfigItemsForView(set, optionState, targetArticle.getArticleOptionState(ops.optionCodex).visibleOptionValues, retValues.constructionRules, [], step.configStep.targetArticles, (_ops$optionOcd2 = ops.optionOcd) !== null && _ops$optionOcd2 !== void 0 ? _ops$optionOcd2 : ops.optionCodex, opg.visibleOptionValues.get(_key).name, opg.visibleOptionValues.get(_key).codex, opg.optionCodex);
34878
35130
  configItems = configItems.concat(_retVal2.myConfigItemsForView);
34879
35131
  clonedConfigItemsForView = JSON.parse(JSON.stringify(_retVal2.myConfigItemsForView));
34880
- targetArticle.addMergesToOPG(opg.optionCodex + '_' + opg.visibleOptionValues[_key].codex, JSON.stringify(targetArticle.getVariantValuesTillOPT(opg.optionCodex)), clonedConfigItemsForView);
34881
- case 53:
35132
+ targetArticle.addMergesToOPG(opg.optionCodex + '_' + opg.visibleOptionValues.get(_key).codex, JSON.stringify(targetArticle.getVariantValuesTillOPT(opg.optionCodex)), clonedConfigItemsForView);
35133
+ case 75:
34882
35134
  LOG$a.debug('calculating for merge to opg', _key, Date.now() - startTime + 'ms');
34883
- _context.next = 36;
35135
+ case 76:
35136
+ _context.next = 58;
34884
35137
  break;
34885
- case 56:
35138
+ case 78:
35139
+ _context.next = 83;
35140
+ break;
35141
+ case 80:
35142
+ _context.prev = 80;
35143
+ _context.t1 = _context["catch"](56);
35144
+ _iterator3.e(_context.t1);
35145
+ case 83:
35146
+ _context.prev = 83;
35147
+ _iterator3.f();
35148
+ return _context.finish(83);
35149
+ case 86:
34886
35150
  if (!seomethingChanged) {
34887
- _context.next = 59;
35151
+ _context.next = 89;
34888
35152
  break;
34889
35153
  }
34890
- _context.next = 59;
35154
+ _context.next = 89;
34891
35155
  return setHandlerInstance.updateArticlesOptionStatesOfActSet(set, originalVariantValues, [targetArticle.basketId], true, 'calcVariant');
34892
- case 59:
34893
- for (_i = 0; _i < configItems.length; _i++) {
34894
- if (configItems[_i].codex == (selectedOpv === null || selectedOpv === void 0 ? void 0 : selectedOpv.codex)) {
35156
+ case 89:
35157
+ for (i = 0; i < configItems.length; i++) {
35158
+ if (configItems[i].codex == (selectedOpv === null || selectedOpv === void 0 ? void 0 : selectedOpv.codex)) {
34895
35159
  selectedItems = [selectedOpv.codex];
34896
- configItems[_i].sel = true;
35160
+ configItems[i].sel = true;
34897
35161
  }
34898
35162
  }
34899
35163
  timeDiff = Date.now() - totalTime;
34900
35164
  LOG$a.debug('calculating for merge to opg', 'totalTime', timeDiff + 'ms');
34901
- case 62:
35165
+ case 92:
34902
35166
  return _context.abrupt("return", {
34903
35167
  configItems: configItems,
34904
35168
  option: optionCodex ? set.CatalogData.getOption(optionCodex) : undefined,
@@ -34909,17 +35173,16 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34909
35173
  }),
34910
35174
  notTotallyMatichingOPVs: !set.CatalogData.articleConfigAll ? retValues.notTotallyMatichingOPVs : undefined
34911
35175
  });
34912
- case 65:
34913
- _configItems = [];
35176
+ case 95:
34914
35177
  return _context.abrupt("return", {
34915
- configItems: _configItems,
35178
+ configItems: [],
34916
35179
  selectedItems: []
34917
35180
  });
34918
- case 67:
35181
+ case 96:
34919
35182
  case "end":
34920
35183
  return _context.stop();
34921
35184
  }
34922
- }, _callee, this);
35185
+ }, _callee, this, [[13, 27, 30, 33], [56, 80, 83, 86]]);
34923
35186
  }));
34924
35187
  function getConifgItemsForView(_x, _x2) {
34925
35188
  return _getConifgItemsForView.apply(this, arguments);
@@ -34931,7 +35194,7 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34931
35194
  value: function getConfigItems(key, articles, configTree) {
34932
35195
  var step = configTree.getAllByKey(key);
34933
35196
  if (step != null) {
34934
- var configItems = {},
35197
+ var configItems = new Map(),
34935
35198
  visibleOptionValuesOfArticles = [],
34936
35199
  constructionRules = {},
34937
35200
  selectedVals = [],
@@ -34959,28 +35222,37 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34959
35222
  //get schnittmenge of all the articles
34960
35223
  if (i === 0) {
34961
35224
  constructionRules = myOptionState.constructionRules;
34962
- configItems = _objectSpread$a({}, myOptionState.visibleOptionValues);
35225
+ configItems = new Map(myOptionState.visibleOptionValues);
34963
35226
  } else {
34964
- for (var _key2 in configItems) {
34965
- if (!myOptionState.visibleOptionValues[_key2]) {
34966
- delete configItems[_key2];
35227
+ var _iterator4 = _createForOfIteratorHelper$2(configItems.keys()),
35228
+ _step4;
35229
+ try {
35230
+ for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
35231
+ var _key2 = _step4.value;
35232
+ if (!myOptionState.visibleOptionValues.get(_key2)) {
35233
+ configItems["delete"](_key2);
35234
+ }
34967
35235
  }
35236
+ } catch (err) {
35237
+ _iterator4.e(err);
35238
+ } finally {
35239
+ _iterator4.f();
34968
35240
  }
34969
35241
  }
34970
35242
  } else if (i == 0 && configStep.targetArticles.length == 1) {
34971
35243
  constructionRules = myOptionState.constructionRules;
34972
- configItems = myOptionState.visibleOptionValues;
35244
+ configItems = new Map(myOptionState.visibleOptionValues);
34973
35245
  } else {
34974
35246
  visibleOptionValuesOfArticles.push(myOptionState.visibleOptionValues);
34975
35247
  }
34976
35248
  }
34977
35249
  if (visibleOptionValuesOfArticles.length > 0) {
34978
- configItems = Object.assign({}, visibleOptionValuesOfArticles[0]);
35250
+ configItems = new Map(visibleOptionValuesOfArticles[0]);
34979
35251
  var _loop4 = function _loop4(_i2) {
34980
35252
  var _articles$configStep$;
34981
35253
  if ((_articles$configStep$ = articles[configStep.targetArticles[_i2]].getArticleOptionStateFlat(configStep.option)) !== null && _articles$configStep$ !== void 0 && _articles$configStep$.definedBySetFeatureFixed) return 1; // continue
34982
- var keys = Object.keys(configItems);
34983
- var newKeys = Object.keys(visibleOptionValuesOfArticles[_i2]);
35254
+ var keys = Array.from(configItems.keys());
35255
+ var newKeys = Array.from(visibleOptionValuesOfArticles[_i2].keys());
34984
35256
  var opvsOnlyInA = keys.filter(function (x) {
34985
35257
  return !newKeys.includes(x);
34986
35258
  });
@@ -34989,9 +35261,11 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34989
35261
  });
34990
35262
  if (opvsOnlyInA.length && opvsOnlyInB.length) {
34991
35263
  var _loop5 = function _loop5() {
34992
- var opva = configItems[opvsOnlyInA[j]];
35264
+ var opva = configItems.get(opvsOnlyInA[j]);
35265
+ if (!opva) return 1; // continue
34993
35266
  var sameOPVExists = opvsOnlyInB.find(function (opvb) {
34994
- return opva.sameopv && opva.sameopv == visibleOptionValuesOfArticles[_i2][opvb].sameopv;
35267
+ var _visibleOptionValuesO;
35268
+ return opva.sameopv && opva.sameopv == ((_visibleOptionValuesO = visibleOptionValuesOfArticles[_i2].get(opvb)) === null || _visibleOptionValuesO === void 0 ? void 0 : _visibleOptionValuesO.sameopv);
34995
35269
  });
34996
35270
  if (sameOPVExists) {
34997
35271
  opvsOnlyInA.splice(j, 1);
@@ -34999,14 +35273,15 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
34999
35273
  }
35000
35274
  };
35001
35275
  for (var j = opvsOnlyInA.length - 1; j >= 0; j--) {
35002
- _loop5();
35276
+ if (_loop5()) continue;
35003
35277
  }
35004
35278
  } else if (opvsOnlyInA.length) {
35005
35279
  var _loop6 = function _loop6() {
35006
- var opva = configItems[opvsOnlyInA[_j]];
35280
+ var opva = configItems.get(opvsOnlyInA[_j]);
35007
35281
  if (!opva) return 1; // continue
35008
35282
  var sameOPVExists = newKeys.find(function (opvb) {
35009
- return opva.sameopv && opva.sameopv == visibleOptionValuesOfArticles[_i2][opvb].sameopv;
35283
+ var _visibleOptionValuesO2;
35284
+ return opva.sameopv && opva.sameopv == ((_visibleOptionValuesO2 = visibleOptionValuesOfArticles[_i2].get(opvb)) === null || _visibleOptionValuesO2 === void 0 ? void 0 : _visibleOptionValuesO2.sameopv);
35010
35285
  });
35011
35286
  if (sameOPVExists) {
35012
35287
  opvsOnlyInA.splice(_j, 1);
@@ -35017,10 +35292,11 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35017
35292
  }
35018
35293
  } else if (opvsOnlyInB.length) {
35019
35294
  var _loop7 = function _loop7() {
35020
- var opva = configItems[opvsOnlyInB[_j2]];
35295
+ var opva = configItems.get(opvsOnlyInB[_j2]);
35021
35296
  if (!opva) return 1; // continue
35022
35297
  var sameOPVExists = keys.find(function (opvb) {
35023
- return opva.sameopv && opva.sameopv == visibleOptionValuesOfArticles[_i2][opvb].sameopv;
35298
+ var _visibleOptionValuesO3;
35299
+ return opva.sameopv && opva.sameopv == ((_visibleOptionValuesO3 = visibleOptionValuesOfArticles[_i2].get(opvb)) === null || _visibleOptionValuesO3 === void 0 ? void 0 : _visibleOptionValuesO3.sameopv);
35024
35300
  });
35025
35301
  if (sameOPVExists) {
35026
35302
  opvsOnlyInB.splice(_j2, 1);
@@ -35065,11 +35341,11 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35065
35341
  ret = false;
35066
35342
  var articles = set.getDivaArticles();
35067
35343
  for (var basketId in articles) {
35068
- var _iterator2 = _createForOfIteratorHelper$2(articles[basketId].articleOptionStates),
35069
- _step2;
35344
+ var _iterator5 = _createForOfIteratorHelper$2(articles[basketId].articleOptionStates.values()),
35345
+ _step5;
35070
35346
  try {
35071
- for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
35072
- var ops = _step2.value;
35347
+ for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
35348
+ var ops = _step5.value;
35073
35349
  if (ops.headerPosVariationType == 'K') {
35074
35350
  if (optionValues[ops.optionCodex] == undefined) {
35075
35351
  optionValues[ops.optionCodex] = ops.valCodex ? ops.valCodex : null;
@@ -35082,9 +35358,9 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35082
35358
  }
35083
35359
  }
35084
35360
  } catch (err) {
35085
- _iterator2.e(err);
35361
+ _iterator5.e(err);
35086
35362
  } finally {
35087
- _iterator2.f();
35363
+ _iterator5.f();
35088
35364
  }
35089
35365
  if (ret == true) break;
35090
35366
  }
@@ -35096,16 +35372,17 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35096
35372
  //bei einer OPG wird hier dessen hauptoptionCodex Übergeben
35097
35373
  idmOpgGroupName, idmOpgValCodex, idmOpgOptionCodex, freeTextValue, freeTextLang) {
35098
35374
  var myConfigItemsForView = [];
35099
- var objectKeys = Object.keys(myConfigItems);
35100
- var groupContentItemIdObject = this.getGroupContentItemIdObject(Object.values(myConfigItems), idmOpgGroupName);
35375
+ var objectKeys = Array.from(myConfigItems.keys());
35376
+ var groupContentItemIdObject = this.getGroupContentItemIdObject(Array.from(myConfigItems.values()), idmOpgGroupName);
35101
35377
  var _loop8 = function _loop8() {
35102
35378
  var _ops$optionOcd3, _item$images, _item$colorGroups, _item$pdfUrl, _item$url;
35103
- var item = myConfigItems[objectKeys[i]];
35379
+ var item = myConfigItems.get(objectKeys[i]);
35380
+ if (!item) throw new Error('item ' + objectKeys[i] + ' not found in myConfigItems');
35104
35381
  var key = objectKeys[i];
35105
35382
  var groupName = item.groupName ? item.groupName : idmOpgGroupName;
35106
35383
  if (!selectedVals.find(function (opv) {
35107
- var _myConfigItems$opv, _myConfigItems$opv2;
35108
- return opv == item.codex || ((_myConfigItems$opv = myConfigItems[opv]) === null || _myConfigItems$opv === void 0 ? void 0 : _myConfigItems$opv.ocd) && ((_myConfigItems$opv2 = myConfigItems[opv]) === null || _myConfigItems$opv2 === void 0 ? void 0 : _myConfigItems$opv2.ocd) === item.codex;
35384
+ var _myConfigItems$get, _myConfigItems$get2;
35385
+ 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;
35109
35386
  }) && (ops.definedBySetFeatureFixed || item.hiddenByMask)) return 1; // continue
35110
35387
  var image = item.image ? set.CatalogData.getCatImageURL(item.image, '_gal') : '';
35111
35388
  var zoomImage = undefined;
@@ -35113,8 +35390,9 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35113
35390
  zoomImage = image;
35114
35391
  image = set.CatalogData.getCatImageURL(item.zoomImage, '_gal');
35115
35392
  }
35116
- if (ops.visibleOPVsImages[item.codex]) {
35117
- image = ops.visibleOPVsImages[item.codex];
35393
+ var imageFromVisibleOPVsImages = ops.visibleOPVsImages.get(item.codex);
35394
+ if (imageFromVisibleOPVsImages) {
35395
+ image = imageFromVisibleOPVsImages;
35118
35396
  }
35119
35397
  var isFav = favoritesHandlerInstance.isFavorite(set, targetArticles, item, (_ops$optionOcd3 = ops.optionOcd) !== null && _ops$optionOcd3 !== void 0 ? _ops$optionOcd3 : optionCodex);
35120
35398
  var isSelected = !!selectedVals.find(function (opv) {
@@ -35203,12 +35481,12 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35203
35481
  for (var iKey in optionStatesOfArticles) {
35204
35482
  //hier evtl. die Article mit einer gewissen reihenfolge durchlaufen!
35205
35483
  var optionsStates = optionStatesOfArticles[iKey];
35206
- var _iterator3 = _createForOfIteratorHelper$2(optionsStates),
35207
- _step3;
35484
+ var _iterator6 = _createForOfIteratorHelper$2(optionsStates.values()),
35485
+ _step6;
35208
35486
  try {
35209
- for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
35487
+ for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
35210
35488
  var _ops$addToMeasure2;
35211
- var ops = _step3.value;
35489
+ var ops = _step6.value;
35212
35490
  var selectionmode = ops.selectionmode;
35213
35491
  if (set.CatalogData.forceConfigSingle && (selectionmode == 1 || selectionmode == 2)) selectionmode = 3;
35214
35492
  if (ops.isInvisible || selectionmode == 0 || !ops.isDoShow || ops.visibleCount == 0 || !!((_ops$addToMeasure2 = ops.addToMeasure) !== null && _ops$addToMeasure2 !== void 0 && _ops$addToMeasure2.length)) {
@@ -35216,9 +35494,9 @@ var DivaConfigTreeHandler = /*#__PURE__*/function () {
35216
35494
  }
35217
35495
  }
35218
35496
  } catch (err) {
35219
- _iterator3.e(err);
35497
+ _iterator6.e(err);
35220
35498
  } finally {
35221
- _iterator3.f();
35499
+ _iterator6.f();
35222
35500
  }
35223
35501
  }
35224
35502
  return configTree;
@@ -39339,7 +39617,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
39339
39617
  var article = set.getDivaArticles()[Object.keys(set.getDivaArticles())[0]];
39340
39618
  var opsKeys = article.articleOptionStatesKeys;
39341
39619
  var sapCount = 0;
39342
- var _iterator = _createForOfIteratorHelper$1(article.articleOptionStates),
39620
+ var _iterator = _createForOfIteratorHelper$1(article.articleOptionStates.values()),
39343
39621
  _step;
39344
39622
  try {
39345
39623
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
@@ -39463,7 +39741,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
39463
39741
  break;
39464
39742
  case 3:
39465
39743
  _context12.next = 5;
39466
- return Promise.resolve().then(function () { return require('./PfisterWWSHandler-4058e465.js'); });
39744
+ return Promise.resolve().then(function () { return require('./PfisterWWSHandler-e44293f5.js'); });
39467
39745
  case 5:
39468
39746
  _yield$import = _context12.sent;
39469
39747
  PfisterWWSHandler = _yield$import["default"];
@@ -39471,7 +39749,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
39471
39749
  return _context12.abrupt("break", 27);
39472
39750
  case 9:
39473
39751
  _context12.next = 11;
39474
- return Promise.resolve().then(function () { return require('./LiviqueWWSHandler-17894cd1.js'); });
39752
+ return Promise.resolve().then(function () { return require('./LiviqueWWSHandler-47a27ec7.js'); });
39475
39753
  case 11:
39476
39754
  _yield$import2 = _context12.sent;
39477
39755
  LiviqueWWSHandler = _yield$import2["default"];
@@ -39479,7 +39757,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
39479
39757
  return _context12.abrupt("break", 27);
39480
39758
  case 15:
39481
39759
  _context12.next = 17;
39482
- return Promise.resolve().then(function () { return require('./SeriousBasketHandler-c8e698e9.js'); });
39760
+ return Promise.resolve().then(function () { return require('./SeriousBasketHandler-6934e260.js'); });
39483
39761
  case 17:
39484
39762
  _yield$import3 = _context12.sent;
39485
39763
  SeriousWWSHandler = _yield$import3["default"];
@@ -39487,7 +39765,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
39487
39765
  return _context12.abrupt("break", 27);
39488
39766
  case 21:
39489
39767
  _context12.next = 23;
39490
- return Promise.resolve().then(function () { return require('./StandardWWSHandler-faeb77e7.js'); });
39768
+ return Promise.resolve().then(function () { return require('./StandardWWSHandler-5dd8d94a.js'); });
39491
39769
  case 23:
39492
39770
  _yield$import4 = _context12.sent;
39493
39771
  StandardWWSHandler = _yield$import4["default"];
@@ -40916,7 +41194,7 @@ var PlannerHandler3D = /*#__PURE__*/function () {
40916
41194
  while (1) switch (_context3.prev = _context3.next) {
40917
41195
  case 0:
40918
41196
  _context3.next = 2;
40919
- return Promise.resolve().then(function () { return require('./Host3DSignalR-eea7d1d4.js'); });
41197
+ return Promise.resolve().then(function () { return require('./Host3DSignalR-57e23024.js'); });
40920
41198
  case 2:
40921
41199
  _yield$import = _context3.sent;
40922
41200
  Host3DSignalR = _yield$import["default"];
@@ -42474,7 +42752,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
42474
42752
  break;
42475
42753
  case 8:
42476
42754
  _context4.next = 10;
42477
- return Promise.resolve().then(function () { return require('./DivaStandardPlanner-e6e39978.js'); });
42755
+ return Promise.resolve().then(function () { return require('./DivaStandardPlanner-77476193.js'); });
42478
42756
  case 10:
42479
42757
  _yield$import = _context4.sent;
42480
42758
  DivaStandardPlanner = _yield$import["default"];
@@ -42485,7 +42763,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
42485
42763
  return _context4.abrupt("break", 21);
42486
42764
  case 15:
42487
42765
  _context4.next = 17;
42488
- return Promise.resolve().then(function () { return require('./DivaBoxPlanner-1364c551.js'); });
42766
+ return Promise.resolve().then(function () { return require('./DivaBoxPlanner-04bf6318.js'); });
42489
42767
  case 17:
42490
42768
  _yield$import2 = _context4.sent;
42491
42769
  DivaBoxPlanner = _yield$import2["default"];
@@ -47626,7 +47904,7 @@ var Grid = /*#__PURE__*/function () {
47626
47904
  _context4.next = 18;
47627
47905
  break;
47628
47906
  }
47629
- if (montageOptionState) montageOptionState.val = montageOptionState.visibleOptionValues[mitCodex];
47907
+ if (montageOptionState) montageOptionState.val = montageOptionState.visibleOptionValues.get(mitCodex);
47630
47908
  _context4.next = 15;
47631
47909
  return _this.updateAccessoireMontageOption((!isIDM ? 'OPT' : '') + optionCodex, mitCodex, specificAccessoire);
47632
47910
  case 15:
@@ -47634,7 +47912,7 @@ var Grid = /*#__PURE__*/function () {
47634
47912
  _context4.next = 21;
47635
47913
  break;
47636
47914
  case 18:
47637
- if (montageOptionState) montageOptionState.val = montageOptionState.visibleOptionValues[ohneCodex];
47915
+ if (montageOptionState) montageOptionState.val = montageOptionState.visibleOptionValues.get(ohneCodex);
47638
47916
  _context4.next = 21;
47639
47917
  return _this.updateAccessoireMontageOption((!isIDM ? 'OPT' : '') + optionCodex, ohneCodex, []);
47640
47918
  case 21:
@@ -63782,6 +64060,7 @@ var a$5 = {
63782
64060
  },
63783
64061
  settings: {
63784
64062
  dontLoadAdditionalModelInfos: true,
64063
+ dontLoadCatalogEditorLiteMask: true,
63785
64064
  identifier: 'PfisterWebPlanner',
63786
64065
  type: 'DIVA_WEBPLANNER',
63787
64066
  configParams: {
@@ -63852,6 +64131,7 @@ var a$4 = {
63852
64131
  },
63853
64132
  settings: {
63854
64133
  dontLoadAdditionalModelInfos: true,
64134
+ dontLoadCatalogEditorLiteMask: true,
63855
64135
  identifier: 'Seller',
63856
64136
  type: 'DIVA_WEBPLANNER',
63857
64137
  configParams: {
@@ -63911,6 +64191,7 @@ var a$3 = {
63911
64191
  },
63912
64192
  settings: {
63913
64193
  dontLoadAdditionalModelInfos: true,
64194
+ dontLoadCatalogEditorLiteMask: true,
63914
64195
  configParams: {
63915
64196
  mediaServiceApiKey: '620e074df81de00012ef47ed.wUyoXTbh4tR3DklrzvvdxFveVK9zcj4H',
63916
64197
  // api2devKey: '627b71be68f4c30011dd25e2.I2RdwvdHG4gruMNr6l810tTU5x7afNMm',