@crystaldesign/web-planner-logic 26.8.0-beta.2 → 26.8.0-beta.21

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 (49) hide show
  1. package/build/cjs/{DivaBoxPlanner-2e378a1a.js → DivaBoxPlanner-16d920f2.js} +68 -58
  2. package/build/cjs/{DivaStandardPlanner-0a6e8f4a.js → DivaStandardPlanner-b4e89cab.js} +2 -2
  3. package/build/cjs/{DoorPlanner-0ebcb060.js → DoorPlanner-1438da9c.js} +1 -1
  4. package/build/cjs/{Host3DSignalR-653cebc1.js → Host3DSignalR-530ac879.js} +1 -1
  5. package/build/cjs/{LiviqueWWSHandler-9259293e.js → LiviqueWWSHandler-e865b385.js} +1 -1
  6. package/build/cjs/{PfisterWWSHandler-26c807f9.js → PfisterWWSHandler-d85f9680.js} +10 -1
  7. package/build/cjs/{PlannerHandler2D-1b28c82a.js → PlannerHandler2D-62352f6b.js} +24 -9
  8. package/build/cjs/{SeriousBasketHandler-e3f8040a.js → SeriousBasketHandler-1dc4eb5a.js} +1 -1
  9. package/build/cjs/{ShelfPlanner-58edfc01.js → ShelfPlanner-9df60123.js} +1 -1
  10. package/build/cjs/{StandardWWSHandler-6faba9e9.js → StandardWWSHandler-77bbb1fb.js} +1 -1
  11. package/build/cjs/{index-c1566d30.js → index-65181912.js} +213 -162
  12. package/build/cjs/index.js +1 -1
  13. package/build/esm/{DivaBoxPlanner-e8f7c4cd.js → DivaBoxPlanner-210c2ceb.js} +68 -58
  14. package/build/esm/{DivaStandardPlanner-21c4c0ca.js → DivaStandardPlanner-d82eb446.js} +2 -2
  15. package/build/esm/{DoorPlanner-a4e3a380.js → DoorPlanner-97f65d89.js} +1 -1
  16. package/build/esm/{Host3DSignalR-ed1240f2.js → Host3DSignalR-06b4d30b.js} +1 -1
  17. package/build/esm/{LiviqueWWSHandler-fc0597c3.js → LiviqueWWSHandler-b488cf8e.js} +1 -1
  18. package/build/esm/{PfisterWWSHandler-a92fb5ca.js → PfisterWWSHandler-9b820585.js} +10 -1
  19. package/build/esm/{PlannerHandler2D-c52912b0.js → PlannerHandler2D-d8217417.js} +24 -9
  20. package/build/esm/{SeriousBasketHandler-18db24f8.js → SeriousBasketHandler-342998a5.js} +1 -1
  21. package/build/esm/{ShelfPlanner-354da88b.js → ShelfPlanner-e66b37ab.js} +1 -1
  22. package/build/esm/{StandardWWSHandler-46f9434e.js → StandardWWSHandler-1d9ae8f7.js} +1 -1
  23. package/build/esm/{index-18f1d8c6.js → index-d51f2804.js} +213 -162
  24. package/build/esm/index.js +1 -1
  25. package/build/types/web-planner-logic/src/interface/Articles/CatalogArticleDataType.d.ts +1 -0
  26. package/build/types/web-planner-logic/src/interface/Articles/CatalogArticleDataType.d.ts.map +1 -1
  27. package/build/types/web-planner-logic/src/interface/DivaCatalogDataType.d.ts +1 -0
  28. package/build/types/web-planner-logic/src/interface/DivaCatalogDataType.d.ts.map +1 -1
  29. package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts +1 -0
  30. package/build/types/web-planner-logic/src/logic/Article/DivaArticle.d.ts.map +1 -1
  31. package/build/types/web-planner-logic/src/logic/Article/Engine/DivaArticleEngine.d.ts.map +1 -1
  32. package/build/types/web-planner-logic/src/logic/Article/Engine/IDMArticleEngine.d.ts.map +1 -1
  33. package/build/types/web-planner-logic/src/logic/Basket/PfisterWWSHandler.d.ts.map +1 -1
  34. package/build/types/web-planner-logic/src/logic/ConfigTree/SummaryHandler.d.ts +1 -0
  35. package/build/types/web-planner-logic/src/logic/ConfigTree/SummaryHandler.d.ts.map +1 -1
  36. package/build/types/web-planner-logic/src/logic/DivaApiHandler.d.ts +5 -0
  37. package/build/types/web-planner-logic/src/logic/DivaApiHandler.d.ts.map +1 -1
  38. package/build/types/web-planner-logic/src/logic/DivaWebPlanner.d.ts.map +1 -1
  39. package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/BoxPlannerGrid.d.ts +1 -0
  40. package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/BoxPlannerGrid.d.ts.map +1 -1
  41. package/build/types/web-planner-logic/src/logic/Planner/BoxPlanner/ConstructionRulesHandler.d.ts.map +1 -1
  42. package/build/types/web-planner-logic/src/logic/Planner/PlannerUtils/DockingPointHandler.d.ts.map +1 -1
  43. package/build/types/web-planner-logic/src/model/Articles/Article/CatalogArticleData.d.ts +1 -0
  44. package/build/types/web-planner-logic/src/model/Articles/Article/CatalogArticleData.d.ts.map +1 -1
  45. package/build/types/web-planner-logic/src/model/Articles/Article/IDMCatalogArticle.d.ts.map +1 -1
  46. package/build/types/web-planner-logic/src/model/Catalog/CatalogData.d.ts +9 -0
  47. package/build/types/web-planner-logic/src/model/Catalog/CatalogData.d.ts.map +1 -1
  48. package/build/types/web-planner-logic/src/model/Catalog/DivaCatalogData.d.ts.map +1 -1
  49. package/package.json +2 -2
@@ -5,11 +5,11 @@ var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
5
5
  var _createClass = require('@babel/runtime/helpers/createClass');
6
6
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
7
7
  var _regeneratorRuntime = require('@babel/runtime/regenerator');
8
- var index = require('./index-c1566d30.js');
8
+ var index = require('./index-65181912.js');
9
9
  var DivaUtils = require('@crystaldesign/diva-utils');
10
10
  var _toConsumableArray = require('@babel/runtime/helpers/toConsumableArray');
11
11
  var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
12
- var PlannerHandler2D = require('./PlannerHandler2D-1b28c82a.js');
12
+ var PlannerHandler2D = require('./PlannerHandler2D-62352f6b.js');
13
13
  require('@babel/runtime/helpers/objectWithoutProperties');
14
14
  require('axios');
15
15
  require('@crystaldesign/basket-model');
@@ -2843,6 +2843,7 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
2843
2843
  var seriesWidthToPlateOpv = coverPlateRule.seriesWidthToPlateOpv;
2844
2844
 
2845
2845
  // default => set all to ohne
2846
+
2846
2847
  serie.forEach(function (element) {
2847
2848
  var _element$size$width;
2848
2849
  seriesWidth += (_element$size$width = element.size.width) !== null && _element$size$width !== void 0 ? _element$size$width : 0;
@@ -2852,37 +2853,30 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
2852
2853
  _this5.setOptionValue(element.elementId, coverPlateRule.optABD, 'OPVOHNE', optionHandler);
2853
2854
  });
2854
2855
  var firstUncoveredElement = serie[0];
2855
- var _loop = function _loop() {
2856
- var opv = seriesWidthToPlateOpv.findLast(function (stp) {
2857
- // is a clean element ending
2858
- var helperWidth = 0;
2859
- var isClean = false;
2860
- serie.forEach(function (element) {
2861
- var _element$size$width2;
2862
- helperWidth += (_element$size$width2 = element.size.width) !== null && _element$size$width2 !== void 0 ? _element$size$width2 : 0;
2863
- if (Math.abs(helperWidth - stp.limit) < 1) isClean = true;
2864
- });
2865
- if (stp.limit <= seriesWidth && isClean) return true;
2866
- return false;
2867
- });
2868
- if (!opv) return {
2869
- v: void 0
2870
- };
2871
- _this5.setOptionValue(firstUncoveredElement.elementId, coverPlateRule.optABD, opv.plateOpv, optionHandler);
2856
+ var elementCoverage = firstUncoveredElement.area.fromX;
2857
+ while (seriesWidth != 0) {
2858
+ var _boxPlannerGrid$GridS;
2859
+ var opv = seriesWidthToPlateOpv.findLast(function (stp) {
2860
+ // is a clean element ending
2872
2861
  var helperWidth = 0;
2873
- firstUncoveredElement = serie.find(function (e) {
2874
- var _e$size$width;
2875
- helperWidth += (_e$size$width = e.size.width) !== null && _e$size$width !== void 0 ? _e$size$width : 0;
2876
- if (helperWidth > opv.limit) return true;
2877
- return false;
2862
+ var isClean = false;
2863
+ serie.forEach(function (element) {
2864
+ var _element$size$width2;
2865
+ helperWidth += (_element$size$width2 = element.size.width) !== null && _element$size$width2 !== void 0 ? _element$size$width2 : 0;
2866
+ if (Math.abs(helperWidth - stp.limit) < 1) isClean = true;
2878
2867
  });
2879
- seriesWidth = seriesWidth - opv.limit;
2880
- if (seriesWidthToPlateOpv[1].limit > seriesWidth) seriesWidth = 0;
2881
- },
2882
- _ret;
2883
- while (seriesWidth != 0) {
2884
- _ret = _loop();
2885
- if (_ret) return _ret.v;
2868
+ if (stp.limit <= seriesWidth && isClean) return true;
2869
+ return false;
2870
+ });
2871
+ if (!opv) return;
2872
+ _this5.setOptionValue(firstUncoveredElement.elementId, coverPlateRule.optABD, opv.plateOpv, optionHandler);
2873
+ elementCoverage += Math.round(opv.limit / ((_boxPlannerGrid$GridS = boxPlannerGrid.GridSetupParams.fixCellRasterWidth) !== null && _boxPlannerGrid$GridS !== void 0 ? _boxPlannerGrid$GridS : 1));
2874
+ firstUncoveredElement = serie.find(function (e) {
2875
+ if (e.area.fromX >= elementCoverage) return true;
2876
+ return false;
2877
+ });
2878
+ seriesWidth = seriesWidth - opv.limit;
2879
+ if (seriesWidthToPlateOpv[1].limit > seriesWidth) seriesWidth = 0;
2886
2880
  }
2887
2881
  });
2888
2882
  }
@@ -3767,6 +3761,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
3767
3761
  }
3768
3762
  }, {
3769
3763
  key: "GridSetupParams",
3764
+ get: function get() {
3765
+ return this.gridSetupParams;
3766
+ },
3770
3767
  set: function set(gridSetupParams) {
3771
3768
  this.gridSetupParams = gridSetupParams;
3772
3769
  }
@@ -4501,29 +4498,42 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4501
4498
  // Neighbor column left/right of the copy (where support width is checked). At the grid edge that column does not exist
4502
4499
  // (LEFT: startColIndex === 0 → index.x === -1; RIGHT: endColIndex === curGrid.length → past last column).
4503
4500
  // Then scan along an in-grid column of this element so we still collect the full vertical stack to copy.
4504
- var supportColX = index.x;
4501
+ var supportColX = dir === 'LEFT' ? curPos.startColIndex - 1 : curPos.endColIndex;
4502
+ var belowColX = dir === 'LEFT' ? curPos.startColIndex : curPos.endColIndex - 1;
4503
+
4504
+ // Copying into new grid space (e.g. LEFT from column 0) — no adjacent column exists to check
4505
+ // support width against, so include the entire vertical stack below unconditionally.
4505
4506
  if (!curGrid[supportColX]) {
4506
- supportColX = dir === 'LEFT' ? curPos.startColIndex : curPos.endColIndex - 1;
4507
+ for (var y = index.y - 1; y >= 0;) {
4508
+ var _curGrid$belowColX;
4509
+ var belowElement = (_curGrid$belowColX = curGrid[belowColX]) === null || _curGrid$belowColX === void 0 || (_curGrid$belowColX = _curGrid$belowColX[y]) === null || _curGrid$belowColX === void 0 ? void 0 : _curGrid$belowColX.plannedElement;
4510
+ if (!belowElement) break;
4511
+ plannerIdsToFill.push(belowElement.elementId);
4512
+ y = belowElement.area.fromY - 1;
4513
+ }
4514
+ return {
4515
+ elements: plannerIdsToFill.reverse(),
4516
+ backside: curPos.backside
4517
+ };
4507
4518
  }
4508
- var belowColX = dir === 'LEFT' ? curPos.startColIndex : curPos.endColIndex - 1;
4509
- var _loop = function _loop(_y3) {
4510
- var _curGrid$belowColX, _curGrid$supportColX$, _Width, _Width2, _Width3;
4519
+ var _loop = function _loop(_y4) {
4520
+ var _curGrid$belowColX2, _curGrid$supportColX$, _Width, _Width2, _Width3;
4511
4521
  if (!curGrid[supportColX]) {
4512
- y = _y3;
4522
+ _y3 = _y4;
4513
4523
  return 0;
4514
4524
  } // break
4515
4525
 
4516
4526
  // Always resolve the element in our own column — that is what we copy, not the neighbour.
4517
- var belowElement = (_curGrid$belowColX = curGrid[belowColX]) === null || _curGrid$belowColX === void 0 || (_curGrid$belowColX = _curGrid$belowColX[_y3]) === null || _curGrid$belowColX === void 0 ? void 0 : _curGrid$belowColX.plannedElement;
4527
+ var belowElement = (_curGrid$belowColX2 = curGrid[belowColX]) === null || _curGrid$belowColX2 === void 0 || (_curGrid$belowColX2 = _curGrid$belowColX2[_y4]) === null || _curGrid$belowColX2 === void 0 ? void 0 : _curGrid$belowColX2.plannedElement;
4518
4528
  if (!belowElement) {
4519
- y = _y3;
4529
+ _y3 = _y4;
4520
4530
  return 0;
4521
4531
  } // break
4522
- var supportElement = (_curGrid$supportColX$ = curGrid[supportColX][_y3]) === null || _curGrid$supportColX$ === void 0 ? void 0 : _curGrid$supportColX$.plannedElement;
4532
+ var supportElement = (_curGrid$supportColX$ = curGrid[supportColX][_y4]) === null || _curGrid$supportColX$ === void 0 ? void 0 : _curGrid$supportColX$.plannedElement;
4523
4533
  if (!supportElement) {
4524
4534
  plannerIdsToFill.push(belowElement.elementId);
4525
- _y3 = belowElement.area.fromY - 1;
4526
- y = _y3;
4535
+ _y4 = belowElement.area.fromY - 1;
4536
+ _y3 = _y4;
4527
4537
  return 1; // continue
4528
4538
  }
4529
4539
 
@@ -4543,7 +4553,7 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4543
4553
  freeSpace += n.Width;
4544
4554
  });
4545
4555
  if (freeSpace >= elementWidth) {
4546
- y = _y3;
4556
+ _y3 = _y4;
4547
4557
  return 0;
4548
4558
  } // break
4549
4559
  var belowWidth = (_Width3 = _this2.getElementById(belowElement.elementId).Width) !== null && _Width3 !== void 0 ? _Width3 : belowElement.size.width;
@@ -4552,12 +4562,12 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4552
4562
  plannerIdsToFill.push(belowElement.elementId);
4553
4563
  missingWidth = Math.round(missingWidth - belowWidth);
4554
4564
  }
4555
- _y3 = belowElement.area.fromY - 1;
4556
- y = _y3;
4565
+ _y4 = belowElement.area.fromY - 1;
4566
+ _y3 = _y4;
4557
4567
  },
4558
4568
  _ret;
4559
- for (var y = index.y - 1; y >= 0;) {
4560
- _ret = _loop(y);
4569
+ for (var _y3 = index.y - 1; _y3 >= 0;) {
4570
+ _ret = _loop(_y3);
4561
4571
  if (_ret === 0) break;
4562
4572
  if (_ret === 1) continue;
4563
4573
  }
@@ -4908,9 +4918,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4908
4918
  for (var _x5 = cell.plannedElement.area.fromX; _x5 < cell.plannedElement.area.toX; _x5++) {
4909
4919
  var row = grid[_x5];
4910
4920
  if (!row) continue;
4911
- for (var _y4 = origin.y; _y4 < row.length; _y4++) {
4912
- var _cell = row[_y4];
4913
- if (_cell.index.y != _y4 || _cell.plannedElement.elementId == cell.plannedElement.elementId) continue; //already corrected
4921
+ for (var _y5 = origin.y; _y5 < row.length; _y5++) {
4922
+ var _cell = row[_y5];
4923
+ if (_cell.index.y != _y5 || _cell.plannedElement.elementId == cell.plannedElement.elementId) continue; //already corrected
4914
4924
  _cell.index.y += diff.y;
4915
4925
  _cell.plannedElement.area.fromY += diff.y;
4916
4926
  _cell.plannedElement.area.toY += diff.y;
@@ -4919,8 +4929,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4919
4929
  } else if (diff.x != 0 && (diff.x > free || diff.x < 0)) {
4920
4930
  // if there is enough free space on the right no need to move
4921
4931
  for (var _x6 = cell.plannedElement.area.fromX; _x6 < grid.length; _x6++) {
4922
- for (var _y5 = cell.plannedElement.area.fromY; _y5 < cell.plannedElement.area.toY; _y5++) {
4923
- var _cell10 = grid[_x6][_y5];
4932
+ for (var _y6 = cell.plannedElement.area.fromY; _y6 < cell.plannedElement.area.toY; _y6++) {
4933
+ var _cell10 = grid[_x6][_y6];
4924
4934
  if (!_cell10 || _cell10.plannedElement.elementId == elementId) continue; //already corrected
4925
4935
  _cell10.index.x += diff.x;
4926
4936
  _cell10.plannedElement.area.fromX += diff.x;
@@ -4944,7 +4954,7 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4944
4954
  });
4945
4955
  })) return 0; // continue
4946
4956
  for (var _x7 = area.fromX; _x7 < area.toX; _x7++) {
4947
- for (var _y6 = area.fromY; _y6 < area.toY; _y6++) {
4957
+ for (var _y7 = area.fromY; _y7 < area.toY; _y7++) {
4948
4958
  if (!newGrid[_x7] && area.fromY == 0) newGrid[_x7] = [];
4949
4959
 
4950
4960
  // we have a so called overhanging element not so nice, let's correct:
@@ -4968,10 +4978,10 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
4968
4978
  // when the element above starts early and goes over multiple ones
4969
4979
 
4970
4980
  // regular case
4971
- newGrid[_x7][_y6] = _objectSpread(_objectSpread({}, cell), {}, {
4981
+ newGrid[_x7][_y7] = _objectSpread(_objectSpread({}, cell), {}, {
4972
4982
  index: {
4973
4983
  x: _x7,
4974
- y: _y6
4984
+ y: _y7
4975
4985
  },
4976
4986
  plannedElement: _objectSpread(_objectSpread({}, cell.plannedElement), {}, {
4977
4987
  area: {
@@ -5449,9 +5459,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
5449
5459
  var _targetColIndex = endColIndex;
5450
5460
  var _copyPossible2 = false;
5451
5461
  // Iterate through rows within the element's height
5452
- for (var _y7 = startRowIndex; _y7 <= endRowIndex; _y7++) {
5453
- if (isValidCell(_targetColIndex, _y7)) {
5454
- copyStartRowIndex = _y7;
5462
+ for (var _y8 = startRowIndex; _y8 <= endRowIndex; _y8++) {
5463
+ if (isValidCell(_targetColIndex, _y8)) {
5464
+ copyStartRowIndex = _y8;
5455
5465
  _copyPossible2 = true;
5456
5466
  break;
5457
5467
  }
@@ -5,9 +5,9 @@ var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
5
5
  var _createClass = require('@babel/runtime/helpers/createClass');
6
6
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
7
7
  var _regeneratorRuntime = require('@babel/runtime/regenerator');
8
- var index = require('./index-c1566d30.js');
8
+ var index = require('./index-65181912.js');
9
9
  var DivaUtils = require('@crystaldesign/diva-utils');
10
- var PlannerHandler2D = require('./PlannerHandler2D-1b28c82a.js');
10
+ var PlannerHandler2D = require('./PlannerHandler2D-62352f6b.js');
11
11
  require('@babel/runtime/helpers/slicedToArray');
12
12
  require('@babel/runtime/helpers/objectWithoutProperties');
13
13
  require('@babel/runtime/helpers/toConsumableArray');
@@ -3,7 +3,7 @@
3
3
  var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
4
4
  var _createClass = require('@babel/runtime/helpers/createClass');
5
5
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
6
- require('./index-c1566d30.js');
6
+ require('./index-65181912.js');
7
7
  var DivaUtils = require('@crystaldesign/diva-utils');
8
8
  require('@babel/runtime/helpers/slicedToArray');
9
9
  require('@babel/runtime/helpers/asyncToGenerator');
@@ -5,7 +5,7 @@ var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
5
5
  var _createClass = require('@babel/runtime/helpers/createClass');
6
6
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
7
7
  var _regeneratorRuntime = require('@babel/runtime/regenerator');
8
- var index = require('./index-c1566d30.js');
8
+ var index = require('./index-65181912.js');
9
9
  var DivaUtils = require('@crystaldesign/diva-utils');
10
10
  var signalr = require('@microsoft/signalr');
11
11
  var io = require('socket.io-client');
@@ -2,7 +2,7 @@
2
2
 
3
3
  var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
4
4
  var _createClass = require('@babel/runtime/helpers/createClass');
5
- require('./index-c1566d30.js');
5
+ require('./index-65181912.js');
6
6
  require('@babel/runtime/helpers/slicedToArray');
7
7
  require('@babel/runtime/helpers/asyncToGenerator');
8
8
  require('@babel/runtime/helpers/defineProperty');
@@ -2,7 +2,7 @@
2
2
 
3
3
  var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
4
4
  var _createClass = require('@babel/runtime/helpers/createClass');
5
- var index = require('./index-c1566d30.js');
5
+ var index = require('./index-65181912.js');
6
6
  var basketModel = require('@crystaldesign/basket-model');
7
7
  var DivaUtils = require('@crystaldesign/diva-utils');
8
8
  require('@babel/runtime/helpers/slicedToArray');
@@ -284,6 +284,15 @@ var PfisterWWSHandler = /*#__PURE__*/function () {
284
284
  } else {
285
285
  sapOrderlines = sapOrderlines.concat(blindSAPOrderLines);
286
286
  }
287
+ } else if (blindSAPOrderLines.length > 0) {
288
+ //ZKAT/blind Artikel zusätzlich zu expliziten SAP Orderlines nur listen, wenn per ADD_AS_ZKAT markiert
289
+ var zkatLinesToAdd = blindSAPOrderLines.filter(function (line) {
290
+ return line.basketIds.some(function (id) {
291
+ var _articles$id;
292
+ return (_articles$id = articles[id]) === null || _articles$id === void 0 ? void 0 : _articles$id.addAsZKAT;
293
+ });
294
+ });
295
+ sapOrderlines = sapOrderlines.concat(zkatLinesToAdd);
287
296
  }
288
297
  if (orderSet.BruttoSetPrice) orderSet.SetPrice = orderSet.BruttoSetPrice;
289
298
  return {
@@ -5,7 +5,7 @@ var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
5
5
  var _createClass = require('@babel/runtime/helpers/createClass');
6
6
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
7
7
  var _regeneratorRuntime = require('@babel/runtime/regenerator');
8
- var index = require('./index-c1566d30.js');
8
+ var index = require('./index-65181912.js');
9
9
  var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
10
10
  var _toConsumableArray = require('@babel/runtime/helpers/toConsumableArray');
11
11
  var fabric = require('fabric');
@@ -1670,8 +1670,9 @@ var DockingPointHandler = /*#__PURE__*/function () {
1670
1670
  value: function checkDPAVLFilterDoMatch(plannerElement1, plannerElement2) {
1671
1671
  var avrFilter1 = plannerElement1.FilterAVR;
1672
1672
  var avlFilter2 = plannerElement2.FilterAVL;
1673
- if (avlFilter2.length == 0 && avrFilter1.length == 0) return true; //Diese überprüfung bin ich mir nicht sicher, dass es so passt.
1674
1673
 
1674
+ // An empty filter on either side means "no connector restriction" -> always dockable.
1675
+ if (avlFilter2.length == 0 || avrFilter1.length == 0) return true;
1675
1676
  for (var i = 0; i < avrFilter1.length; i++) {
1676
1677
  for (var j = 0; j < avlFilter2.length; j++) {
1677
1678
  if (avrFilter1[i] == avlFilter2[j]) {
@@ -1686,7 +1687,9 @@ var DockingPointHandler = /*#__PURE__*/function () {
1686
1687
  value: function checkDPAVRFilterDoMatch(plannerElement1, plannerElement2) {
1687
1688
  var avlFilter1 = plannerElement1.FilterAVL;
1688
1689
  var avrFilter2 = plannerElement2.FilterAVR;
1689
- if (avlFilter1.length == 0 && avrFilter2.length == 0) return true; //Diese überprüfung bin ich mir nicht sicher, dass es so passt.
1690
+
1691
+ // An empty filter on either side means "no connector restriction" -> always dockable.
1692
+ if (avlFilter1.length == 0 || avrFilter2.length == 0) return true;
1690
1693
  for (var i = 0; i < avlFilter1.length; i++) {
1691
1694
  for (var j = 0; j < avrFilter2.length; j++) {
1692
1695
  if (avlFilter1[i] == avrFilter2[j]) {
@@ -1706,10 +1709,18 @@ var DockingPointHandler = /*#__PURE__*/function () {
1706
1709
  var avrDockable = this.checkDPAVRFilterDoMatch(sourcePlannerElement, targetElement);
1707
1710
  var avlDockable = this.checkDPAVLFilterDoMatch(sourcePlannerElement, targetElement);
1708
1711
  var refDPType = this.getReferenceDPType(dp1.Type);
1709
- if (refDPType == 'AVL' && !avlDockable) return false;
1710
- if (refDPType == 'AVR' && !avrDockable) return false;
1711
- if (dp2.Type != refDPType) return false;
1712
- if (dp1.IsDocking || dp2.IsDocking) return false;
1712
+ if (refDPType == 'AVL' && !avlDockable) {
1713
+ return false;
1714
+ }
1715
+ if (refDPType == 'AVR' && !avrDockable) {
1716
+ return false;
1717
+ }
1718
+ if (dp2.Type != refDPType) {
1719
+ return false;
1720
+ }
1721
+ if (dp1.IsDocking || dp2.IsDocking) {
1722
+ return false;
1723
+ }
1713
1724
  if (!dp1.IgnoreLayer || !dp2.IgnoreLayer) {
1714
1725
  var doCheckLayer = true;
1715
1726
  if (dp1.PlannerConfig.ignoreLayerAVC && (dp1.Type == 'AVC' || dp2.Type == 'AVC')) {
@@ -1722,9 +1733,13 @@ var DockingPointHandler = /*#__PURE__*/function () {
1722
1733
  doCheckLayer = false;
1723
1734
  }
1724
1735
  //Check layer
1725
- if (doCheckLayer && dp2.Layer == dp1.Layer) return false;
1736
+ if (doCheckLayer && dp2.Layer == dp1.Layer) {
1737
+ return false;
1738
+ }
1739
+ }
1740
+ if (!dp1.PlannerConfig.ignoreDockingNumber && dp1.HasNumber && dp2.HasNumber && dp1.Number != dp2.Number) {
1741
+ return false;
1726
1742
  }
1727
- if (dp1.HasNumber && dp2.HasNumber && dp1.Number != dp2.Number) return false;
1728
1743
  return true;
1729
1744
  }
1730
1745
 
@@ -3,7 +3,7 @@
3
3
  var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
4
4
  var _createClass = require('@babel/runtime/helpers/createClass');
5
5
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
6
- var index = require('./index-c1566d30.js');
6
+ var index = require('./index-65181912.js');
7
7
  var DivaUtils = require('@crystaldesign/diva-utils');
8
8
  require('@babel/runtime/helpers/slicedToArray');
9
9
  require('@babel/runtime/helpers/asyncToGenerator');
@@ -6,7 +6,7 @@ var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
6
6
  var _createClass = require('@babel/runtime/helpers/createClass');
7
7
  var _defineProperty = require('@babel/runtime/helpers/defineProperty');
8
8
  var _regeneratorRuntime = require('@babel/runtime/regenerator');
9
- var index = require('./index-c1566d30.js');
9
+ var index = require('./index-65181912.js');
10
10
  var DivaUtils = require('@crystaldesign/diva-utils');
11
11
  require('@babel/runtime/helpers/slicedToArray');
12
12
  require('@babel/runtime/helpers/objectWithoutProperties');
@@ -2,7 +2,7 @@
2
2
 
3
3
  var _classCallCheck = require('@babel/runtime/helpers/classCallCheck');
4
4
  var _createClass = require('@babel/runtime/helpers/createClass');
5
- require('./index-c1566d30.js');
5
+ require('./index-65181912.js');
6
6
  require('@babel/runtime/helpers/slicedToArray');
7
7
  require('@babel/runtime/helpers/asyncToGenerator');
8
8
  require('@babel/runtime/helpers/defineProperty');