@crystaldesign/web-planner-logic 24.11.0-beta.38 → 24.11.0-beta.39

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 (56) hide show
  1. package/build/cjs/{DivaBoxPlanner-330653bb.js → DivaBoxPlanner-c0491407.js} +2 -2
  2. package/build/cjs/{DivaStandardPlanner-428015e0.js → DivaStandardPlanner-3a655cd7.js} +73 -17
  3. package/build/cjs/{DoorPlanner-73c462cf.js → DoorPlanner-497f79a4.js} +1 -1
  4. package/build/cjs/{Host3DSignalR-93aafc52.js → Host3DSignalR-c8a4f342.js} +1 -1
  5. package/build/cjs/{LiviqueWWSHandler-72636128.js → LiviqueWWSHandler-9ef41a4b.js} +1 -1
  6. package/build/cjs/{PfisterWWSHandler-0b867d64.js → PfisterWWSHandler-3832b3db.js} +1 -1
  7. package/build/cjs/{PlannerHandler2D-80167e97.js → PlannerHandler2D-49ee318c.js} +26 -2
  8. package/build/cjs/{ProductBasketHandler-7b9f5bd9.js → ProductBasketHandler-bf3f28a6.js} +1 -1
  9. package/build/cjs/{SeriousBasketHandler-0303202e.js → SeriousBasketHandler-44108127.js} +1 -1
  10. package/build/cjs/{ShelfPlanner-47bbfb7c.js → ShelfPlanner-8b2db628.js} +1 -1
  11. package/build/cjs/{StandardWWSHandler-06ae3bfc.js → StandardWWSHandler-6150a756.js} +1 -1
  12. package/build/cjs/{index-c285a3c4.js → index-4d3eb4fa.js} +365 -269
  13. package/build/cjs/index.js +1 -1
  14. package/build/esm/{DivaBoxPlanner-da028daa.js → DivaBoxPlanner-ad6509af.js} +2 -2
  15. package/build/esm/{DivaStandardPlanner-b23fcfc4.js → DivaStandardPlanner-251c5b36.js} +73 -17
  16. package/build/esm/{DoorPlanner-d53478a6.js → DoorPlanner-8063f973.js} +1 -1
  17. package/build/esm/{Host3DSignalR-de59e1ca.js → Host3DSignalR-ab1ccbea.js} +1 -1
  18. package/build/esm/{LiviqueWWSHandler-8ac2de7d.js → LiviqueWWSHandler-f13c497c.js} +1 -1
  19. package/build/esm/{PfisterWWSHandler-7e6d73a9.js → PfisterWWSHandler-cb6d8996.js} +1 -1
  20. package/build/esm/{PlannerHandler2D-d320a01d.js → PlannerHandler2D-4ed43b5f.js} +26 -2
  21. package/build/esm/{ProductBasketHandler-faa30dae.js → ProductBasketHandler-e42fb957.js} +1 -1
  22. package/build/esm/{SeriousBasketHandler-00d1471a.js → SeriousBasketHandler-bd8bacf8.js} +1 -1
  23. package/build/esm/{ShelfPlanner-747bb48e.js → ShelfPlanner-1a65509e.js} +1 -1
  24. package/build/esm/{StandardWWSHandler-33764628.js → StandardWWSHandler-51626324.js} +1 -1
  25. package/build/esm/{index-1f21b165.js → index-862cadbc.js} +365 -269
  26. package/build/esm/index.js +1 -1
  27. package/build/types/web-planner-logic/src/interface/Articles/AccessoireItemType.d.ts +2 -0
  28. package/build/types/web-planner-logic/src/interface/Articles/AccessoireItemType.d.ts.map +1 -1
  29. package/build/types/web-planner-logic/src/interface/Articles/CatalogPlannerArticleDataType.d.ts +4 -0
  30. package/build/types/web-planner-logic/src/interface/Articles/CatalogPlannerArticleDataType.d.ts.map +1 -1
  31. package/build/types/web-planner-logic/src/interface/Articles/CatalogPlannerArticleViewDataType.d.ts +2 -0
  32. package/build/types/web-planner-logic/src/interface/Articles/CatalogPlannerArticleViewDataType.d.ts.map +1 -1
  33. package/build/types/web-planner-logic/src/interface/Planner/DockingPointDataType.d.ts +1 -1
  34. package/build/types/web-planner-logic/src/interface/Planner/DockingPointDataType.d.ts.map +1 -1
  35. package/build/types/web-planner-logic/src/interface/Planner/IDivaViewPlannerElement.d.ts +2 -0
  36. package/build/types/web-planner-logic/src/interface/Planner/IDivaViewPlannerElement.d.ts.map +1 -1
  37. package/build/types/web-planner-logic/src/interface/Planner/PlannerDataType.d.ts +2 -0
  38. package/build/types/web-planner-logic/src/interface/Planner/PlannerDataType.d.ts.map +1 -1
  39. package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts.map +1 -1
  40. package/build/types/web-planner-logic/src/logic/Article/DivaArticleHandler.d.ts +10 -0
  41. package/build/types/web-planner-logic/src/logic/Article/DivaArticleHandler.d.ts.map +1 -1
  42. package/build/types/web-planner-logic/src/logic/DivaCatalogHandler.d.ts.map +1 -1
  43. package/build/types/web-planner-logic/src/logic/Planner/DivaPlannerHandler.d.ts.map +1 -1
  44. package/build/types/web-planner-logic/src/logic/Planner/DivaStandardPlanner.d.ts +1 -1
  45. package/build/types/web-planner-logic/src/logic/Planner/DivaStandardPlanner.d.ts.map +1 -1
  46. package/build/types/web-planner-logic/src/logic/Planner/PlannerUtils/DockingPointHandler.d.ts.map +1 -1
  47. package/build/types/web-planner-logic/src/logic/Planner/Rendering/PlannerHandler3D.d.ts.map +1 -1
  48. package/build/types/web-planner-logic/src/logic/Planner/Rendering/Rendering.d.ts +6 -0
  49. package/build/types/web-planner-logic/src/logic/Planner/Rendering/Rendering.d.ts.map +1 -1
  50. package/build/types/web-planner-logic/src/model/Articles/CatalogArticleData.d.ts.map +1 -1
  51. package/build/types/web-planner-logic/src/model/Articles/CatalogPlannerArticleData.d.ts +2 -0
  52. package/build/types/web-planner-logic/src/model/Articles/CatalogPlannerArticleData.d.ts.map +1 -1
  53. package/build/types/web-planner-logic/src/model/DivaCatalogData.d.ts.map +1 -1
  54. package/build/types/web-planner-logic/src/model/Planner/PlannerElementData.d.ts +4 -0
  55. package/build/types/web-planner-logic/src/model/Planner/PlannerElementData.d.ts.map +1 -1
  56. package/package.json +2 -2
@@ -17088,7 +17088,7 @@ var CatalogArticleData = /*#__PURE__*/function () {
17088
17088
  if (articleRelations[0].Articles.length > 0) {
17089
17089
  this.catalogArticle.hasArticleRelations = true;
17090
17090
  for (var i = 0; i < articleRelations[0].Articles.length; i++) {
17091
- var _catalogArticle$catal, _catalogArticle$catal2, _catalogArticle$catal3, _catalogArticle$catal4, _catalogArticle$catal5, _catalogArticle$catal6;
17091
+ var _catalogArticle$catal, _catalogArticle$catal2, _catalogArticle$catal3, _catalogArticle$catal4, _catalogArticle$catal5, _catalogArticle$catal6, _catalogArticle$catal7, _catalogArticle$catal8, _catalogArticle$catal9, _catalogArticle$catal10;
17092
17092
  var myAcc = articleRelations[0].Articles[i];
17093
17093
  if (this.catalogCodex != myAcc.CatalogCodex) {
17094
17094
  //DivaUtils.LOG.log("Accessoire ist von einem anderen Catalog. Sollte eig funktionern aber bitte testen!");
@@ -17113,6 +17113,8 @@ var CatalogArticleData = /*#__PURE__*/function () {
17113
17113
  hasAVC: ((_catalogArticle$catal = (_catalogArticle$catal2 = catalogArticle.catalogPlannerArticle) === null || _catalogArticle$catal2 === void 0 ? void 0 : _catalogArticle$catal2.topAVC) !== null && _catalogArticle$catal !== void 0 ? _catalogArticle$catal : 0) > 0,
17114
17114
  hasAVO: ((_catalogArticle$catal3 = (_catalogArticle$catal4 = catalogArticle.catalogPlannerArticle) === null || _catalogArticle$catal4 === void 0 ? void 0 : _catalogArticle$catal4.topAVO) !== null && _catalogArticle$catal3 !== void 0 ? _catalogArticle$catal3 : 0) > 0,
17115
17115
  hasAVU: ((_catalogArticle$catal5 = (_catalogArticle$catal6 = catalogArticle.catalogPlannerArticle) === null || _catalogArticle$catal6 === void 0 ? void 0 : _catalogArticle$catal6.topAVU) !== null && _catalogArticle$catal5 !== void 0 ? _catalogArticle$catal5 : 0) > 0,
17116
+ hasAVN: ((_catalogArticle$catal7 = (_catalogArticle$catal8 = catalogArticle.catalogPlannerArticle) === null || _catalogArticle$catal8 === void 0 ? void 0 : _catalogArticle$catal8.topAVN) !== null && _catalogArticle$catal7 !== void 0 ? _catalogArticle$catal7 : 0) > 0,
17117
+ hasAVS: ((_catalogArticle$catal9 = (_catalogArticle$catal10 = catalogArticle.catalogPlannerArticle) === null || _catalogArticle$catal10 === void 0 ? void 0 : _catalogArticle$catal10.topAVS) !== null && _catalogArticle$catal9 !== void 0 ? _catalogArticle$catal9 : 0) > 0,
17116
17118
  width: catalogArticle.width,
17117
17119
  height: catalogArticle.height,
17118
17120
  depth: catalogArticle.depth,
@@ -17559,6 +17561,8 @@ var CatalogPlannerArticleData = /*#__PURE__*/function () {
17559
17561
  topAVO: jsonArticle.TopAVO ? jsonArticle.TopAVO : -1,
17560
17562
  topAVU: jsonArticle.TopAVU ? jsonArticle.TopAVU : -1,
17561
17563
  topAVC: jsonArticle.TopAVC ? jsonArticle.TopAVC : -1,
17564
+ topAVN: jsonArticle.TopAVN ? jsonArticle.TopAVN : -1,
17565
+ topAVS: jsonArticle.TopAVS ? jsonArticle.TopAVS : -1,
17562
17566
  topIsAccessoire: jsonArticle.TopIsAccessoire != undefined ? jsonArticle.TopIsAccessoire : undefined,
17563
17567
  j3DUrl: jsonArticle.J3DUrl && jsonArticle.J3DUrl != '' ? jsonArticle.J3DUrl : undefined,
17564
17568
  isArticleRelation: jsonArticle.IsArticleRelation != undefined ? jsonArticle.IsArticleRelation : undefined,
@@ -17762,6 +17766,16 @@ var CatalogPlannerArticleData = /*#__PURE__*/function () {
17762
17766
  get: function get() {
17763
17767
  return this.catPlanArt.topAVU;
17764
17768
  }
17769
+ }, {
17770
+ key: "topAVN",
17771
+ get: function get() {
17772
+ return this.catPlanArt.topAVN;
17773
+ }
17774
+ }, {
17775
+ key: "topAVS",
17776
+ get: function get() {
17777
+ return this.catPlanArt.topAVS;
17778
+ }
17765
17779
  }, {
17766
17780
  key: "getSvgInSvgWithFormulaArr",
17767
17781
  value: function getSvgInSvgWithFormulaArr(curSVG) {
@@ -17790,9 +17804,9 @@ var CatalogPlannerArticleData = /*#__PURE__*/function () {
17790
17804
  get: function get() {
17791
17805
  if (
17792
17806
  //if the article hasTopSvg
17793
- this.hasTopSvg && (this.topAVC > 0 || this.topAVO > 0 || this.topAVU > 0 || this.topHasAVL || this.topHasAVR) ||
17807
+ this.hasTopSvg && (this.topAVC > 0 || this.topAVO > 0 || this.topAVU > 0 || this.topAVN > 0 || this.topAVS > 0 || this.topHasAVL || this.topHasAVR) ||
17794
17808
  //if the article hasTopSvgsWithFormula (more svgs). All svgs have to have the same dp
17795
- this.hasTopSvgsWithFormula && this.topSvgsWithFormula.length > 0 && (this.topSvgsWithFormula[0].AVC > 0 || this.topSvgsWithFormula[0].AVO > 0 || this.topSvgsWithFormula[0].AVU > 0 || this.topSvgsWithFormula[0].HasAVL || this.topSvgsWithFormula[0].HasAVR)) {
17809
+ this.hasTopSvgsWithFormula && this.topSvgsWithFormula.length > 0 && (this.topSvgsWithFormula[0].AVC > 0 || this.topSvgsWithFormula[0].AVO > 0 || this.topSvgsWithFormula[0].AVU > 0 || this.topSvgsWithFormula[0].AVN > 0 || this.topSvgsWithFormula[0].AVS > 0 || this.topSvgsWithFormula[0].HasAVL || this.topSvgsWithFormula[0].HasAVR)) {
17796
17810
  return true;
17797
17811
  }
17798
17812
  return false;
@@ -18790,6 +18804,8 @@ var DivaCatalogData = /*#__PURE__*/function () {
18790
18804
  hasAVC: topSvg.TopAVC && topSvg.TopAVC > 0 || topSvg.AVC && topSvg.AVC > 0 ? true : false,
18791
18805
  hasAVO: topSvg.TopAVO && topSvg.TopAVO > 0 || topSvg.AVO && topSvg.AVO > 0 ? true : false,
18792
18806
  hasAVU: topSvg.TopAVU && topSvg.TopAVU > 0 || topSvg.AVU && topSvg.AVU > 0 ? true : false,
18807
+ hasAVN: topSvg.TopAVN && topSvg.TopAVN > 0 || topSvg.AVN && topSvg.AVN > 0 ? true : false,
18808
+ hasAVS: topSvg.TopAVS && topSvg.TopAVS > 0 || topSvg.AVS && topSvg.AVS > 0 ? true : false,
18793
18809
  hasAVR: topSvg.HasAVR ? true : false,
18794
18810
  hasAVL: topSvg.HasAVL ? true : false,
18795
18811
  jsonFormula: topSvg.JsFormula,
@@ -18846,6 +18862,8 @@ var DivaCatalogData = /*#__PURE__*/function () {
18846
18862
  hasAVC: catPlanArticle.topAVC && catPlanArticle.topAVC > 0 ? true : false,
18847
18863
  hasAVO: catPlanArticle.topAVO && catPlanArticle.topAVO > 0 ? true : false,
18848
18864
  hasAVU: catPlanArticle.topAVU && catPlanArticle.topAVU > 0 ? true : false,
18865
+ hasAVN: catPlanArticle.topAVN && catPlanArticle.topAVN > 0 ? true : false,
18866
+ hasAVS: catPlanArticle.topAVS && catPlanArticle.topAVS > 0 ? true : false,
18849
18867
  hasAVR: hasAVR,
18850
18868
  hasAVL: hasAVL,
18851
18869
  layer: catPlanArticle.topLayer ? Number(catPlanArticle.topLayer) : 20,
@@ -20492,6 +20510,8 @@ var DivaArticle = /*#__PURE__*/function () {
20492
20510
  countAVC: -1,
20493
20511
  countAVO: -1,
20494
20512
  countAVU: -1,
20513
+ countAVN: -1,
20514
+ countAVS: -1,
20495
20515
  hasAVL: false,
20496
20516
  hasAVR: false,
20497
20517
  isAccessoire: false,
@@ -20521,6 +20541,8 @@ var DivaArticle = /*#__PURE__*/function () {
20521
20541
  this.actPlannerData.countAVC = plannerElement.topAVC;
20522
20542
  this.actPlannerData.countAVO = plannerElement.topAVO;
20523
20543
  this.actPlannerData.countAVU = plannerElement.topAVU;
20544
+ this.actPlannerData.countAVN = plannerElement.topAVN;
20545
+ this.actPlannerData.countAVS = plannerElement.topAVS;
20524
20546
  }
20525
20547
  this.actPlannerData.accessoireList = this.accessoireList;
20526
20548
  this.actPlannerData.svgsWithFormula = plannerElement.topSvgsWithFormula;
@@ -21548,6 +21570,8 @@ var DivaArticle = /*#__PURE__*/function () {
21548
21570
  this.actPlannerData.countAVC = this.article.catalogArticle.catalogPlannerArticle.topAVC;
21549
21571
  this.actPlannerData.countAVO = this.article.catalogArticle.catalogPlannerArticle.topAVO;
21550
21572
  this.actPlannerData.countAVU = this.article.catalogArticle.catalogPlannerArticle.topAVU;
21573
+ this.actPlannerData.countAVN = this.article.catalogArticle.catalogPlannerArticle.topAVN;
21574
+ this.actPlannerData.countAVS = this.article.catalogArticle.catalogPlannerArticle.topAVS;
21551
21575
  this.actPlannerData.isAccessoire = !this.isPartListArticle && this.article.relatedToBasketId != undefined;
21552
21576
  }
21553
21577
  }, {
@@ -22339,8 +22363,9 @@ var DivaArticle = /*#__PURE__*/function () {
22339
22363
  ops.freeTextLang['FR'] = langs[1];
22340
22364
  ops.freeTextLang['IT'] = langs[2];
22341
22365
  } else {
22366
+ var _freeTextValues$optio;
22342
22367
  var doSetValue = newConfigValues[optionCodex + '_val'] === undefined;
22343
- if (!doSetValue && !freeTextValues[optionCodex].exactMatchingKey && key === partenOptionCodex + '.' + optionCodex) doSetValue = true;
22368
+ if (!doSetValue && !((_freeTextValues$optio = freeTextValues[optionCodex]) !== null && _freeTextValues$optio !== void 0 && _freeTextValues$optio.exactMatchingKey) && key === partenOptionCodex + '.' + optionCodex) doSetValue = true;
22344
22369
  if (!doSetValue) return;
22345
22370
  freeTextValues[optionCodex] = {
22346
22371
  exactMatchingKey: key === partenOptionCodex + '.' + optionCodex
@@ -23538,7 +23563,7 @@ var DivaArticle = /*#__PURE__*/function () {
23538
23563
  break;
23539
23564
  }
23540
23565
  _context.next = 4;
23541
- return Promise.resolve().then(function () { return require('./ShelfPlanner-47bbfb7c.js'); });
23566
+ return Promise.resolve().then(function () { return require('./ShelfPlanner-8b2db628.js'); });
23542
23567
  case 4:
23543
23568
  _yield$import = _context.sent;
23544
23569
  ShelfPlanner = _yield$import["default"];
@@ -24082,6 +24107,8 @@ var DivaArticle = /*#__PURE__*/function () {
24082
24107
  this.actPlannerData.countAVC = mySVG.AVC;
24083
24108
  this.actPlannerData.countAVO = mySVG.AVO;
24084
24109
  this.actPlannerData.countAVU = mySVG.AVU;
24110
+ this.actPlannerData.countAVN = mySVG.AVN;
24111
+ this.actPlannerData.countAVS = mySVG.AVS;
24085
24112
  this.actPlannerData.hasAVL = mySVG.HasAVL;
24086
24113
  this.actPlannerData.hasAVR = mySVG.HasAVR;
24087
24114
  LOG$c.debug('new SVG by SVG tausch', {
@@ -24091,6 +24118,8 @@ var DivaArticle = /*#__PURE__*/function () {
24091
24118
  AVC: mySVG.AVC,
24092
24119
  AVO: mySVG.AVO,
24093
24120
  AVU: mySVG.AVU,
24121
+ AVN: mySVG.AVN,
24122
+ AVS: mySVG.AVS,
24094
24123
  HasAVL: mySVG.HasAVL,
24095
24124
  HasAVR: mySVG.HasAVR
24096
24125
  });
@@ -24489,24 +24518,68 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24489
24518
  value: //Initialisiert eventuell Option Tree und Infos im CatalogArticle
24490
24519
  function () {
24491
24520
  var _loadArticle = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee(set, articleCodex, initParams) {
24492
- var catalog, _set$getSetState$acti, _set$getSetState$acti2, _set$getSetState$acti3, _set$getSetState$acti4, catalogArticle, newBasketId, _set$actions;
24521
+ var _yield$this$preLoadAr, catalog, catalogArticle, newBasketId, _set$actions;
24493
24522
  return _regeneratorRuntime__default["default"].wrap(function _callee$(_context) {
24494
24523
  while (1) switch (_context.prev = _context.next) {
24524
+ case 0:
24525
+ _context.next = 2;
24526
+ return this.preLoadArticle(set, articleCodex, initParams);
24527
+ case 2:
24528
+ _yield$this$preLoadAr = _context.sent;
24529
+ catalog = _yield$this$preLoadAr.catalog;
24530
+ catalogArticle = _yield$this$preLoadAr.catalogArticle;
24531
+ newBasketId = initParams.basketId ? initParams.basketId : 'B' + DivaUtils.nanoid();
24532
+ if (!catalogArticle) {
24533
+ _context.next = 10;
24534
+ break;
24535
+ }
24536
+ return _context.abrupt("return", new DivaArticle(set, newBasketId, initParams, catalogArticle, catalog));
24537
+ case 10:
24538
+ //articleCodex does not exist anymore in catalog
24539
+ LOG$b.error(new DivaUtils.DivaError('articleCodex not found in article list. Could be due to exclusivity or a bug in the application!', {
24540
+ code: 'WC_0011',
24541
+ custom: {
24542
+ articleCodex: articleCodex
24543
+ }
24544
+ }));
24545
+ (_set$actions = set.actions) === null || _set$actions === void 0 || _set$actions.openModal({
24546
+ accept: true,
24547
+ title: set.i18n.t('modals.error_accured')
24548
+ });
24549
+ return _context.abrupt("return", false);
24550
+ case 13:
24551
+ case "end":
24552
+ return _context.stop();
24553
+ }
24554
+ }, _callee, this);
24555
+ }));
24556
+ function loadArticle(_x, _x2, _x3) {
24557
+ return _loadArticle.apply(this, arguments);
24558
+ }
24559
+ return loadArticle;
24560
+ }() //loads all the calls for an article but does not create the article
24561
+ }, {
24562
+ key: "preLoadArticle",
24563
+ value: function () {
24564
+ var _preLoadArticle = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee2(set, articleCodex, initParams) {
24565
+ var catalog, _set$getSetState$acti, _set$getSetState$acti2, _set$getSetState$acti3, _set$getSetState$acti4, catalogArticle;
24566
+ return _regeneratorRuntime__default["default"].wrap(function _callee2$(_context2) {
24567
+ while (1) switch (_context2.prev = _context2.next) {
24495
24568
  case 0:
24496
24569
  if (!(initParams.catalogCodex && initParams.catalogCodex !== set.CatalogData.catalogCodex)) {
24497
- _context.next = 8;
24570
+ _context2.next = 8;
24498
24571
  break;
24499
24572
  }
24500
24573
  (_set$getSetState$acti = set.getSetState.actions) === null || _set$getSetState$acti === void 0 || (_set$getSetState$acti2 = _set$getSetState$acti.toggleLoading) === null || _set$getSetState$acti2 === void 0 || _set$getSetState$acti2.call(_set$getSetState$acti, 'loadingCatalog' + initParams.catalogCodex, false, true);
24501
- _context.next = 4;
24574
+ _context2.next = 4;
24502
24575
  return catalogHandlerInstance.getCatalogData(set.getSetState, initParams.catalogCodex, {
24503
24576
  AccountGUID: set.CatalogData.accountGuid,
24504
24577
  AccountSessionGUID: set.CatalogData.accountSessionGuid
24505
24578
  });
24506
24579
  case 4:
24507
- catalog = _context.sent;
24580
+ catalog = _context2.sent;
24508
24581
  (_set$getSetState$acti3 = set.getSetState.actions) === null || _set$getSetState$acti3 === void 0 || (_set$getSetState$acti4 = _set$getSetState$acti3.toggleLoading) === null || _set$getSetState$acti4 === void 0 || _set$getSetState$acti4.call(_set$getSetState$acti3, 'loadingCatalog' + initParams.catalogCodex, false, false);
24509
- _context.next = 9;
24582
+ _context2.next = 9;
24510
24583
  break;
24511
24584
  case 8:
24512
24585
  catalog = set.CatalogData;
@@ -24515,68 +24588,62 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24515
24588
  //usecase der selbe Article wurde bereits verplant. nun kann die bereits geladene & verwendete Klasse catalogArticle wiederverwendet werden da wir dort nichts
24516
24589
  //während der Konfiguration verändern!
24517
24590
  if (!catalogArticle) {
24518
- _context.next = 18;
24591
+ _context2.next = 17;
24519
24592
  break;
24520
24593
  }
24521
24594
  if (!catalogArticle.areOptionsToLoad) {
24522
- _context.next = 14;
24595
+ _context2.next = 14;
24523
24596
  break;
24524
24597
  }
24525
- _context.next = 14;
24598
+ _context2.next = 14;
24526
24599
  return this.loadArticleData(set, catalogArticle, catalog);
24527
24600
  case 14:
24528
- newBasketId = initParams.basketId ? initParams.basketId : 'B' + DivaUtils.nanoid();
24529
- return _context.abrupt("return", new DivaArticle(set, newBasketId, initParams, catalogArticle, catalog));
24530
- case 18:
24531
- //articleCodex does not exist anymore in catalog
24532
- LOG$b.error(new DivaUtils.DivaError('articleCodex not found in article list. Could be due to exclusivity or a bug in the application!', {
24533
- code: 'WC_0011',
24534
- custom: {
24535
- articleCodex: articleCodex
24536
- }
24537
- }));
24538
- (_set$actions = set.actions) === null || _set$actions === void 0 || _set$actions.openModal({
24539
- accept: true,
24540
- title: set.i18n.t('modals.error_accured')
24601
+ return _context2.abrupt("return", {
24602
+ catalog: catalog,
24603
+ catalogArticle: catalogArticle
24541
24604
  });
24542
- return _context.abrupt("return", false);
24543
- case 21:
24605
+ case 17:
24606
+ return _context2.abrupt("return", {
24607
+ catalog: catalog,
24608
+ catalogArticle: catalogArticle
24609
+ });
24610
+ case 18:
24544
24611
  case "end":
24545
- return _context.stop();
24612
+ return _context2.stop();
24546
24613
  }
24547
- }, _callee, this);
24614
+ }, _callee2, this);
24548
24615
  }));
24549
- function loadArticle(_x, _x2, _x3) {
24550
- return _loadArticle.apply(this, arguments);
24616
+ function preLoadArticle(_x4, _x5, _x6) {
24617
+ return _preLoadArticle.apply(this, arguments);
24551
24618
  }
24552
- return loadArticle;
24619
+ return preLoadArticle;
24553
24620
  }()
24554
24621
  }, {
24555
24622
  key: "loadArticleData",
24556
24623
  value: function () {
24557
- var _loadArticleData = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee2(set, catalogArticle, catalog) {
24624
+ var _loadArticleData = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee3(set, catalogArticle, catalog) {
24558
24625
  var catalogCodex, promises, _yield$Promise$all, _yield$Promise$all2, jsonPrices, jsonOption;
24559
- return _regeneratorRuntime__default["default"].wrap(function _callee2$(_context2) {
24560
- while (1) switch (_context2.prev = _context2.next) {
24626
+ return _regeneratorRuntime__default["default"].wrap(function _callee3$(_context3) {
24627
+ while (1) switch (_context3.prev = _context3.next) {
24561
24628
  case 0:
24562
24629
  //ArticleRelations und J3D und Partlists bekommt man jetzt noch
24563
24630
  catalogCodex = catalog.catalogCodex;
24564
- _context2.t0 = catalogArticle;
24565
- _context2.next = 4;
24631
+ _context3.t0 = catalogArticle;
24632
+ _context3.next = 4;
24566
24633
  return set.api.getArticleJson(catalogArticle.articleCodex, catalogCodex, catalog.accountSessionGuid);
24567
24634
  case 4:
24568
- _context2.t1 = _context2.sent;
24569
- _context2.t2 = catalog;
24570
- _context2.t0.loadMoreFromArticle.call(_context2.t0, _context2.t1, _context2.t2);
24635
+ _context3.t1 = _context3.sent;
24636
+ _context3.t2 = catalog;
24637
+ _context3.t0.loadMoreFromArticle.call(_context3.t0, _context3.t1, _context3.t2);
24571
24638
  if (!catalogArticle.templateCodex) {
24572
- _context2.next = 17;
24639
+ _context3.next = 17;
24573
24640
  break;
24574
24641
  }
24575
24642
  promises = [set.api.loadArticlePricesQS(catalogArticle.articleCodex, catalogCodex, catalog.accountSessionGuid), set.api.getJsonOptionTree(catalogArticle.templateCodex, catalogCodex, catalog.accountSessionGuid)];
24576
- _context2.next = 11;
24643
+ _context3.next = 11;
24577
24644
  return Promise.all(promises);
24578
24645
  case 11:
24579
- _yield$Promise$all = _context2.sent;
24646
+ _yield$Promise$all = _context3.sent;
24580
24647
  _yield$Promise$all2 = _slicedToArray__default["default"](_yield$Promise$all, 2);
24581
24648
  jsonPrices = _yield$Promise$all2[0];
24582
24649
  jsonOption = _yield$Promise$all2[1];
@@ -24586,11 +24653,11 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24586
24653
  catalogArticle.areOptionsLoaded = true;
24587
24654
  case 18:
24588
24655
  case "end":
24589
- return _context2.stop();
24656
+ return _context3.stop();
24590
24657
  }
24591
- }, _callee2);
24658
+ }, _callee3);
24592
24659
  }));
24593
- function loadArticleData(_x4, _x5, _x6) {
24660
+ function loadArticleData(_x7, _x8, _x9) {
24594
24661
  return _loadArticleData.apply(this, arguments);
24595
24662
  }
24596
24663
  return loadArticleData;
@@ -24598,24 +24665,24 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24598
24665
  }, {
24599
24666
  key: "updateAccessoireQuantity",
24600
24667
  value: function () {
24601
- var _updateAccessoireQuantity = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee3(accessoire, newQuantity) {
24602
- return _regeneratorRuntime__default["default"].wrap(function _callee3$(_context3) {
24603
- while (1) switch (_context3.prev = _context3.next) {
24668
+ var _updateAccessoireQuantity = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee4(accessoire, newQuantity) {
24669
+ return _regeneratorRuntime__default["default"].wrap(function _callee4$(_context4) {
24670
+ while (1) switch (_context4.prev = _context4.next) {
24604
24671
  case 0:
24605
24672
  accessoire.quantity = newQuantity;
24606
24673
  if (!(accessoire.articleType == 'OPTION' || accessoire.articleType == 'OPTIONTREE')) {
24607
- _context3.next = 4;
24674
+ _context4.next = 4;
24608
24675
  break;
24609
24676
  }
24610
- _context3.next = 4;
24677
+ _context4.next = 4;
24611
24678
  return this.updateCfgValues(accessoire, {}, {});
24612
24679
  case 4:
24613
24680
  case "end":
24614
- return _context3.stop();
24681
+ return _context4.stop();
24615
24682
  }
24616
- }, _callee3, this);
24683
+ }, _callee4, this);
24617
24684
  }));
24618
- function updateAccessoireQuantity(_x7, _x8) {
24685
+ function updateAccessoireQuantity(_x10, _x11) {
24619
24686
  return _updateAccessoireQuantity.apply(this, arguments);
24620
24687
  }
24621
24688
  return updateAccessoireQuantity;
@@ -24623,33 +24690,33 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24623
24690
  }, {
24624
24691
  key: "toDoAfterArticleLoaded",
24625
24692
  value: function () {
24626
- var _toDoAfterArticleLoaded = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee4(article, defaultValues, variantValues, from, variantItems, ignorePlanner) {
24627
- return _regeneratorRuntime__default["default"].wrap(function _callee4$(_context4) {
24628
- while (1) switch (_context4.prev = _context4.next) {
24693
+ var _toDoAfterArticleLoaded = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee5(article, defaultValues, variantValues, from, variantItems, ignorePlanner) {
24694
+ return _regeneratorRuntime__default["default"].wrap(function _callee5$(_context5) {
24695
+ while (1) switch (_context5.prev = _context5.next) {
24629
24696
  case 0:
24630
24697
  if (!(article.articleType == 'OPTION' || article.articleType == 'OPTIONTREE')) {
24631
- _context4.next = 8;
24698
+ _context5.next = 8;
24632
24699
  break;
24633
24700
  }
24634
- _context4.next = 3;
24701
+ _context5.next = 3;
24635
24702
  return this.initCfgValues(article, variantValues, variantItems);
24636
24703
  case 3:
24637
- _context4.next = 5;
24704
+ _context5.next = 5;
24638
24705
  return this.updateCfgValues(article, defaultValues, variantValues);
24639
24706
  case 5:
24640
24707
  if (!(article.set.PlannerMode !== 'BoxPlanner')) {
24641
- _context4.next = 8;
24708
+ _context5.next = 8;
24642
24709
  break;
24643
24710
  }
24644
- _context4.next = 8;
24711
+ _context5.next = 8;
24645
24712
  return setHandlerInstance.updateArticlesOptionStatesOfActSet(article.set, defaultValues, [article.basketId], ignorePlanner, from);
24646
24713
  case 8:
24647
24714
  case "end":
24648
- return _context4.stop();
24715
+ return _context5.stop();
24649
24716
  }
24650
- }, _callee4, this);
24717
+ }, _callee5, this);
24651
24718
  }));
24652
- function toDoAfterArticleLoaded(_x9, _x10, _x11, _x12, _x13, _x14) {
24719
+ function toDoAfterArticleLoaded(_x12, _x13, _x14, _x15, _x16, _x17) {
24653
24720
  return _toDoAfterArticleLoaded.apply(this, arguments);
24654
24721
  }
24655
24722
  return toDoAfterArticleLoaded;
@@ -24668,11 +24735,11 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24668
24735
  }, {
24669
24736
  key: "updateArticlesOptionStates",
24670
24737
  value: function () {
24671
- var _updateArticlesOptionStates = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee5(myValues, targetArticlesWithNewValues, targetArticlesToUpdate, articles, from) {
24738
+ var _updateArticlesOptionStates = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee6(myValues, targetArticlesWithNewValues, targetArticlesToUpdate, articles, from) {
24672
24739
  var _articles$targetArtic;
24673
24740
  var newEDOExtraArticles, partlistArticlesToLoad, valuesArray, i, actArticle, newPartlistArticlesToLoad, _actArticle$checkDefa, variantValues, triggerUpdate, key, configuredArticle, toIgnore, _actArticle, _i, _actArticle2;
24674
- return _regeneratorRuntime__default["default"].wrap(function _callee5$(_context5) {
24675
- while (1) switch (_context5.prev = _context5.next) {
24741
+ return _regeneratorRuntime__default["default"].wrap(function _callee6$(_context6) {
24742
+ while (1) switch (_context6.prev = _context6.next) {
24676
24743
  case 0:
24677
24744
  newEDOExtraArticles = [];
24678
24745
  partlistArticlesToLoad = [];
@@ -24680,124 +24747,124 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24680
24747
  i = 0;
24681
24748
  case 4:
24682
24749
  if (!(i < targetArticlesToUpdate.length)) {
24683
- _context5.next = 40;
24750
+ _context6.next = 40;
24684
24751
  break;
24685
24752
  }
24686
24753
  valuesArray[i] = {};
24687
24754
  actArticle = articles[targetArticlesToUpdate[i]];
24688
24755
  if (!(!actArticle || actArticle.deleted)) {
24689
- _context5.next = 11;
24756
+ _context6.next = 11;
24690
24757
  break;
24691
24758
  }
24692
24759
  targetArticlesToUpdate.splice(i, 1);
24693
24760
  i--;
24694
- return _context5.abrupt("continue", 37);
24761
+ return _context6.abrupt("continue", 37);
24695
24762
  case 11:
24696
24763
  if (targetArticlesWithNewValues.includes(targetArticlesToUpdate[i])) {
24697
24764
  valuesArray[i] = actArticle.getValidValues(_objectSpread$c({}, myValues), actArticle.CatalogData.mergeOptionsToSameOption);
24698
24765
  }
24699
24766
  if (!(Object.entries(valuesArray[i]).length > 0 || from !== null && from !== void 0 && from.startsWith('initializing'))) {
24700
- _context5.next = 32;
24767
+ _context6.next = 32;
24701
24768
  break;
24702
24769
  }
24703
- _context5.next = 15;
24770
+ _context6.next = 15;
24704
24771
  return this.updateCfgValues(actArticle, valuesArray[i], {});
24705
24772
  case 15:
24706
- newPartlistArticlesToLoad = _context5.sent;
24773
+ newPartlistArticlesToLoad = _context6.sent;
24707
24774
  _actArticle$checkDefa = actArticle.checkDefaultGlobalOpt(valuesArray[i]), variantValues = _actArticle$checkDefa.variantValues, triggerUpdate = _actArticle$checkDefa.triggerUpdate;
24708
24775
  valuesArray[i] = variantValues;
24709
- _context5.next = 20;
24776
+ _context6.next = 20;
24710
24777
  return this.updateAccessoriesFromGlobalOption(valuesArray[i], actArticle);
24711
24778
  case 20:
24712
24779
  if (!triggerUpdate) {
24713
- _context5.next = 28;
24780
+ _context6.next = 28;
24714
24781
  break;
24715
24782
  }
24716
- _context5.t0 = partlistArticlesToLoad;
24717
- _context5.next = 24;
24783
+ _context6.t0 = partlistArticlesToLoad;
24784
+ _context6.next = 24;
24718
24785
  return this.updateCfgValues(actArticle, valuesArray[i], {});
24719
24786
  case 24:
24720
- _context5.t1 = _context5.sent;
24721
- partlistArticlesToLoad = _context5.t0.concat.call(_context5.t0, _context5.t1);
24722
- _context5.next = 29;
24787
+ _context6.t1 = _context6.sent;
24788
+ partlistArticlesToLoad = _context6.t0.concat.call(_context6.t0, _context6.t1);
24789
+ _context6.next = 29;
24723
24790
  break;
24724
24791
  case 28:
24725
24792
  partlistArticlesToLoad = partlistArticlesToLoad.concat(newPartlistArticlesToLoad);
24726
24793
  case 29:
24727
24794
  newEDOExtraArticles = this.checkEDOArticles(articles);
24728
- _context5.next = 37;
24795
+ _context6.next = 37;
24729
24796
  break;
24730
24797
  case 32:
24731
- _context5.t2 = partlistArticlesToLoad;
24732
- _context5.next = 35;
24798
+ _context6.t2 = partlistArticlesToLoad;
24799
+ _context6.next = 35;
24733
24800
  return this.updateCfgValues(actArticle, {}, {});
24734
24801
  case 35:
24735
- _context5.t3 = _context5.sent;
24736
- partlistArticlesToLoad = _context5.t2.concat.call(_context5.t2, _context5.t3);
24802
+ _context6.t3 = _context6.sent;
24803
+ partlistArticlesToLoad = _context6.t2.concat.call(_context6.t2, _context6.t3);
24737
24804
  case 37:
24738
24805
  i++;
24739
- _context5.next = 4;
24806
+ _context6.next = 4;
24740
24807
  break;
24741
24808
  case 40:
24742
24809
  if (!((_articles$targetArtic = articles[targetArticlesToUpdate[0]]) !== null && _articles$targetArtic !== void 0 && _articles$targetArtic.hasPartlistArticleVisibleInTree)) {
24743
- _context5.next = 53;
24810
+ _context6.next = 53;
24744
24811
  break;
24745
24812
  }
24746
- _context5.t4 = _regeneratorRuntime__default["default"].keys(articles);
24813
+ _context6.t4 = _regeneratorRuntime__default["default"].keys(articles);
24747
24814
  case 42:
24748
- if ((_context5.t5 = _context5.t4()).done) {
24749
- _context5.next = 53;
24815
+ if ((_context6.t5 = _context6.t4()).done) {
24816
+ _context6.next = 53;
24750
24817
  break;
24751
24818
  }
24752
- key = _context5.t5.value;
24819
+ key = _context6.t5.value;
24753
24820
  configuredArticle = articles[targetArticlesToUpdate[0]];
24754
24821
  toIgnore = configuredArticle.pushParentId();
24755
24822
  if (![configuredArticle.basketId].concat(_toConsumableArray__default["default"](toIgnore)).includes(key)) {
24756
- _context5.next = 48;
24823
+ _context6.next = 48;
24757
24824
  break;
24758
24825
  }
24759
- return _context5.abrupt("continue", 42);
24826
+ return _context6.abrupt("continue", 42);
24760
24827
  case 48:
24761
24828
  _actArticle = articles[key];
24762
- _context5.next = 51;
24829
+ _context6.next = 51;
24763
24830
  return this.updateCfgValues(_actArticle, {}, {});
24764
24831
  case 51:
24765
- _context5.next = 42;
24832
+ _context6.next = 42;
24766
24833
  break;
24767
24834
  case 53:
24768
24835
  _i = 0;
24769
24836
  case 54:
24770
24837
  if (!(_i < targetArticlesToUpdate.length)) {
24771
- _context5.next = 64;
24838
+ _context6.next = 64;
24772
24839
  break;
24773
24840
  }
24774
24841
  _actArticle2 = articles[targetArticlesToUpdate[_i]];
24775
24842
  if (!(_actArticle2.CatalogData.doubleClickOnConfig || _actArticle2.hasType1Dependencies)) {
24776
- _context5.next = 61;
24843
+ _context6.next = 61;
24777
24844
  break;
24778
24845
  }
24779
- _context5.next = 59;
24846
+ _context6.next = 59;
24780
24847
  return this.updateCfgValues(_actArticle2, valuesArray[_i], {});
24781
24848
  case 59:
24782
- _context5.next = 61;
24849
+ _context6.next = 61;
24783
24850
  return this.updateCfgValues(_actArticle2, valuesArray[_i], {});
24784
24851
  case 61:
24785
24852
  _i++;
24786
- _context5.next = 54;
24853
+ _context6.next = 54;
24787
24854
  break;
24788
24855
  case 64:
24789
- return _context5.abrupt("return", {
24856
+ return _context6.abrupt("return", {
24790
24857
  newEDOExtraArticles: newEDOExtraArticles,
24791
24858
  targetArticlesToUpdate: targetArticlesToUpdate,
24792
24859
  partlistArticlesToLoad: partlistArticlesToLoad
24793
24860
  });
24794
24861
  case 65:
24795
24862
  case "end":
24796
- return _context5.stop();
24863
+ return _context6.stop();
24797
24864
  }
24798
- }, _callee5, this);
24865
+ }, _callee6, this);
24799
24866
  }));
24800
- function updateArticlesOptionStates(_x15, _x16, _x17, _x18, _x19) {
24867
+ function updateArticlesOptionStates(_x18, _x19, _x20, _x21, _x22) {
24801
24868
  return _updateArticlesOptionStates.apply(this, arguments);
24802
24869
  }
24803
24870
  return updateArticlesOptionStates;
@@ -24805,31 +24872,31 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24805
24872
  }, {
24806
24873
  key: "updateAccessoriesFromGlobalOption",
24807
24874
  value: function () {
24808
- var _updateAccessoriesFromGlobalOption = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee6(values, actArticle) {
24875
+ var _updateAccessoriesFromGlobalOption = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee7(values, actArticle) {
24809
24876
  var accessoiresToUpdate, key;
24810
- return _regeneratorRuntime__default["default"].wrap(function _callee6$(_context6) {
24811
- while (1) switch (_context6.prev = _context6.next) {
24877
+ return _regeneratorRuntime__default["default"].wrap(function _callee7$(_context7) {
24878
+ while (1) switch (_context7.prev = _context7.next) {
24812
24879
  case 0:
24813
24880
  accessoiresToUpdate = actArticle.getAccessoriesToChangeFromGlobalOption(values);
24814
- _context6.t0 = _regeneratorRuntime__default["default"].keys(accessoiresToUpdate);
24881
+ _context7.t0 = _regeneratorRuntime__default["default"].keys(accessoiresToUpdate);
24815
24882
  case 2:
24816
- if ((_context6.t1 = _context6.t0()).done) {
24817
- _context6.next = 8;
24883
+ if ((_context7.t1 = _context7.t0()).done) {
24884
+ _context7.next = 8;
24818
24885
  break;
24819
24886
  }
24820
- key = _context6.t1.value;
24821
- _context6.next = 6;
24887
+ key = _context7.t1.value;
24888
+ _context7.next = 6;
24822
24889
  return this.updateCfgValues(accessoiresToUpdate[key].accessoire, accessoiresToUpdate[key].variantValues, {});
24823
24890
  case 6:
24824
- _context6.next = 2;
24891
+ _context7.next = 2;
24825
24892
  break;
24826
24893
  case 8:
24827
24894
  case "end":
24828
- return _context6.stop();
24895
+ return _context7.stop();
24829
24896
  }
24830
- }, _callee6, this);
24897
+ }, _callee7, this);
24831
24898
  }));
24832
- function updateAccessoriesFromGlobalOption(_x20, _x21) {
24899
+ function updateAccessoriesFromGlobalOption(_x23, _x24) {
24833
24900
  return _updateAccessoriesFromGlobalOption.apply(this, arguments);
24834
24901
  }
24835
24902
  return updateAccessoriesFromGlobalOption;
@@ -24907,12 +24974,12 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24907
24974
  }, {
24908
24975
  key: "initCfgValues",
24909
24976
  value: (function () {
24910
- var _initCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee7(article, variantValues,
24977
+ var _initCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee8(article, variantValues,
24911
24978
  // Werte aus einem Basiskonfigurat,
24912
24979
  variantItems) {
24913
24980
  var myCatalogArticleOptions, articleOptionState, key, _article$set$ViewConf, optionState, attr, foundItem, _foundItem$opt, freeText, _key, myArtOPS, value, optionValueCodex, i, variantItem, possibleValues, j, possibleValue, _i2, _variantItem, val;
24914
- return _regeneratorRuntime__default["default"].wrap(function _callee7$(_context7) {
24915
- while (1) switch (_context7.prev = _context7.next) {
24981
+ return _regeneratorRuntime__default["default"].wrap(function _callee8$(_context8) {
24982
+ while (1) switch (_context8.prev = _context8.next) {
24916
24983
  case 0:
24917
24984
  myCatalogArticleOptions = article.catalogArticleOptions;
24918
24985
  articleOptionState = article.articleOptionStates;
@@ -24992,11 +25059,11 @@ var DivaArticleHandler = /*#__PURE__*/function () {
24992
25059
  }
24993
25060
  case 4:
24994
25061
  case "end":
24995
- return _context7.stop();
25062
+ return _context8.stop();
24996
25063
  }
24997
- }, _callee7);
25064
+ }, _callee8);
24998
25065
  }));
24999
- function initCfgValues(_x22, _x23, _x24) {
25066
+ function initCfgValues(_x25, _x26, _x27) {
25000
25067
  return _initCfgValues.apply(this, arguments);
25001
25068
  }
25002
25069
  return initCfgValues;
@@ -25004,19 +25071,19 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25004
25071
  }, {
25005
25072
  key: "setValidVariantValues",
25006
25073
  value: function () {
25007
- var _setValidVariantValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee8(article) {
25008
- return _regeneratorRuntime__default["default"].wrap(function _callee8$(_context8) {
25009
- while (1) switch (_context8.prev = _context8.next) {
25074
+ var _setValidVariantValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee9(article) {
25075
+ return _regeneratorRuntime__default["default"].wrap(function _callee9$(_context9) {
25076
+ while (1) switch (_context9.prev = _context9.next) {
25010
25077
  case 0:
25011
- _context8.next = 2;
25078
+ _context9.next = 2;
25012
25079
  return this.updateCfgValues(article, article.getValidValues(article.VariantValues, undefined, true), {});
25013
25080
  case 2:
25014
25081
  case "end":
25015
- return _context8.stop();
25082
+ return _context9.stop();
25016
25083
  }
25017
- }, _callee8, this);
25084
+ }, _callee9, this);
25018
25085
  }));
25019
- function setValidVariantValues(_x25) {
25086
+ function setValidVariantValues(_x28) {
25020
25087
  return _setValidVariantValues.apply(this, arguments);
25021
25088
  }
25022
25089
  return setValidVariantValues;
@@ -25033,10 +25100,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25033
25100
  }, {
25034
25101
  key: "updateCfgValues",
25035
25102
  value: (function () {
25036
- var _updateCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee9(article, newConfigValues, alreadyInitializedValues, dontCalcPrice, dontLoadPartlist) {
25103
+ var _updateCfgValues = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee10(article, newConfigValues, alreadyInitializedValues, dontCalcPrice, dontLoadPartlist) {
25037
25104
  var maxPriceOfGroupCodex, setByFeatureVariantValues, key, partlistArticlesToLoad;
25038
- return _regeneratorRuntime__default["default"].wrap(function _callee9$(_context9) {
25039
- while (1) switch (_context9.prev = _context9.next) {
25105
+ return _regeneratorRuntime__default["default"].wrap(function _callee10$(_context10) {
25106
+ while (1) switch (_context10.prev = _context10.next) {
25040
25107
  case 0:
25041
25108
  if (!!article.CatalogData.bundleRules) dontLoadPartlist = true;
25042
25109
  //es wird versucht die neuen Optionswerte zu setzten
@@ -25069,20 +25136,20 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25069
25136
  }
25070
25137
 
25071
25138
  //await -> partlist berechnung und laden
25072
- _context9.next = 8;
25139
+ _context10.next = 8;
25073
25140
  return article.updateShelfPlannerState();
25074
25141
  case 8:
25075
25142
  if (dontCalcPrice) {
25076
- _context9.next = 11;
25143
+ _context10.next = 11;
25077
25144
  break;
25078
25145
  }
25079
- _context9.next = 11;
25146
+ _context10.next = 11;
25080
25147
  return this.updateLastElement(article);
25081
25148
  case 11:
25082
- _context9.next = 13;
25149
+ _context10.next = 13;
25083
25150
  return this.evalAndLoadPartlistArticles(article, dontLoadPartlist, newConfigValues);
25084
25151
  case 13:
25085
- partlistArticlesToLoad = _context9.sent;
25152
+ partlistArticlesToLoad = _context10.sent;
25086
25153
  // löscht seine eigene partlist article - optimierung schnittmenge nicht löschen und nur neu neu laden
25087
25154
 
25088
25155
  //evalConstructionRules ausswerten
@@ -25099,14 +25166,14 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25099
25166
  //evtl opv images mit rules updaten
25100
25167
  article.updateOPVImages();
25101
25168
  }
25102
- return _context9.abrupt("return", partlistArticlesToLoad);
25169
+ return _context10.abrupt("return", partlistArticlesToLoad);
25103
25170
  case 17:
25104
25171
  case "end":
25105
- return _context9.stop();
25172
+ return _context10.stop();
25106
25173
  }
25107
- }, _callee9, this);
25174
+ }, _callee10, this);
25108
25175
  }));
25109
- function updateCfgValues(_x26, _x27, _x28, _x29, _x30) {
25176
+ function updateCfgValues(_x29, _x30, _x31, _x32, _x33) {
25110
25177
  return _updateCfgValues.apply(this, arguments);
25111
25178
  }
25112
25179
  return updateCfgValues;
@@ -25114,10 +25181,10 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25114
25181
  }, {
25115
25182
  key: "updateLastElement",
25116
25183
  value: function () {
25117
- var _updateLastElement = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee10(article) {
25184
+ var _updateLastElement = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee11(article) {
25118
25185
  var opsLastElement, lastElement, opsLastPlannedAccessoire, opsFirstAccessoire, _article$accessoirePa, _article$accessoirePa2, accessoires, i;
25119
- return _regeneratorRuntime__default["default"].wrap(function _callee10$(_context10) {
25120
- while (1) switch (_context10.prev = _context10.next) {
25186
+ return _regeneratorRuntime__default["default"].wrap(function _callee11$(_context11) {
25187
+ while (1) switch (_context11.prev = _context11.next) {
25121
25188
  case 0:
25122
25189
  opsLastElement = article.getArticleOptionState('OPTELEMENTPOSITION');
25123
25190
  if (opsLastElement) {
@@ -25140,29 +25207,29 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25140
25207
  }
25141
25208
  opsFirstAccessoire = article.getArticleOptionState('OPTFIRSTACCESSOIRE');
25142
25209
  if (!opsFirstAccessoire) {
25143
- _context10.next = 14;
25210
+ _context11.next = 14;
25144
25211
  break;
25145
25212
  }
25146
25213
  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 : [];
25147
25214
  i = 0;
25148
25215
  case 8:
25149
25216
  if (!(i < accessoires.length)) {
25150
- _context10.next = 14;
25217
+ _context11.next = 14;
25151
25218
  break;
25152
25219
  }
25153
- _context10.next = 11;
25220
+ _context11.next = 11;
25154
25221
  return this.updateOption(accessoires[i], 'OPTFIRSTACCESSOIRE', 'OPV' + (i + 1).toString(), i === 0 ? 'OPVFIRSTACCESSOIRE' : 'OPVNOTFIRSTACCESSOIRE');
25155
25222
  case 11:
25156
25223
  i++;
25157
- _context10.next = 8;
25224
+ _context11.next = 8;
25158
25225
  break;
25159
25226
  case 14:
25160
25227
  case "end":
25161
- return _context10.stop();
25228
+ return _context11.stop();
25162
25229
  }
25163
- }, _callee10, this);
25230
+ }, _callee11, this);
25164
25231
  }));
25165
- function updateLastElement(_x31) {
25232
+ function updateLastElement(_x34) {
25166
25233
  return _updateLastElement.apply(this, arguments);
25167
25234
  }
25168
25235
  return updateLastElement;
@@ -25170,41 +25237,41 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25170
25237
  }, {
25171
25238
  key: "updateOption",
25172
25239
  value: function () {
25173
- var _updateOption = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee11(article, optionCodex, newCodex, fallbackNewCodex) {
25240
+ var _updateOption = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee12(article, optionCodex, newCodex, fallbackNewCodex) {
25174
25241
  var _ops$val, _ops$visibleOptionVal;
25175
25242
  var ops, oldCodex, newVal;
25176
- return _regeneratorRuntime__default["default"].wrap(function _callee11$(_context11) {
25177
- while (1) switch (_context11.prev = _context11.next) {
25243
+ return _regeneratorRuntime__default["default"].wrap(function _callee12$(_context12) {
25244
+ while (1) switch (_context12.prev = _context12.next) {
25178
25245
  case 0:
25179
25246
  ops = article.getArticleOptionState(optionCodex);
25180
25247
  if (ops) {
25181
- _context11.next = 3;
25248
+ _context12.next = 3;
25182
25249
  break;
25183
25250
  }
25184
- return _context11.abrupt("return");
25251
+ return _context12.abrupt("return");
25185
25252
  case 3:
25186
25253
  oldCodex = (_ops$val = ops.val) === null || _ops$val === void 0 ? void 0 : _ops$val.codex;
25187
25254
  newVal = (_ops$visibleOptionVal = ops.visibleOptionValues[newCodex]) !== null && _ops$visibleOptionVal !== void 0 ? _ops$visibleOptionVal : fallbackNewCodex ? ops.visibleOptionValues[fallbackNewCodex] : undefined;
25188
25255
  if (!(oldCodex === (newVal === null || newVal === void 0 ? void 0 : newVal.codex))) {
25189
- _context11.next = 7;
25256
+ _context12.next = 7;
25190
25257
  break;
25191
25258
  }
25192
- return _context11.abrupt("return");
25259
+ return _context12.abrupt("return");
25193
25260
  case 7:
25194
25261
  if (!newVal) {
25195
- _context11.next = 11;
25262
+ _context12.next = 11;
25196
25263
  break;
25197
25264
  }
25198
25265
  ops.val = newVal;
25199
- _context11.next = 11;
25266
+ _context12.next = 11;
25200
25267
  return setHandlerInstance.updateArticlesOptionStatesOfActSet(article.set, {}, []);
25201
25268
  case 11:
25202
25269
  case "end":
25203
- return _context11.stop();
25270
+ return _context12.stop();
25204
25271
  }
25205
- }, _callee11);
25272
+ }, _callee12);
25206
25273
  }));
25207
- function updateOption(_x32, _x33, _x34, _x35) {
25274
+ function updateOption(_x35, _x36, _x37, _x38) {
25208
25275
  return _updateOption.apply(this, arguments);
25209
25276
  }
25210
25277
  return updateOption;
@@ -25214,23 +25281,23 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25214
25281
  }, {
25215
25282
  key: "evalAndLoadPartlistArticles",
25216
25283
  value: (function () {
25217
- var _evalAndLoadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee12(article, dontLoadPartlist, newConfigValues) {
25284
+ var _evalAndLoadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee13(article, dontLoadPartlist, newConfigValues) {
25218
25285
  var partlistArticlesToLoad;
25219
- return _regeneratorRuntime__default["default"].wrap(function _callee12$(_context12) {
25220
- while (1) switch (_context12.prev = _context12.next) {
25286
+ return _regeneratorRuntime__default["default"].wrap(function _callee13$(_context13) {
25287
+ while (1) switch (_context13.prev = _context13.next) {
25221
25288
  case 0:
25222
25289
  partlistArticlesToLoad = [];
25223
25290
  if (!article.hasPartlistArticle) {
25224
- _context12.next = 8;
25291
+ _context13.next = 8;
25225
25292
  break;
25226
25293
  }
25227
25294
  article.deletePartlistArticles(); //alle aktellen PartlistArticles des Articles löschen!
25228
25295
  partlistArticlesToLoad = article.evalPartlist(newConfigValues);
25229
25296
  if (dontLoadPartlist) {
25230
- _context12.next = 8;
25297
+ _context13.next = 8;
25231
25298
  break;
25232
25299
  }
25233
- _context12.next = 7;
25300
+ _context13.next = 7;
25234
25301
  return this.loadPartlistArticles(partlistArticlesToLoad, article, article.VariantValues);
25235
25302
  case 7:
25236
25303
  partlistArticlesToLoad = [];
@@ -25239,14 +25306,14 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25239
25306
  partlistArticlesToLoad = this.bundlePartlistArticles(partlistArticlesToLoad, article.bundleRules, _defineProperty__default["default"]({}, article.basketId, article));
25240
25307
  }
25241
25308
  article.hasPartlistArticleInitialized = true;
25242
- return _context12.abrupt("return", partlistArticlesToLoad);
25309
+ return _context13.abrupt("return", partlistArticlesToLoad);
25243
25310
  case 11:
25244
25311
  case "end":
25245
- return _context12.stop();
25312
+ return _context13.stop();
25246
25313
  }
25247
- }, _callee12, this);
25314
+ }, _callee13, this);
25248
25315
  }));
25249
- function evalAndLoadPartlistArticles(_x36, _x37, _x38) {
25316
+ function evalAndLoadPartlistArticles(_x39, _x40, _x41) {
25250
25317
  return _evalAndLoadPartlistArticles.apply(this, arguments);
25251
25318
  }
25252
25319
  return evalAndLoadPartlistArticles;
@@ -25254,32 +25321,41 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25254
25321
  }, {
25255
25322
  key: "loadPartlistArticles",
25256
25323
  value: function () {
25257
- var _loadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee13(partlistArticlesToLoad, article, newConfigValues) {
25258
- var i;
25259
- return _regeneratorRuntime__default["default"].wrap(function _callee13$(_context13) {
25260
- while (1) switch (_context13.prev = _context13.next) {
25324
+ var _loadPartlistArticles = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee14(partlistArticlesToLoad, article, newConfigValues) {
25325
+ var loadAwaits, i, doLoadItem;
25326
+ return _regeneratorRuntime__default["default"].wrap(function _callee14$(_context14) {
25327
+ while (1) switch (_context14.prev = _context14.next) {
25261
25328
  case 0:
25329
+ //make all api calls of all the partlistarticles at the same time but initialize them still synced
25330
+ loadAwaits = [];
25331
+ for (i = 0; i < partlistArticlesToLoad.length; i++) {
25332
+ doLoadItem = partlistArticlesToLoad[i];
25333
+ loadAwaits.push(this.preLoadArticle(article.set, doLoadItem.ArticleCodex, this.partlistArticleInitData(article, doLoadItem)));
25334
+ }
25335
+ _context14.next = 4;
25336
+ return Promise.all(loadAwaits);
25337
+ case 4:
25262
25338
  i = 0;
25263
- case 1:
25339
+ case 5:
25264
25340
  if (!(i < partlistArticlesToLoad.length)) {
25265
- _context13.next = 7;
25341
+ _context14.next = 11;
25266
25342
  break;
25267
25343
  }
25268
- _context13.next = 4;
25344
+ _context14.next = 8;
25269
25345
  return this.loadPartlistArticle(partlistArticlesToLoad[i], article, newConfigValues);
25270
- case 4:
25346
+ case 8:
25271
25347
  i++;
25272
- _context13.next = 1;
25348
+ _context14.next = 5;
25273
25349
  break;
25274
- case 7:
25350
+ case 11:
25275
25351
  article.sortPartlistArticles(partlistArticlesToLoad);
25276
- case 8:
25352
+ case 12:
25277
25353
  case "end":
25278
- return _context13.stop();
25354
+ return _context14.stop();
25279
25355
  }
25280
- }, _callee13, this);
25356
+ }, _callee14, this);
25281
25357
  }));
25282
- function loadPartlistArticles(_x39, _x40, _x41) {
25358
+ function loadPartlistArticles(_x42, _x43, _x44) {
25283
25359
  return _loadPartlistArticles.apply(this, arguments);
25284
25360
  }
25285
25361
  return loadPartlistArticles;
@@ -25288,60 +25364,64 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25288
25364
  }, {
25289
25365
  key: "loadPartlistArticle",
25290
25366
  value: function () {
25291
- var _loadPartlistArticle = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee14(doLoadItem, article, newConfigValues) {
25292
- var parentVariantValues, initParams, nArticle;
25293
- return _regeneratorRuntime__default["default"].wrap(function _callee14$(_context14) {
25294
- while (1) switch (_context14.prev = _context14.next) {
25367
+ var _loadPartlistArticle = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee15(doLoadItem, article, newConfigValues) {
25368
+ var nArticle;
25369
+ return _regeneratorRuntime__default["default"].wrap(function _callee15$(_context15) {
25370
+ while (1) switch (_context15.prev = _context15.next) {
25295
25371
  case 0:
25296
- //jeder neue Artikel sollte im Warenkorb als Zubehörartikel gelistet werden - es können auch mehrere sein
25297
- parentVariantValues = article.getArticleJsonVariantValues(); //jetzt Artikel laden und zur Kollektion hinzufügen
25298
- initParams = {
25299
- plannerBasketID: article.basketId,
25300
- //Bei Ekornes gibt es Partlistartikels mit SVGs - Damit die BasketID im Plener weiter gültig ist, wird hier die Originale BasketID gemerkt.
25301
- quantity: doLoadItem.Quantity,
25302
- variantValues: parentVariantValues,
25303
- //Objektstruktur
25304
- relatedToBasketId: article.basketId,
25305
- parentArticle: article,
25306
- isPartlistArticle: true,
25307
- ruleDesc: doLoadItem.RuleDesc,
25308
- ruleDesc_locales: doLoadItem.RuleDesc_locales,
25309
- basketId: doLoadItem.BasketID,
25310
- partlistRule: doLoadItem.PartlistRule,
25311
- retailArticleNr: doLoadItem.RetailArticleNr,
25312
- retailPrefix: doLoadItem.RetailPrefix,
25313
- configArticleCodex: doLoadItem.RetailArticleNr,
25314
- supplierOrderCodex: doLoadItem.SupplierOrderCodex,
25315
- initDecisions: doLoadItem.initDecisions,
25316
- partlistArticleVisibleInTree: doLoadItem.PosInvisibility === 0,
25317
- optionsForPrint: doLoadItem.optionsForPrint,
25318
- optionImgForPrint: doLoadItem.optionImgForPrint,
25319
- catalogCodex: doLoadItem.CatalogCodex
25320
- };
25321
- _context14.next = 4;
25322
- return this.loadArticle(article.set, doLoadItem.ArticleCodex, initParams);
25323
- case 4:
25324
- nArticle = _context14.sent;
25372
+ _context15.next = 2;
25373
+ return this.loadArticle(article.set, doLoadItem.ArticleCodex, this.partlistArticleInitData(article, doLoadItem));
25374
+ case 2:
25375
+ nArticle = _context15.sent;
25325
25376
  if (!nArticle) {
25326
- _context14.next = 10;
25377
+ _context15.next = 8;
25327
25378
  break;
25328
25379
  }
25329
25380
  doLoadItem.BasketID = nArticle.basketId;
25330
- _context14.next = 9;
25381
+ _context15.next = 7;
25331
25382
  return this.toDoAfterArticleLoaded(nArticle, {}, _objectSpread$c(_objectSpread$c({}, doLoadItem.VariantValues), newConfigValues), 'initializingPartlist', doLoadItem.VariantItemData);
25332
- case 9:
25383
+ case 7:
25333
25384
  article.addPartlistArticle(nArticle);
25334
- case 10:
25385
+ case 8:
25335
25386
  case "end":
25336
- return _context14.stop();
25387
+ return _context15.stop();
25337
25388
  }
25338
- }, _callee14, this);
25389
+ }, _callee15, this);
25339
25390
  }));
25340
- function loadPartlistArticle(_x42, _x43, _x44) {
25391
+ function loadPartlistArticle(_x45, _x46, _x47) {
25341
25392
  return _loadPartlistArticle.apply(this, arguments);
25342
25393
  }
25343
25394
  return loadPartlistArticle;
25344
- }() /**************************************** Querkontrollen über mehrere Article deshalb hier im ArticleHandler ********************************************************************************/
25395
+ }()
25396
+ }, {
25397
+ key: "partlistArticleInitData",
25398
+ value: function partlistArticleInitData(article, doLoadItem) {
25399
+ //jetzt Artikel laden und zur Kollektion hinzufügen
25400
+ return {
25401
+ plannerBasketID: article.basketId,
25402
+ //Bei Ekornes gibt es Partlistartikels mit SVGs - Damit die BasketID im Plener weiter gültig ist, wird hier die Originale BasketID gemerkt.
25403
+ quantity: doLoadItem.Quantity,
25404
+ variantValues: article.getArticleJsonVariantValues(),
25405
+ //Objektstruktur
25406
+ relatedToBasketId: article.basketId,
25407
+ parentArticle: article,
25408
+ isPartlistArticle: true,
25409
+ ruleDesc: doLoadItem.RuleDesc,
25410
+ ruleDesc_locales: doLoadItem.RuleDesc_locales,
25411
+ basketId: doLoadItem.BasketID,
25412
+ partlistRule: doLoadItem.PartlistRule,
25413
+ retailArticleNr: doLoadItem.RetailArticleNr,
25414
+ retailPrefix: doLoadItem.RetailPrefix,
25415
+ configArticleCodex: doLoadItem.RetailArticleNr,
25416
+ supplierOrderCodex: doLoadItem.SupplierOrderCodex,
25417
+ initDecisions: doLoadItem.initDecisions,
25418
+ partlistArticleVisibleInTree: doLoadItem.PosInvisibility === 0,
25419
+ optionsForPrint: doLoadItem.optionsForPrint,
25420
+ optionImgForPrint: doLoadItem.optionImgForPrint,
25421
+ catalogCodex: doLoadItem.CatalogCodex
25422
+ };
25423
+ }
25424
+ /**************************************** Querkontrollen über mehrere Article deshalb hier im ArticleHandler ********************************************************************************/
25345
25425
  }, {
25346
25426
  key: "evalOpvsOnOpvsConstructionRules",
25347
25427
  value: function evalOpvsOnOpvsConstructionRules(article) {
@@ -25586,31 +25666,31 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25586
25666
  }, {
25587
25667
  key: "triggerShelfplannerVisibility",
25588
25668
  value: function () {
25589
- var _triggerShelfplannerVisibility = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee15(artices, gridGroup) {
25669
+ var _triggerShelfplannerVisibility = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee16(artices, gridGroup) {
25590
25670
  var key, _artice$shelfPlanner, artice;
25591
- return _regeneratorRuntime__default["default"].wrap(function _callee15$(_context15) {
25592
- while (1) switch (_context15.prev = _context15.next) {
25671
+ return _regeneratorRuntime__default["default"].wrap(function _callee16$(_context16) {
25672
+ while (1) switch (_context16.prev = _context16.next) {
25593
25673
  case 0:
25594
- _context15.t0 = _regeneratorRuntime__default["default"].keys(artices);
25674
+ _context16.t0 = _regeneratorRuntime__default["default"].keys(artices);
25595
25675
  case 1:
25596
- if ((_context15.t1 = _context15.t0()).done) {
25597
- _context15.next = 8;
25676
+ if ((_context16.t1 = _context16.t0()).done) {
25677
+ _context16.next = 8;
25598
25678
  break;
25599
25679
  }
25600
- key = _context15.t1.value;
25680
+ key = _context16.t1.value;
25601
25681
  artice = artices[key];
25602
- _context15.next = 6;
25682
+ _context16.next = 6;
25603
25683
  return (_artice$shelfPlanner = artice.shelfPlanner) === null || _artice$shelfPlanner === void 0 ? void 0 : _artice$shelfPlanner.triggerVisibility(gridGroup);
25604
25684
  case 6:
25605
- _context15.next = 1;
25685
+ _context16.next = 1;
25606
25686
  break;
25607
25687
  case 8:
25608
25688
  case "end":
25609
- return _context15.stop();
25689
+ return _context16.stop();
25610
25690
  }
25611
- }, _callee15);
25691
+ }, _callee16);
25612
25692
  }));
25613
- function triggerShelfplannerVisibility(_x45, _x46) {
25693
+ function triggerShelfplannerVisibility(_x48, _x49) {
25614
25694
  return _triggerShelfplannerVisibility.apply(this, arguments);
25615
25695
  }
25616
25696
  return triggerShelfplannerVisibility;
@@ -25856,21 +25936,21 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25856
25936
  }, {
25857
25937
  key: "correctPartlistArticlesByGlobalRules",
25858
25938
  value: (function () {
25859
- var _correctPartlistArticlesByGlobalRules = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee16(set, partlistArticlesToLoad, bundleRules, doChangeRetailArticleNumbers) {
25939
+ var _correctPartlistArticlesByGlobalRules = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee17(set, partlistArticlesToLoad, bundleRules, doChangeRetailArticleNumbers) {
25860
25940
  var _loop2, i, article;
25861
- return _regeneratorRuntime__default["default"].wrap(function _callee16$(_context17) {
25862
- while (1) switch (_context17.prev = _context17.next) {
25941
+ return _regeneratorRuntime__default["default"].wrap(function _callee17$(_context18) {
25942
+ while (1) switch (_context18.prev = _context18.next) {
25863
25943
  case 0:
25864
25944
  if (bundleRules) partlistArticlesToLoad = this.bundlePartlistArticles(partlistArticlesToLoad, bundleRules, set.getDivaArticles());
25865
25945
  //Correct RetailArticleNumbers
25866
25946
  if (!(doChangeRetailArticleNumbers !== null && doChangeRetailArticleNumbers !== void 0 && doChangeRetailArticleNumbers.doChange && doChangeRetailArticleNumbers.retailArticleRules)) {
25867
- _context17.next = 9;
25947
+ _context18.next = 9;
25868
25948
  break;
25869
25949
  }
25870
25950
  _loop2 = /*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _loop2(i) {
25871
25951
  var rule;
25872
- return _regeneratorRuntime__default["default"].wrap(function _loop2$(_context16) {
25873
- while (1) switch (_context16.prev = _context16.next) {
25952
+ return _regeneratorRuntime__default["default"].wrap(function _loop2$(_context17) {
25953
+ while (1) switch (_context17.prev = _context17.next) {
25874
25954
  case 0:
25875
25955
  //Run through articleCodexes to repair:
25876
25956
  rule = doChangeRetailArticleNumbers.retailArticleRules.find(function (item) {
@@ -25882,34 +25962,34 @@ var DivaArticleHandler = /*#__PURE__*/function () {
25882
25962
  }
25883
25963
  case 2:
25884
25964
  case "end":
25885
- return _context16.stop();
25965
+ return _context17.stop();
25886
25966
  }
25887
25967
  }, _loop2);
25888
25968
  });
25889
25969
  i = 0;
25890
25970
  case 4:
25891
25971
  if (!(i < partlistArticlesToLoad.length)) {
25892
- _context17.next = 9;
25972
+ _context18.next = 9;
25893
25973
  break;
25894
25974
  }
25895
- return _context17.delegateYield(_loop2(i), "t0", 6);
25975
+ return _context18.delegateYield(_loop2(i), "t0", 6);
25896
25976
  case 6:
25897
25977
  i++;
25898
- _context17.next = 4;
25978
+ _context18.next = 4;
25899
25979
  break;
25900
25980
  case 9:
25901
25981
  article = Object.values(set.getDivaArticles()).find(function (article) {
25902
25982
  return article.hasPartlistArticle && !article.deleted;
25903
25983
  });
25904
- _context17.next = 12;
25984
+ _context18.next = 12;
25905
25985
  return this.loadPartlistArticles(partlistArticlesToLoad, article, {});
25906
25986
  case 12:
25907
25987
  case "end":
25908
- return _context17.stop();
25988
+ return _context18.stop();
25909
25989
  }
25910
- }, _callee16, this);
25990
+ }, _callee17, this);
25911
25991
  }));
25912
- function correctPartlistArticlesByGlobalRules(_x47, _x48, _x49, _x50) {
25992
+ function correctPartlistArticlesByGlobalRules(_x50, _x51, _x52, _x53) {
25913
25993
  return _correctPartlistArticlesByGlobalRules.apply(this, arguments);
25914
25994
  }
25915
25995
  return correctPartlistArticlesByGlobalRules;
@@ -28001,7 +28081,7 @@ var DivaSet = /*#__PURE__*/function () {
28001
28081
  break;
28002
28082
  }
28003
28083
  _context4.next = 3;
28004
- return Promise.resolve().then(function () { return require('./DoorPlanner-73c462cf.js'); });
28084
+ return Promise.resolve().then(function () { return require('./DoorPlanner-497f79a4.js'); });
28005
28085
  case 3:
28006
28086
  _yield$import = _context4.sent;
28007
28087
  DoorPlanner = _yield$import["default"];
@@ -35218,7 +35298,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
35218
35298
  break;
35219
35299
  case 3:
35220
35300
  _context13.next = 5;
35221
- return Promise.resolve().then(function () { return require('./PfisterWWSHandler-0b867d64.js'); });
35301
+ return Promise.resolve().then(function () { return require('./PfisterWWSHandler-3832b3db.js'); });
35222
35302
  case 5:
35223
35303
  _yield$import = _context13.sent;
35224
35304
  PfisterWWSHandler = _yield$import["default"];
@@ -35226,7 +35306,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
35226
35306
  return _context13.abrupt("break", 33);
35227
35307
  case 9:
35228
35308
  _context13.next = 11;
35229
- return Promise.resolve().then(function () { return require('./LiviqueWWSHandler-72636128.js'); });
35309
+ return Promise.resolve().then(function () { return require('./LiviqueWWSHandler-9ef41a4b.js'); });
35230
35310
  case 11:
35231
35311
  _yield$import2 = _context13.sent;
35232
35312
  LiviqueWWSHandler = _yield$import2["default"];
@@ -35234,7 +35314,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
35234
35314
  return _context13.abrupt("break", 33);
35235
35315
  case 15:
35236
35316
  _context13.next = 17;
35237
- return Promise.resolve().then(function () { return require('./SeriousBasketHandler-0303202e.js'); });
35317
+ return Promise.resolve().then(function () { return require('./SeriousBasketHandler-44108127.js'); });
35238
35318
  case 17:
35239
35319
  _yield$import3 = _context13.sent;
35240
35320
  SeriousWWSHandler = _yield$import3["default"];
@@ -35242,7 +35322,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
35242
35322
  return _context13.abrupt("break", 33);
35243
35323
  case 21:
35244
35324
  _context13.next = 23;
35245
- return Promise.resolve().then(function () { return require('./ProductBasketHandler-7b9f5bd9.js'); });
35325
+ return Promise.resolve().then(function () { return require('./ProductBasketHandler-bf3f28a6.js'); });
35246
35326
  case 23:
35247
35327
  _yield$import4 = _context13.sent;
35248
35328
  ProductWWSHandler = _yield$import4["default"];
@@ -35250,7 +35330,7 @@ var DivaBasketHandler = /*#__PURE__*/function () {
35250
35330
  return _context13.abrupt("break", 33);
35251
35331
  case 27:
35252
35332
  _context13.next = 29;
35253
- return Promise.resolve().then(function () { return require('./StandardWWSHandler-06ae3bfc.js'); });
35333
+ return Promise.resolve().then(function () { return require('./StandardWWSHandler-6150a756.js'); });
35254
35334
  case 29:
35255
35335
  _yield$import5 = _context13.sent;
35256
35336
  StandardWWSHandler = _yield$import5["default"];
@@ -36086,6 +36166,17 @@ var Rendering = /*#__PURE__*/function () {
36086
36166
  value: function getUnityFOV() {
36087
36167
  return parseFloat(this.uiInfo['CAM']['FOV']);
36088
36168
  }
36169
+ }, {
36170
+ key: "get3DDimInfo",
36171
+ value: function get3DDimInfo() {
36172
+ if (this.uiInfo && this.uiInfo['DIM3D']) return this.uiInfo['DIM3D'];
36173
+ LOG$5.warn('No dimension infos returned');
36174
+ return {
36175
+ w: -1,
36176
+ h: -1,
36177
+ d: -1
36178
+ };
36179
+ }
36089
36180
 
36090
36181
  //elementId has to be a string because when working with accs in shelf planner an element id is the combination of parentElementId.rasterHeight.gridId
36091
36182
  //It returns the distance of an element to the ground in cm
@@ -36110,7 +36201,11 @@ var Rendering = /*#__PURE__*/function () {
36110
36201
  }));
36111
36202
  }
36112
36203
  }
36113
-
36204
+ }, {
36205
+ key: "hasUIInfo",
36206
+ value: function hasUIInfo() {
36207
+ return this.uiInfo != '';
36208
+ }
36114
36209
  /**
36115
36210
  * This function adds a blobImage to the rendering .
36116
36211
  * It is parsed to a base64 image.
@@ -36620,7 +36715,7 @@ var PlannerHandler3D = /*#__PURE__*/function () {
36620
36715
  while (1) switch (_context3.prev = _context3.next) {
36621
36716
  case 0:
36622
36717
  _context3.next = 2;
36623
- return Promise.resolve().then(function () { return require('./Host3DSignalR-93aafc52.js'); });
36718
+ return Promise.resolve().then(function () { return require('./Host3DSignalR-c8a4f342.js'); });
36624
36719
  case 2:
36625
36720
  _yield$import = _context3.sent;
36626
36721
  Host3DSignalR = _yield$import["default"];
@@ -36913,7 +37008,7 @@ var PlannerHandler3D = /*#__PURE__*/function () {
36913
37008
  startTimeWait = new Date(); //It can happen that a rendering is not in the waitForRenderings stack anymore, but UrlToSavedRendering is not set yet- therefore wait until the url to the rendering is set.
36914
37009
  //This happens when two renderings are requested at the same time. First one with mediaType Stream and the second with mediatype TEMP. (Open PDF Viewer directly)
36915
37010
  case 4:
36916
- if (!(this.waitForRenderings.has(this.lastSavedRendering.PlanningHash) || !this.lastSavedRendering.UrlToSavedRendering)) {
37011
+ if (!(this.waitForRenderings.has(this.lastSavedRendering.PlanningHash) || !this.lastSavedRendering.UrlToSavedRendering || !this.lastSavedRendering.hasUIInfo())) {
36917
37012
  _context5.next = 12;
36918
37013
  break;
36919
37014
  }
@@ -36975,7 +37070,7 @@ var PlannerHandler3D = /*#__PURE__*/function () {
36975
37070
  break;
36976
37071
  }
36977
37072
  case 5:
36978
- if (!(this.waitForRenderings.has(this.lastSavedAlternateRenderings[i].PlanningHash) || !this.lastSavedAlternateRenderings[i].UrlToSavedRendering)) {
37073
+ if (!(this.waitForRenderings.has(this.lastSavedAlternateRenderings[i].PlanningHash) || !this.lastSavedAlternateRenderings[i].UrlToSavedRendering || !this.lastSavedAlternateRenderings[i].hasUIInfo())) {
36979
37074
  _context6.next = 12;
36980
37075
  break;
36981
37076
  }
@@ -38169,7 +38264,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
38169
38264
  break;
38170
38265
  case 8:
38171
38266
  _context4.next = 10;
38172
- return Promise.resolve().then(function () { return require('./DivaStandardPlanner-428015e0.js'); });
38267
+ return Promise.resolve().then(function () { return require('./DivaStandardPlanner-3a655cd7.js'); });
38173
38268
  case 10:
38174
38269
  _yield$import = _context4.sent;
38175
38270
  DivaStandardPlanner = _yield$import["default"];
@@ -38180,7 +38275,7 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
38180
38275
  return _context4.abrupt("break", 21);
38181
38276
  case 15:
38182
38277
  _context4.next = 17;
38183
- return Promise.resolve().then(function () { return require('./DivaBoxPlanner-330653bb.js'); });
38278
+ return Promise.resolve().then(function () { return require('./DivaBoxPlanner-c0491407.js'); });
38184
38279
  case 17:
38185
38280
  _yield$import2 = _context4.sent;
38186
38281
  DivaBoxPlanner = _yield$import2["default"];
@@ -38322,8 +38417,9 @@ var DivaPlannerHandler = /*#__PURE__*/function () {
38322
38417
  return this.getSetRendering(setId);
38323
38418
  case 2:
38324
38419
  rendering = _context6.sent;
38420
+ LOG$2.debug('SAVE SET IMAGE DIM3D width: ' + (rendering === null || rendering === void 0 ? void 0 : rendering.get3DDimInfo().w) + ', height: ' + (rendering === null || rendering === void 0 ? void 0 : rendering.get3DDimInfo().h) + ', depth: ' + (rendering === null || rendering === void 0 ? void 0 : rendering.get3DDimInfo().d));
38325
38421
  return _context6.abrupt("return", rendering != undefined ? rendering.UrlToSavedRendering : '');
38326
- case 4:
38422
+ case 5:
38327
38423
  case "end":
38328
38424
  return _context6.stop();
38329
38425
  }