@crystaldesign/web-planner-logic 24.12.1 → 24.12.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/{DivaBoxPlanner-303a552b.js → DivaBoxPlanner-1c78ef85.js} +317 -318
- package/build/cjs/{DivaStandardPlanner-2f994125.js → DivaStandardPlanner-eb45e763.js} +82 -82
- package/build/cjs/{DoorPlanner-1faa1593.js → DoorPlanner-3a199423.js} +1 -1
- package/build/cjs/{Host3DSignalR-a9bc4c70.js → Host3DSignalR-c52991a0.js} +43 -43
- package/build/cjs/{LiviqueWWSHandler-e9462b37.js → LiviqueWWSHandler-6607e52f.js} +1 -1
- package/build/cjs/{PfisterWWSHandler-65b5992f.js → PfisterWWSHandler-2ea37e1d.js} +6 -6
- package/build/cjs/{PlannerHandler2D-9ce74b8c.js → PlannerHandler2D-de64a752.js} +189 -189
- package/build/cjs/{SeriousBasketHandler-c0d4f0f5.js → SeriousBasketHandler-03648231.js} +1 -1
- package/build/cjs/{ShelfPlanner-642594d4.js → ShelfPlanner-4402bf3e.js} +86 -86
- package/build/cjs/{StandardWWSHandler-c7833d13.js → StandardWWSHandler-62bc3cc6.js} +1 -1
- package/build/cjs/{index-530d9304.js → index-e86ab943.js} +632 -632
- package/build/cjs/index.js +1 -1
- package/build/esm/{DivaBoxPlanner-0748b14a.js → DivaBoxPlanner-655a32f3.js} +317 -318
- package/build/esm/{DivaStandardPlanner-2c8858b2.js → DivaStandardPlanner-e1faf2c9.js} +82 -82
- package/build/esm/{DoorPlanner-c640fd24.js → DoorPlanner-cfebaef8.js} +1 -1
- package/build/esm/{Host3DSignalR-aa3a4b4d.js → Host3DSignalR-5d924d77.js} +43 -43
- package/build/esm/{LiviqueWWSHandler-8d2570dd.js → LiviqueWWSHandler-62ff852e.js} +1 -1
- package/build/esm/{PfisterWWSHandler-c046e3ee.js → PfisterWWSHandler-1cf1fce6.js} +6 -6
- package/build/esm/{PlannerHandler2D-844fc811.js → PlannerHandler2D-ad96ee8d.js} +189 -189
- package/build/esm/{SeriousBasketHandler-b8e1b0da.js → SeriousBasketHandler-9e031da4.js} +1 -1
- package/build/esm/{ShelfPlanner-f3218c50.js → ShelfPlanner-4f446e61.js} +86 -86
- package/build/esm/{StandardWWSHandler-a3c5246b.js → StandardWWSHandler-e72ecb08.js} +1 -1
- package/build/esm/{index-3870ea62.js → index-84339e2f.js} +632 -632
- package/build/esm/index.js +1 -1
- package/package.json +2 -2
|
@@ -3,10 +3,10 @@ import _classCallCheck from '@babel/runtime/helpers/classCallCheck';
|
|
|
3
3
|
import _createClass from '@babel/runtime/helpers/createClass';
|
|
4
4
|
import _defineProperty from '@babel/runtime/helpers/defineProperty';
|
|
5
5
|
import _regeneratorRuntime from '@babel/runtime/regenerator';
|
|
6
|
-
import { V as Vector3, B as BoundingBox } from './index-
|
|
6
|
+
import { V as Vector3, B as BoundingBox } from './index-84339e2f.js';
|
|
7
7
|
import DivaUtils, { DivaError, md5 } from '@crystaldesign/diva-utils';
|
|
8
8
|
import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
|
|
9
|
-
import { d as dockingPointHandlerInst, P as PlannerElementData, h as handler2D } from './PlannerHandler2D-
|
|
9
|
+
import { d as dockingPointHandlerInst, P as PlannerElementData, h as handler2D } from './PlannerHandler2D-ad96ee8d.js';
|
|
10
10
|
import '@babel/runtime/helpers/objectWithoutProperties';
|
|
11
11
|
import '@babel/runtime/helpers/slicedToArray';
|
|
12
12
|
import 'axios';
|
|
@@ -422,11 +422,11 @@ var BoxPlannerPartlistHelper = /*#__PURE__*/function () {
|
|
|
422
422
|
}
|
|
423
423
|
}
|
|
424
424
|
|
|
425
|
-
/**
|
|
426
|
-
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
427
|
-
* @param curElement
|
|
428
|
-
* @param boxPlannerGrid
|
|
429
|
-
* @param optionHandler
|
|
425
|
+
/**
|
|
426
|
+
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
427
|
+
* @param curElement
|
|
428
|
+
* @param boxPlannerGrid
|
|
429
|
+
* @param optionHandler
|
|
430
430
|
*/
|
|
431
431
|
}, {
|
|
432
432
|
key: "correctRahmenVerticalLeftFront",
|
|
@@ -469,11 +469,11 @@ var BoxPlannerPartlistHelper = /*#__PURE__*/function () {
|
|
|
469
469
|
}
|
|
470
470
|
}
|
|
471
471
|
|
|
472
|
-
/**
|
|
473
|
-
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
474
|
-
* @param curElement
|
|
475
|
-
* @param boxPlannerGrid
|
|
476
|
-
* @param optionHandler
|
|
472
|
+
/**
|
|
473
|
+
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
474
|
+
* @param curElement
|
|
475
|
+
* @param boxPlannerGrid
|
|
476
|
+
* @param optionHandler
|
|
477
477
|
*/
|
|
478
478
|
}, {
|
|
479
479
|
key: "correctRahmenVerticalLeftBack",
|
|
@@ -527,11 +527,11 @@ var BoxPlannerPartlistHelper = /*#__PURE__*/function () {
|
|
|
527
527
|
}
|
|
528
528
|
}
|
|
529
529
|
|
|
530
|
-
/**
|
|
531
|
-
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
532
|
-
* @param curElement
|
|
533
|
-
* @param boxPlannerGrid
|
|
534
|
-
* @param optionHandler
|
|
530
|
+
/**
|
|
531
|
+
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
532
|
+
* @param curElement
|
|
533
|
+
* @param boxPlannerGrid
|
|
534
|
+
* @param optionHandler
|
|
535
535
|
*/
|
|
536
536
|
}, {
|
|
537
537
|
key: "correctRahmenVerticalRightFront",
|
|
@@ -583,11 +583,11 @@ var BoxPlannerPartlistHelper = /*#__PURE__*/function () {
|
|
|
583
583
|
}
|
|
584
584
|
}
|
|
585
585
|
|
|
586
|
-
/**
|
|
587
|
-
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
588
|
-
* @param curElement
|
|
589
|
-
* @param boxPlannerGrid
|
|
590
|
-
* @param optionHandler
|
|
586
|
+
/**
|
|
587
|
+
* This fucntion corrects the left front Senkrechte Rahmen of the element
|
|
588
|
+
* @param curElement
|
|
589
|
+
* @param boxPlannerGrid
|
|
590
|
+
* @param optionHandler
|
|
591
591
|
*/
|
|
592
592
|
}, {
|
|
593
593
|
key: "correctRahmenVerticalRightBack",
|
|
@@ -1425,76 +1425,76 @@ var BoxPlannerPartlistHelper = /*#__PURE__*/function () {
|
|
|
1425
1425
|
}
|
|
1426
1426
|
break;
|
|
1427
1427
|
}
|
|
1428
|
-
/*
|
|
1429
|
-
if (!this.getElementHasBottomPlate(curElement, optionHandler)) {
|
|
1430
|
-
//Element has no ground plate
|
|
1431
|
-
if (!boxPlannerGrid.getElementHasRightElement(curElement.getElementId())) {
|
|
1432
|
-
let opposideElement = boxPlannerGrid.getOppositeElement(curElement.getElementId());
|
|
1433
|
-
if (opposideElement) {
|
|
1434
|
-
if (this.getElementHasBottomPlate(opposideElement, optionHandler)) {
|
|
1435
|
-
//The opposide element has a ground plate
|
|
1436
|
-
this.setOptionValue(
|
|
1437
|
-
curElement.getElementId(),
|
|
1438
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1439
|
-
this.constructionRules.knotInfo.knotOPVs.knot3er_1GT,
|
|
1440
|
-
optionHandler,
|
|
1441
|
-
);
|
|
1442
|
-
} else {
|
|
1443
|
-
//The opposide element has no ground plate
|
|
1444
|
-
this.setOptionValue(
|
|
1445
|
-
curElement.getElementId(),
|
|
1446
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1447
|
-
this.constructionRules.knotInfo.knotOPVs.knot3er_0GT,
|
|
1448
|
-
optionHandler,
|
|
1449
|
-
);
|
|
1450
|
-
}
|
|
1451
|
-
}
|
|
1452
|
-
} else {
|
|
1453
|
-
//Element has neighbor element
|
|
1454
|
-
//Set the Glasteller count depending on the plates of the neighbors
|
|
1455
|
-
switch (this.getGroundPlatesNumOfRightNeighbors(curElement, boxPlannerGrid, optionHandler)) {
|
|
1456
|
-
case 0:
|
|
1457
|
-
this.setOptionValue(
|
|
1458
|
-
curElement.getElementId(),
|
|
1459
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1460
|
-
this.constructionRules.knotInfo.knotOPVs.knot4er_0GT,
|
|
1461
|
-
optionHandler,
|
|
1462
|
-
);
|
|
1463
|
-
break;
|
|
1464
|
-
case 1:
|
|
1465
|
-
this.setOptionValue(
|
|
1466
|
-
curElement.getElementId(),
|
|
1467
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1468
|
-
this.constructionRules.knotInfo.knotOPVs.knot4er_1GT,
|
|
1469
|
-
optionHandler,
|
|
1470
|
-
);
|
|
1471
|
-
break;
|
|
1472
|
-
case 2:
|
|
1473
|
-
this.setOptionValue(
|
|
1474
|
-
curElement.getElementId(),
|
|
1475
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1476
|
-
this.constructionRules.knotInfo.knotOPVs.knot4er_2GT,
|
|
1477
|
-
optionHandler,
|
|
1478
|
-
);
|
|
1479
|
-
break;
|
|
1480
|
-
case 3:
|
|
1481
|
-
this.setOptionValue(
|
|
1482
|
-
curElement.getElementId(),
|
|
1483
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1484
|
-
this.constructionRules.knotInfo.knotOPVs.knot4er_3GT,
|
|
1485
|
-
optionHandler,
|
|
1486
|
-
);
|
|
1487
|
-
break;
|
|
1488
|
-
case 4:
|
|
1489
|
-
this.setOptionValue(
|
|
1490
|
-
curElement.getElementId(),
|
|
1491
|
-
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1492
|
-
this.constructionRules.knotInfo.knotOPVs.knot4er_4GT,
|
|
1493
|
-
optionHandler,
|
|
1494
|
-
);
|
|
1495
|
-
break;
|
|
1496
|
-
}
|
|
1497
|
-
}
|
|
1428
|
+
/*
|
|
1429
|
+
if (!this.getElementHasBottomPlate(curElement, optionHandler)) {
|
|
1430
|
+
//Element has no ground plate
|
|
1431
|
+
if (!boxPlannerGrid.getElementHasRightElement(curElement.getElementId())) {
|
|
1432
|
+
let opposideElement = boxPlannerGrid.getOppositeElement(curElement.getElementId());
|
|
1433
|
+
if (opposideElement) {
|
|
1434
|
+
if (this.getElementHasBottomPlate(opposideElement, optionHandler)) {
|
|
1435
|
+
//The opposide element has a ground plate
|
|
1436
|
+
this.setOptionValue(
|
|
1437
|
+
curElement.getElementId(),
|
|
1438
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1439
|
+
this.constructionRules.knotInfo.knotOPVs.knot3er_1GT,
|
|
1440
|
+
optionHandler,
|
|
1441
|
+
);
|
|
1442
|
+
} else {
|
|
1443
|
+
//The opposide element has no ground plate
|
|
1444
|
+
this.setOptionValue(
|
|
1445
|
+
curElement.getElementId(),
|
|
1446
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1447
|
+
this.constructionRules.knotInfo.knotOPVs.knot3er_0GT,
|
|
1448
|
+
optionHandler,
|
|
1449
|
+
);
|
|
1450
|
+
}
|
|
1451
|
+
}
|
|
1452
|
+
} else {
|
|
1453
|
+
//Element has neighbor element
|
|
1454
|
+
//Set the Glasteller count depending on the plates of the neighbors
|
|
1455
|
+
switch (this.getGroundPlatesNumOfRightNeighbors(curElement, boxPlannerGrid, optionHandler)) {
|
|
1456
|
+
case 0:
|
|
1457
|
+
this.setOptionValue(
|
|
1458
|
+
curElement.getElementId(),
|
|
1459
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1460
|
+
this.constructionRules.knotInfo.knotOPVs.knot4er_0GT,
|
|
1461
|
+
optionHandler,
|
|
1462
|
+
);
|
|
1463
|
+
break;
|
|
1464
|
+
case 1:
|
|
1465
|
+
this.setOptionValue(
|
|
1466
|
+
curElement.getElementId(),
|
|
1467
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1468
|
+
this.constructionRules.knotInfo.knotOPVs.knot4er_1GT,
|
|
1469
|
+
optionHandler,
|
|
1470
|
+
);
|
|
1471
|
+
break;
|
|
1472
|
+
case 2:
|
|
1473
|
+
this.setOptionValue(
|
|
1474
|
+
curElement.getElementId(),
|
|
1475
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1476
|
+
this.constructionRules.knotInfo.knotOPVs.knot4er_2GT,
|
|
1477
|
+
optionHandler,
|
|
1478
|
+
);
|
|
1479
|
+
break;
|
|
1480
|
+
case 3:
|
|
1481
|
+
this.setOptionValue(
|
|
1482
|
+
curElement.getElementId(),
|
|
1483
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1484
|
+
this.constructionRules.knotInfo.knotOPVs.knot4er_3GT,
|
|
1485
|
+
optionHandler,
|
|
1486
|
+
);
|
|
1487
|
+
break;
|
|
1488
|
+
case 4:
|
|
1489
|
+
this.setOptionValue(
|
|
1490
|
+
curElement.getElementId(),
|
|
1491
|
+
this.constructionRules.knotInfo.knotOPT_RightBottomBack,
|
|
1492
|
+
this.constructionRules.knotInfo.knotOPVs.knot4er_4GT,
|
|
1493
|
+
optionHandler,
|
|
1494
|
+
);
|
|
1495
|
+
break;
|
|
1496
|
+
}
|
|
1497
|
+
}
|
|
1498
1498
|
}*/
|
|
1499
1499
|
}
|
|
1500
1500
|
if (this.getElementIsCornerElement(curElement, optionHandler)) {
|
|
@@ -1679,19 +1679,19 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1679
1679
|
_defineProperty(this, "checkArticleHasOption", void 0);
|
|
1680
1680
|
_defineProperty(this, "updateCfgValuesByPlanner", void 0);
|
|
1681
1681
|
// private repairPairs: () => void;
|
|
1682
|
-
/**
|
|
1683
|
-
* This object holds all the information for constructing the boxPlanner. If you place for example two elements one after another, so the left element has no right wall. However, the right element has a left wall.
|
|
1684
|
-
* Futhermore, there are options, that are applied only to specific elements.
|
|
1682
|
+
/**
|
|
1683
|
+
* This object holds all the information for constructing the boxPlanner. If you place for example two elements one after another, so the left element has no right wall. However, the right element has a left wall.
|
|
1684
|
+
* Futhermore, there are options, that are applied only to specific elements.
|
|
1685
1685
|
*/
|
|
1686
1686
|
_defineProperty(this, "constructionRules", void 0);
|
|
1687
1687
|
_defineProperty(this, "constructionRulesLoaded", void 0);
|
|
1688
1688
|
_defineProperty(this, "hideOptionsForConstruction", void 0);
|
|
1689
1689
|
//This saves an array of options per elementID that are hidden due to construction rules
|
|
1690
1690
|
_defineProperty(this, "partlistHelper", void 0);
|
|
1691
|
-
/**
|
|
1692
|
-
* This function looks what value the option has in the current OptionHandler
|
|
1693
|
-
* @param elementId ElementId
|
|
1694
|
-
* @param opt OptionKey
|
|
1691
|
+
/**
|
|
1692
|
+
* This function looks what value the option has in the current OptionHandler
|
|
1693
|
+
* @param elementId ElementId
|
|
1694
|
+
* @param opt OptionKey
|
|
1695
1695
|
*/
|
|
1696
1696
|
_defineProperty(this, "getOptionVal", function (elementId, opt, optionHandler) {
|
|
1697
1697
|
if (optionHandler.has(elementId)) {
|
|
@@ -1703,12 +1703,12 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1703
1703
|
var opv = _this.getValueOfOptionOfArticle(elementId, opt);
|
|
1704
1704
|
return opv != undefined ? opv : '';
|
|
1705
1705
|
});
|
|
1706
|
-
/**
|
|
1707
|
-
* this fuction check is an element has an option and retuns a bool
|
|
1708
|
-
* @param elementId ElementId
|
|
1709
|
-
* @param opt OptionKey
|
|
1710
|
-
* @param optionHandler
|
|
1711
|
-
* @returns
|
|
1706
|
+
/**
|
|
1707
|
+
* this fuction check is an element has an option and retuns a bool
|
|
1708
|
+
* @param elementId ElementId
|
|
1709
|
+
* @param opt OptionKey
|
|
1710
|
+
* @param optionHandler
|
|
1711
|
+
* @returns
|
|
1712
1712
|
*/
|
|
1713
1713
|
_defineProperty(this, "hasOptionValue", function (elementId, opt, optionHandler) {
|
|
1714
1714
|
if (optionHandler.has(elementId)) {
|
|
@@ -1719,8 +1719,8 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1719
1719
|
var opv = _this.getValueOfOptionOfArticle(elementId, opt);
|
|
1720
1720
|
return !!opv;
|
|
1721
1721
|
});
|
|
1722
|
-
/**
|
|
1723
|
-
* This function sets te OptionValue in the optionHandler and hideOptiosnForConstruction Information
|
|
1722
|
+
/**
|
|
1723
|
+
* This function sets te OptionValue in the optionHandler and hideOptiosnForConstruction Information
|
|
1724
1724
|
*/
|
|
1725
1725
|
_defineProperty(this, "setOptionValue", function (elementId, option, optionValue, optionHandler) {
|
|
1726
1726
|
var _optionHandler$get;
|
|
@@ -1734,9 +1734,9 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1734
1734
|
}
|
|
1735
1735
|
}
|
|
1736
1736
|
});
|
|
1737
|
-
/**
|
|
1738
|
-
* This function returns true, if the element has a bottom Plate. Elements with bottom plate are e.g. Offenes Fach oder Schubladen.
|
|
1739
|
-
* Elements without bottom plate are "Garderobe" or "Offenes Fach ohne Boden"
|
|
1737
|
+
/**
|
|
1738
|
+
* This function returns true, if the element has a bottom Plate. Elements with bottom plate are e.g. Offenes Fach oder Schubladen.
|
|
1739
|
+
* Elements without bottom plate are "Garderobe" or "Offenes Fach ohne Boden"
|
|
1740
1740
|
*/
|
|
1741
1741
|
_defineProperty(this, "getElementHasBottomPlate", function (curElement, optionHandler) {
|
|
1742
1742
|
if (_this.constructionRules.knotInfo.elementsWithGroundPlate) {
|
|
@@ -1749,10 +1749,10 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1749
1749
|
}
|
|
1750
1750
|
return false;
|
|
1751
1751
|
});
|
|
1752
|
-
/**
|
|
1753
|
-
* This function returns true if the current element is a corner element
|
|
1754
|
-
* @param curElement
|
|
1755
|
-
* @param optionHandler
|
|
1752
|
+
/**
|
|
1753
|
+
* This function returns true if the current element is a corner element
|
|
1754
|
+
* @param curElement
|
|
1755
|
+
* @param optionHandler
|
|
1756
1756
|
*/
|
|
1757
1757
|
_defineProperty(this, "getElementIsCornerElement", function (curElement, optionHandler) {
|
|
1758
1758
|
return _this.constructionRules.hasCORNER && _this.arrayContainsValue(_this.constructionRules.knotInfo.cornerElements.onOPVs, _this.getOptionVal(curElement.getElementId(), _this.constructionRules.knotInfo.cornerElements.onOPT, optionHandler));
|
|
@@ -1764,11 +1764,11 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1764
1764
|
if (_this.getOptionVal(curElement.getElementId(), 'OPTELEMENT', optionHandler) == 'OPVECK_I') return 'INSIDE';else if (_this.getOptionVal(curElement.getElementId(), 'OPTELEMENT', optionHandler) == 'OPVECK_A') return 'OUTSIDE';
|
|
1765
1765
|
return 'NOCORNER';
|
|
1766
1766
|
});
|
|
1767
|
-
/**
|
|
1768
|
-
* This function returns true, if the element has a top plate. It has a top plate if it has no element on the top or the element on the top has a ground plate.
|
|
1769
|
-
* It has no top plate, if the element on top has no ground plate, like a "Garderobe"
|
|
1770
|
-
* @param curElement
|
|
1771
|
-
* @param optionHandler
|
|
1767
|
+
/**
|
|
1768
|
+
* This function returns true, if the element has a top plate. It has a top plate if it has no element on the top or the element on the top has a ground plate.
|
|
1769
|
+
* It has no top plate, if the element on top has no ground plate, like a "Garderobe"
|
|
1770
|
+
* @param curElement
|
|
1771
|
+
* @param optionHandler
|
|
1772
1772
|
*/
|
|
1773
1773
|
_defineProperty(this, "getElementHasTopPlate", function (curElement, boxPlannerGrid, optionHandler) {
|
|
1774
1774
|
if (boxPlannerGrid.getElementHasTopElement(curElement.getElementId())) {
|
|
@@ -1784,11 +1784,11 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1784
1784
|
this.partlistHelper = new BoxPlannerPartlistHelper(this.getOptionVal, this.setOptionValue, this.getElementHasBottomPlate, this.getElementIsCornerElement, this.getCornerType, this.getElementHasTopPlate, this.getElementIsGarderobeElement);
|
|
1785
1785
|
}
|
|
1786
1786
|
|
|
1787
|
-
/**
|
|
1788
|
-
* This function returns true if an array contains a specific value.
|
|
1789
|
-
* E.G. All unvalid options are separated using ; . This function now returns true, if a specific option is inside
|
|
1790
|
-
* @param rule
|
|
1791
|
-
* @param opt
|
|
1787
|
+
/**
|
|
1788
|
+
* This function returns true if an array contains a specific value.
|
|
1789
|
+
* E.G. All unvalid options are separated using ; . This function now returns true, if a specific option is inside
|
|
1790
|
+
* @param rule
|
|
1791
|
+
* @param opt
|
|
1792
1792
|
*/
|
|
1793
1793
|
return _createClass(ConstructionRulesHandler, [{
|
|
1794
1794
|
key: "arrayContainsValue",
|
|
@@ -1821,11 +1821,11 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1821
1821
|
}, {
|
|
1822
1822
|
key: "setOptionDoShow",
|
|
1823
1823
|
value:
|
|
1824
|
-
/**
|
|
1825
|
-
* This function sets a specific Option to be visible.
|
|
1826
|
-
* @param elementId The elementID of the target element
|
|
1827
|
-
* @param option The option that should be set to Visible
|
|
1828
|
-
* @param optionHandler The optionHandler that saves all optionChanges in order to fit the boxplannerLogic
|
|
1824
|
+
/**
|
|
1825
|
+
* This function sets a specific Option to be visible.
|
|
1826
|
+
* @param elementId The elementID of the target element
|
|
1827
|
+
* @param option The option that should be set to Visible
|
|
1828
|
+
* @param optionHandler The optionHandler that saves all optionChanges in order to fit the boxplannerLogic
|
|
1829
1829
|
*/
|
|
1830
1830
|
function setOptionDoShow(elementId, option, optionHandler) {
|
|
1831
1831
|
//DivaUtils.LOG.log("Update Box Planner Logic. SetOptionDoShow: elementID: " + elementId + "; Option: " + option);
|
|
@@ -1851,11 +1851,11 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
1851
1851
|
}
|
|
1852
1852
|
}
|
|
1853
1853
|
}
|
|
1854
|
-
/**
|
|
1855
|
-
* This function sets a specific Option to be hidden.
|
|
1856
|
-
* @param elementId The elementID of the target element
|
|
1857
|
-
* @param option The option that should be set to hidden
|
|
1858
|
-
* @param optionHandler The optionHandler that saves all optionChanges in order to fit the boxplannerLogic
|
|
1854
|
+
/**
|
|
1855
|
+
* This function sets a specific Option to be hidden.
|
|
1856
|
+
* @param elementId The elementID of the target element
|
|
1857
|
+
* @param option The option that should be set to hidden
|
|
1858
|
+
* @param optionHandler The optionHandler that saves all optionChanges in order to fit the boxplannerLogic
|
|
1859
1859
|
*/
|
|
1860
1860
|
}, {
|
|
1861
1861
|
key: "setOptionDoHide",
|
|
@@ -2110,12 +2110,12 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2110
2110
|
return messageForView;
|
|
2111
2111
|
}
|
|
2112
2112
|
|
|
2113
|
-
/**
|
|
2114
|
-
* Eg. height or width changed
|
|
2115
|
-
* @param boxPlannerGrid
|
|
2116
|
-
* @param changedOPTs
|
|
2117
|
-
* @param onSelectionChangedElementId
|
|
2118
|
-
* @param optionHandler
|
|
2113
|
+
/**
|
|
2114
|
+
* Eg. height or width changed
|
|
2115
|
+
* @param boxPlannerGrid
|
|
2116
|
+
* @param changedOPTs
|
|
2117
|
+
* @param onSelectionChangedElementId
|
|
2118
|
+
* @param optionHandler
|
|
2119
2119
|
*/
|
|
2120
2120
|
}, {
|
|
2121
2121
|
key: "doCorrectAffectedElementsByOption",
|
|
@@ -2180,9 +2180,9 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2180
2180
|
}
|
|
2181
2181
|
}
|
|
2182
2182
|
|
|
2183
|
-
/*
|
|
2184
|
-
This function handles that only one Opt is visible. For Example if a Element Right is already shown, then the element right is hidden.
|
|
2185
|
-
However, one of both is always visible.
|
|
2183
|
+
/*
|
|
2184
|
+
This function handles that only one Opt is visible. For Example if a Element Right is already shown, then the element right is hidden.
|
|
2185
|
+
However, one of both is always visible.
|
|
2186
2186
|
*/
|
|
2187
2187
|
}, {
|
|
2188
2188
|
key: "handleVisibility_SHOW_HIDE",
|
|
@@ -2199,9 +2199,9 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2199
2199
|
}
|
|
2200
2200
|
}
|
|
2201
2201
|
|
|
2202
|
-
/*
|
|
2203
|
-
This function handles that only one Opt is visible when the options depend on a element on the front and backside.
|
|
2204
|
-
This is only called once for the element on the backside
|
|
2202
|
+
/*
|
|
2203
|
+
This function handles that only one Opt is visible when the options depend on a element on the front and backside.
|
|
2204
|
+
This is only called once for the element on the backside
|
|
2205
2205
|
*/
|
|
2206
2206
|
}, {
|
|
2207
2207
|
key: "handleBacksideVisibility_SHOW_HIDE",
|
|
@@ -2223,11 +2223,11 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2223
2223
|
}
|
|
2224
2224
|
}
|
|
2225
2225
|
|
|
2226
|
-
/**
|
|
2227
|
-
* This function forces both options to hide IF both options are visible. if only one Option is visible, nothing happens.
|
|
2228
|
-
* @param {*} curArticle
|
|
2229
|
-
* @param {*} neighborArticle
|
|
2230
|
-
* @param {*} rule
|
|
2226
|
+
/**
|
|
2227
|
+
* This function forces both options to hide IF both options are visible. if only one Option is visible, nothing happens.
|
|
2228
|
+
* @param {*} curArticle
|
|
2229
|
+
* @param {*} neighborArticle
|
|
2230
|
+
* @param {*} rule
|
|
2231
2231
|
*/
|
|
2232
2232
|
}, {
|
|
2233
2233
|
key: "handleVisibiliy_HIDE_HIDE",
|
|
@@ -2344,10 +2344,10 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2344
2344
|
}
|
|
2345
2345
|
}
|
|
2346
2346
|
|
|
2347
|
-
/**
|
|
2348
|
-
* This function corrects the back after everything is set (Default + force options)
|
|
2349
|
-
* @param boxPlannerGrid
|
|
2350
|
-
* @param curElement
|
|
2347
|
+
/**
|
|
2348
|
+
* This function corrects the back after everything is set (Default + force options)
|
|
2349
|
+
* @param boxPlannerGrid
|
|
2350
|
+
* @param curElement
|
|
2351
2351
|
*/
|
|
2352
2352
|
}, {
|
|
2353
2353
|
key: "correctBack",
|
|
@@ -2652,10 +2652,10 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2652
2652
|
var neighbourElement = boxPlannerGrid.getNeighborElement(curElemPos.col, curElemPos.row, tempComplementDir, curElemPos.backside);
|
|
2653
2653
|
if (neighbourElement != undefined) {
|
|
2654
2654
|
//Check complementary option
|
|
2655
|
-
/*
|
|
2656
|
-
if (forceOptValue == "dShow") {
|
|
2657
|
-
//beim aktuellen artikel MUSS es gesetzt werden
|
|
2658
|
-
this.setOptionDoShow(curElementId, optName, optionHandler);
|
|
2655
|
+
/*
|
|
2656
|
+
if (forceOptValue == "dShow") {
|
|
2657
|
+
//beim aktuellen artikel MUSS es gesetzt werden
|
|
2658
|
+
this.setOptionDoShow(curElementId, optName, optionHandler);
|
|
2659
2659
|
}*/
|
|
2660
2660
|
var rulesForNeighborArticle = this.getCurOptionBasedConstructionRules(neighbourElement.ElementId, optionHandler);
|
|
2661
2661
|
var complementOptName = optInfo.complementOPT;
|
|
@@ -2770,17 +2770,17 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2770
2770
|
}
|
|
2771
2771
|
}
|
|
2772
2772
|
|
|
2773
|
-
/*
|
|
2774
|
-
"_comment_correctRetailArticleNumberByRule": "Specifies that SAP numbers have to be switched when all Elements (range=global) satisfy the rule",
|
|
2775
|
-
"range": "global",
|
|
2776
|
-
"rule": "OPTFARBE_RAHMEN=OPVCHROM&OPTFARBE=OPVWEISS",
|
|
2777
|
-
"retailArticleRules": [
|
|
2778
|
-
{
|
|
2779
|
-
"origRetailArticleNr": 91194,
|
|
2780
|
-
"origPrefix": "SAP",
|
|
2781
|
-
"newRetailArticleNr": 90771,
|
|
2782
|
-
"newPrefix": "SAP"
|
|
2783
|
-
},
|
|
2773
|
+
/*
|
|
2774
|
+
"_comment_correctRetailArticleNumberByRule": "Specifies that SAP numbers have to be switched when all Elements (range=global) satisfy the rule",
|
|
2775
|
+
"range": "global",
|
|
2776
|
+
"rule": "OPTFARBE_RAHMEN=OPVCHROM&OPTFARBE=OPVWEISS",
|
|
2777
|
+
"retailArticleRules": [
|
|
2778
|
+
{
|
|
2779
|
+
"origRetailArticleNr": 91194,
|
|
2780
|
+
"origPrefix": "SAP",
|
|
2781
|
+
"newRetailArticleNr": 90771,
|
|
2782
|
+
"newPrefix": "SAP"
|
|
2783
|
+
},
|
|
2784
2784
|
*/
|
|
2785
2785
|
}, {
|
|
2786
2786
|
key: "correctNeighborCustomOLTs",
|
|
@@ -2844,15 +2844,14 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2844
2844
|
|
|
2845
2845
|
//Die gleiche Option kann sowohl nach rechts als auch nach oben gesetzt werden (Rahmen rechts oben). Wenn das der Fall ist, darf wenn es rechts keinen Nachbarn gibt nicht mit doShow überschrieben werden, wenn es vorher bei TOP versteckt wurde
|
|
2846
2846
|
//Deshalb darf es nicht angeschalten werden, wenn es in der gleichen Runde ausgeschalten wurde
|
|
2847
|
-
/*
|
|
2848
|
-
Diese Funktion korrigiert alle sogenannten Construction Options. Beim Planer dürfen zwei nebeneinanderliegenden Elemente nicht jeweils eine Wand rechts und das daneben eine Wand links haben.
|
|
2849
|
-
Dann würden nämlich zwei Wände nebeneinander liegen.
|
|
2850
|
-
Des Weiteren kümmert sich die Funktion darum, dass Füße nur auf der untersten ebene zu sehen sind.
|
|
2851
|
-
Generell wird hier das constuctionRules Objekt evaluiert und ausgewertet.
|
|
2852
|
-
Das Ergebnis wird direkt in den Optionen der Artikel abgepseichert.
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
*/
|
|
2847
|
+
/*
|
|
2848
|
+
Diese Funktion korrigiert alle sogenannten Construction Options. Beim Planer dürfen zwei nebeneinanderliegenden Elemente nicht jeweils eine Wand rechts und das daneben eine Wand links haben.
|
|
2849
|
+
Dann würden nämlich zwei Wände nebeneinander liegen.
|
|
2850
|
+
Des Weiteren kümmert sich die Funktion darum, dass Füße nur auf der untersten ebene zu sehen sind.
|
|
2851
|
+
Generell wird hier das constuctionRules Objekt evaluiert und ausgewertet.
|
|
2852
|
+
Das Ergebnis wird direkt in den Optionen der Artikel abgepseichert.
|
|
2853
|
+
onSelectionChangedArticle: Das ist der Articel der ausgewählt war, als die Option geändert wurde
|
|
2854
|
+
*/
|
|
2856
2855
|
}, {
|
|
2857
2856
|
key: "updateOptionLogicBoxPlanner",
|
|
2858
2857
|
value: function () {
|
|
@@ -2944,9 +2943,9 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2944
2943
|
}
|
|
2945
2944
|
return updateOptionLogicBoxPlanner;
|
|
2946
2945
|
}()
|
|
2947
|
-
/**
|
|
2948
|
-
* This function is called when an element is deleted. It deletes the saved constcutionInformation
|
|
2949
|
-
* @param elementId
|
|
2946
|
+
/**
|
|
2947
|
+
* This function is called when an element is deleted. It deletes the saved constcutionInformation
|
|
2948
|
+
* @param elementId
|
|
2950
2949
|
*/
|
|
2951
2950
|
}, {
|
|
2952
2951
|
key: "onElemDeleted",
|
|
@@ -2956,10 +2955,10 @@ var ConstructionRulesHandler = /*#__PURE__*/function () {
|
|
|
2956
2955
|
}
|
|
2957
2956
|
}
|
|
2958
2957
|
|
|
2959
|
-
/**
|
|
2960
|
-
* This function is called when an element is copied. The hideOptionsForConstruction information is copied from one element to the new one.
|
|
2961
|
-
* @param origElementId
|
|
2962
|
-
* @param newElementId
|
|
2958
|
+
/**
|
|
2959
|
+
* This function is called when an element is copied. The hideOptionsForConstruction information is copied from one element to the new one.
|
|
2960
|
+
* @param origElementId
|
|
2961
|
+
* @param newElementId
|
|
2963
2962
|
*/
|
|
2964
2963
|
}, {
|
|
2965
2964
|
key: "onElementCopy",
|
|
@@ -2997,8 +2996,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
2997
2996
|
this.getValueOfOptionOfArticle = getValueOfOptionOfArticle;
|
|
2998
2997
|
}
|
|
2999
2998
|
|
|
3000
|
-
/*
|
|
3001
|
-
* Gibt die Breite einer Spalte im Grid zurück. Die Spalte ist immer so breit wie das breiteste Element darin
|
|
2999
|
+
/*
|
|
3000
|
+
* Gibt die Breite einer Spalte im Grid zurück. Die Spalte ist immer so breit wie das breiteste Element darin
|
|
3002
3001
|
*/
|
|
3003
3002
|
return _createClass(BoxPlannerGrid, [{
|
|
3004
3003
|
key: "getGridColumnWidth",
|
|
@@ -3024,8 +3023,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3024
3023
|
}
|
|
3025
3024
|
return height;
|
|
3026
3025
|
}
|
|
3027
|
-
/*
|
|
3028
|
-
Deletes the Element on the specified grid Position. If there is no other element in the column, the whole column is deleted.
|
|
3026
|
+
/*
|
|
3027
|
+
Deletes the Element on the specified grid Position. If there is no other element in the column, the whole column is deleted.
|
|
3029
3028
|
*/
|
|
3030
3029
|
}, {
|
|
3031
3030
|
key: "deleteGridPos",
|
|
@@ -3068,17 +3067,17 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3068
3067
|
}
|
|
3069
3068
|
}
|
|
3070
3069
|
|
|
3071
|
-
/*
|
|
3072
|
-
private correctWorldPosInGrid(plannerElement: PlannerElementData) {
|
|
3073
|
-
//Braucht es das überhaupt?
|
|
3074
|
-
}
|
|
3070
|
+
/*
|
|
3071
|
+
private correctWorldPosInGrid(plannerElement: PlannerElementData) {
|
|
3072
|
+
//Braucht es das überhaupt?
|
|
3073
|
+
}
|
|
3075
3074
|
*/
|
|
3076
3075
|
|
|
3077
|
-
/**
|
|
3078
|
-
* This function returns the ElementID of the element at a specific GridPosition.
|
|
3079
|
-
* If there is no element at this position, the function returns undefined
|
|
3080
|
-
* @param curXPos
|
|
3081
|
-
* @param curYPos
|
|
3076
|
+
/**
|
|
3077
|
+
* This function returns the ElementID of the element at a specific GridPosition.
|
|
3078
|
+
* If there is no element at this position, the function returns undefined
|
|
3079
|
+
* @param curXPos
|
|
3080
|
+
* @param curYPos
|
|
3082
3081
|
*/
|
|
3083
3082
|
}, {
|
|
3084
3083
|
key: "getPlannerElementAtGridPos",
|
|
@@ -3090,10 +3089,10 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3090
3089
|
return undefined;
|
|
3091
3090
|
}
|
|
3092
3091
|
|
|
3093
|
-
/**
|
|
3094
|
-
* This function returns the index of an element by elementId in the grid.
|
|
3095
|
-
* It returns the column and row position in the grid and if it is in the front or backgrid
|
|
3096
|
-
* @param elementId
|
|
3092
|
+
/**
|
|
3093
|
+
* This function returns the index of an element by elementId in the grid.
|
|
3094
|
+
* It returns the column and row position in the grid and if it is in the front or backgrid
|
|
3095
|
+
* @param elementId
|
|
3097
3096
|
*/
|
|
3098
3097
|
}, {
|
|
3099
3098
|
key: "getIndexInGridByElementId",
|
|
@@ -3122,8 +3121,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3122
3121
|
backside: false
|
|
3123
3122
|
};
|
|
3124
3123
|
}
|
|
3125
|
-
/**
|
|
3126
|
-
* This function returns all elementIds that are inside the grid
|
|
3124
|
+
/**
|
|
3125
|
+
* This function returns all elementIds that are inside the grid
|
|
3127
3126
|
*/
|
|
3128
3127
|
}, {
|
|
3129
3128
|
key: "getAllElementIdsInGrid",
|
|
@@ -3163,8 +3162,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3163
3162
|
}
|
|
3164
3163
|
return allElements;
|
|
3165
3164
|
}
|
|
3166
|
-
/**
|
|
3167
|
-
* This function returns all elements In grid - from frontside and from backside
|
|
3165
|
+
/**
|
|
3166
|
+
* This function returns all elements In grid - from frontside and from backside
|
|
3168
3167
|
*/
|
|
3169
3168
|
}, {
|
|
3170
3169
|
key: "getAllElementsInGrid",
|
|
@@ -3190,9 +3189,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3190
3189
|
return curElementGrid[pos.col][pos.row];
|
|
3191
3190
|
}
|
|
3192
3191
|
|
|
3193
|
-
/**
|
|
3194
|
-
* Returns true if the element by ElementId is in the bottomLeft corner of the grid
|
|
3195
|
-
* @param elementId
|
|
3192
|
+
/**
|
|
3193
|
+
* Returns true if the element by ElementId is in the bottomLeft corner of the grid
|
|
3194
|
+
* @param elementId
|
|
3196
3195
|
*/
|
|
3197
3196
|
}, {
|
|
3198
3197
|
key: "getElementIsFirstInGrid",
|
|
@@ -3201,9 +3200,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3201
3200
|
return pos.col == 0 && pos.row == 0 && !pos.backside;
|
|
3202
3201
|
}
|
|
3203
3202
|
|
|
3204
|
-
/**
|
|
3205
|
-
* Returns true if the element by ElementId is in the bottomLeft corner of the grid
|
|
3206
|
-
* @param elementId
|
|
3203
|
+
/**
|
|
3204
|
+
* Returns true if the element by ElementId is in the bottomLeft corner of the grid
|
|
3205
|
+
* @param elementId
|
|
3207
3206
|
*/
|
|
3208
3207
|
}, {
|
|
3209
3208
|
key: "getElementIsInLastCol",
|
|
@@ -3213,9 +3212,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3213
3212
|
return pos.col + 1 == curElementGrid.length;
|
|
3214
3213
|
}
|
|
3215
3214
|
|
|
3216
|
-
/**
|
|
3217
|
-
* returns true if the element has another element on top
|
|
3218
|
-
* @param elementId
|
|
3215
|
+
/**
|
|
3216
|
+
* returns true if the element has another element on top
|
|
3217
|
+
* @param elementId
|
|
3219
3218
|
*/
|
|
3220
3219
|
}, {
|
|
3221
3220
|
key: "getElementHasTopElement",
|
|
@@ -3225,9 +3224,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3225
3224
|
if (curElementGrid[pos.col].length > pos.row + 1) return true;
|
|
3226
3225
|
return false;
|
|
3227
3226
|
}
|
|
3228
|
-
/**
|
|
3229
|
-
* returns the element on the top of the current element
|
|
3230
|
-
* @param elementId
|
|
3227
|
+
/**
|
|
3228
|
+
* returns the element on the top of the current element
|
|
3229
|
+
* @param elementId
|
|
3231
3230
|
*/
|
|
3232
3231
|
}, {
|
|
3233
3232
|
key: "getTopElement",
|
|
@@ -3238,9 +3237,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3238
3237
|
return undefined;
|
|
3239
3238
|
}
|
|
3240
3239
|
|
|
3241
|
-
/**
|
|
3242
|
-
* returns the element on the top right of the current element
|
|
3243
|
-
* @param elementId
|
|
3240
|
+
/**
|
|
3241
|
+
* returns the element on the top right of the current element
|
|
3242
|
+
* @param elementId
|
|
3244
3243
|
*/
|
|
3245
3244
|
}, {
|
|
3246
3245
|
key: "getTopRightElement",
|
|
@@ -3251,9 +3250,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3251
3250
|
return undefined;
|
|
3252
3251
|
}
|
|
3253
3252
|
|
|
3254
|
-
/**
|
|
3255
|
-
* returns the element on the top left of the current element
|
|
3256
|
-
* @param elementId
|
|
3253
|
+
/**
|
|
3254
|
+
* returns the element on the top left of the current element
|
|
3255
|
+
* @param elementId
|
|
3257
3256
|
*/
|
|
3258
3257
|
}, {
|
|
3259
3258
|
key: "getTopLeftElement",
|
|
@@ -3263,9 +3262,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3263
3262
|
if (pos.col > 0 && curElementGrid[pos.col - 1][pos.row - 1] != undefined) return curElementGrid[pos.col - 1][pos.row - 1];
|
|
3264
3263
|
return undefined;
|
|
3265
3264
|
}
|
|
3266
|
-
/**
|
|
3267
|
-
* returns true if the element has another element on the bottom
|
|
3268
|
-
* @param elementId
|
|
3265
|
+
/**
|
|
3266
|
+
* returns true if the element has another element on the bottom
|
|
3267
|
+
* @param elementId
|
|
3269
3268
|
*/
|
|
3270
3269
|
}, {
|
|
3271
3270
|
key: "getElementHasBottomElement",
|
|
@@ -3274,9 +3273,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3274
3273
|
if (pos.row - 1 >= 0) return true;
|
|
3275
3274
|
return false;
|
|
3276
3275
|
}
|
|
3277
|
-
/**
|
|
3278
|
-
* returns the element on the bottom of the current element
|
|
3279
|
-
* @param elementId
|
|
3276
|
+
/**
|
|
3277
|
+
* returns the element on the bottom of the current element
|
|
3278
|
+
* @param elementId
|
|
3280
3279
|
*/
|
|
3281
3280
|
}, {
|
|
3282
3281
|
key: "getBottomElement",
|
|
@@ -3286,9 +3285,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3286
3285
|
if (pos.row - 1 >= 0) return curElementGrid[pos.col][pos.row - 1];
|
|
3287
3286
|
return undefined;
|
|
3288
3287
|
}
|
|
3289
|
-
/**
|
|
3290
|
-
* returns true if the element has another element on its right side
|
|
3291
|
-
* @param elementId
|
|
3288
|
+
/**
|
|
3289
|
+
* returns true if the element has another element on its right side
|
|
3290
|
+
* @param elementId
|
|
3292
3291
|
*/
|
|
3293
3292
|
}, {
|
|
3294
3293
|
key: "getElementHasRightElement",
|
|
@@ -3311,9 +3310,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3311
3310
|
return undefined;
|
|
3312
3311
|
}
|
|
3313
3312
|
|
|
3314
|
-
/**
|
|
3315
|
-
* returns true if the element has another element on its left side
|
|
3316
|
-
* @param elementId
|
|
3313
|
+
/**
|
|
3314
|
+
* returns true if the element has another element on its left side
|
|
3315
|
+
* @param elementId
|
|
3317
3316
|
*/
|
|
3318
3317
|
}, {
|
|
3319
3318
|
key: "getElementHasLeftElement",
|
|
@@ -3329,9 +3328,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3329
3328
|
if (pos.col > 0 && this.getPlannerElementAtGridPos(pos.col - 1, pos.row, pos.backside) != undefined) return this.getPlannerElementAtGridPos(pos.col - 1, pos.row, pos.backside);
|
|
3330
3329
|
return undefined;
|
|
3331
3330
|
}
|
|
3332
|
-
/*
|
|
3333
|
-
returns all Elements in the column.
|
|
3334
|
-
index: index of the column in the grid
|
|
3331
|
+
/*
|
|
3332
|
+
returns all Elements in the column.
|
|
3333
|
+
index: index of the column in the grid
|
|
3335
3334
|
*/
|
|
3336
3335
|
}, {
|
|
3337
3336
|
key: "getAllElementsInColumn",
|
|
@@ -3345,8 +3344,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3345
3344
|
return curElementGrid.length > index ? result : undefined;
|
|
3346
3345
|
}
|
|
3347
3346
|
|
|
3348
|
-
/**
|
|
3349
|
-
* This function returns the count of columns in the grid
|
|
3347
|
+
/**
|
|
3348
|
+
* This function returns the count of columns in the grid
|
|
3350
3349
|
*/
|
|
3351
3350
|
}, {
|
|
3352
3351
|
key: "getColumnCount",
|
|
@@ -3354,9 +3353,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3354
3353
|
return this.plannedElementGrid.length;
|
|
3355
3354
|
}
|
|
3356
3355
|
|
|
3357
|
-
/**
|
|
3358
|
-
* This function returns the count of rows in a columns
|
|
3359
|
-
* @param colIndex
|
|
3356
|
+
/**
|
|
3357
|
+
* This function returns the count of rows in a columns
|
|
3358
|
+
* @param colIndex
|
|
3360
3359
|
*/
|
|
3361
3360
|
}, {
|
|
3362
3361
|
key: "getRowCount",
|
|
@@ -3364,9 +3363,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3364
3363
|
return this.plannedElementGrid[colIndex].length;
|
|
3365
3364
|
}
|
|
3366
3365
|
|
|
3367
|
-
/*
|
|
3368
|
-
returns all Elements in the row of the grid.
|
|
3369
|
-
index: index of the row in the grid
|
|
3366
|
+
/*
|
|
3367
|
+
returns all Elements in the row of the grid.
|
|
3368
|
+
index: index of the row in the grid
|
|
3370
3369
|
*/
|
|
3371
3370
|
}, {
|
|
3372
3371
|
key: "getAllElementsInRow",
|
|
@@ -3379,8 +3378,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3379
3378
|
return allElements;
|
|
3380
3379
|
}
|
|
3381
3380
|
|
|
3382
|
-
/**
|
|
3383
|
-
* This function returns the size of the highes row element over all columns
|
|
3381
|
+
/**
|
|
3382
|
+
* This function returns the size of the highes row element over all columns
|
|
3384
3383
|
*/
|
|
3385
3384
|
}, {
|
|
3386
3385
|
key: "getSizeOfHighesRow",
|
|
@@ -3393,11 +3392,11 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3393
3392
|
return highestRow;
|
|
3394
3393
|
}
|
|
3395
3394
|
|
|
3396
|
-
/**
|
|
3397
|
-
* This function returns the neighbor element in the grid
|
|
3398
|
-
* @param curXPos
|
|
3399
|
-
* @param curYPos
|
|
3400
|
-
* @param dir
|
|
3395
|
+
/**
|
|
3396
|
+
* This function returns the neighbor element in the grid
|
|
3397
|
+
* @param curXPos
|
|
3398
|
+
* @param curYPos
|
|
3399
|
+
* @param dir
|
|
3401
3400
|
*/
|
|
3402
3401
|
}, {
|
|
3403
3402
|
key: "getNeighborElement",
|
|
@@ -3455,9 +3454,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3455
3454
|
return oppositeElements;
|
|
3456
3455
|
}
|
|
3457
3456
|
|
|
3458
|
-
/**
|
|
3459
|
-
* this function returns the size Information of the set.
|
|
3460
|
-
* Because of the fact that the backside is always opposite of the front side - only the front side is used for calculation
|
|
3457
|
+
/**
|
|
3458
|
+
* this function returns the size Information of the set.
|
|
3459
|
+
* Because of the fact that the backside is always opposite of the front side - only the front side is used for calculation
|
|
3461
3460
|
*/
|
|
3462
3461
|
}, {
|
|
3463
3462
|
key: "getSizeOfWholeSet",
|
|
@@ -3484,8 +3483,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3484
3483
|
return new Vector3(width, height, depth);
|
|
3485
3484
|
}
|
|
3486
3485
|
|
|
3487
|
-
/**
|
|
3488
|
-
* Returns all Elements that are under the specified element
|
|
3486
|
+
/**
|
|
3487
|
+
* Returns all Elements that are under the specified element
|
|
3489
3488
|
*/
|
|
3490
3489
|
}, {
|
|
3491
3490
|
key: "getAllElementsDown",
|
|
@@ -3611,12 +3610,12 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3611
3610
|
}
|
|
3612
3611
|
}
|
|
3613
3612
|
|
|
3614
|
-
/**
|
|
3615
|
-
* This function deletes an Element from the grid.
|
|
3616
|
-
* If backsideModule is active, than the oppsite Element is deleted as well
|
|
3617
|
-
* If the boxPlanner_backside switch deletion type is set, do not delete the opposite element
|
|
3618
|
-
* @param elementId
|
|
3619
|
-
* @returns all elements that are deleted - it can happen that multiple elements get deleted
|
|
3613
|
+
/**
|
|
3614
|
+
* This function deletes an Element from the grid.
|
|
3615
|
+
* If backsideModule is active, than the oppsite Element is deleted as well
|
|
3616
|
+
* If the boxPlanner_backside switch deletion type is set, do not delete the opposite element
|
|
3617
|
+
* @param elementId
|
|
3618
|
+
* @returns all elements that are deleted - it can happen that multiple elements get deleted
|
|
3620
3619
|
*/
|
|
3621
3620
|
}, {
|
|
3622
3621
|
key: "deleteElement",
|
|
@@ -3640,9 +3639,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3640
3639
|
return result;
|
|
3641
3640
|
}
|
|
3642
3641
|
|
|
3643
|
-
/**
|
|
3644
|
-
* This function updates the world position of all Elements in the grid.
|
|
3645
|
-
* First the world position of the front grid is computed. If the backside is active, it also computes the posNr of the elements on the backside.
|
|
3642
|
+
/**
|
|
3643
|
+
* This function updates the world position of all Elements in the grid.
|
|
3644
|
+
* First the world position of the front grid is computed. If the backside is active, it also computes the posNr of the elements on the backside.
|
|
3646
3645
|
*/
|
|
3647
3646
|
}, {
|
|
3648
3647
|
key: "updateWorldPosOfElements",
|
|
@@ -3700,9 +3699,9 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3700
3699
|
}
|
|
3701
3700
|
}
|
|
3702
3701
|
|
|
3703
|
-
/**
|
|
3704
|
-
* This function destroys the box Planner and its grid. It also destroys all plannerElements inside.
|
|
3705
|
-
* If the backside Module is active, also the backside module has to be updated
|
|
3702
|
+
/**
|
|
3703
|
+
* This function destroys the box Planner and its grid. It also destroys all plannerElements inside.
|
|
3704
|
+
* If the backside Module is active, also the backside module has to be updated
|
|
3706
3705
|
*/
|
|
3707
3706
|
}, {
|
|
3708
3707
|
key: "destroyBoxPlannerGrid",
|
|
@@ -3727,8 +3726,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3727
3726
|
this.backModulPlannedElementGrid = [];
|
|
3728
3727
|
}
|
|
3729
3728
|
}
|
|
3730
|
-
/**
|
|
3731
|
-
|
|
3729
|
+
/**
|
|
3730
|
+
|
|
3732
3731
|
*/
|
|
3733
3732
|
}, {
|
|
3734
3733
|
key: "getAllElementsInBacksideModuleGrid",
|
|
@@ -3742,8 +3741,8 @@ var BoxPlannerGrid = /*#__PURE__*/function () {
|
|
|
3742
3741
|
return elementsInGrid;
|
|
3743
3742
|
}
|
|
3744
3743
|
|
|
3745
|
-
/**
|
|
3746
|
-
* Destroys the backside module Grid and returns all Element ids inside the backside grid
|
|
3744
|
+
/**
|
|
3745
|
+
* Destroys the backside module Grid and returns all Element ids inside the backside grid
|
|
3747
3746
|
*/
|
|
3748
3747
|
}, {
|
|
3749
3748
|
key: "destroyBacksideModuleGrid",
|
|
@@ -4003,10 +4002,10 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4003
4002
|
return saveSet;
|
|
4004
4003
|
}
|
|
4005
4004
|
|
|
4006
|
-
/**
|
|
4007
|
-
* Add a planner Element (CoPY?)
|
|
4008
|
-
* @param basketID
|
|
4009
|
-
* @param params
|
|
4005
|
+
/**
|
|
4006
|
+
* Add a planner Element (CoPY?)
|
|
4007
|
+
* @param basketID
|
|
4008
|
+
* @param params
|
|
4010
4009
|
*/
|
|
4011
4010
|
}, {
|
|
4012
4011
|
key: "addPlannerElement",
|
|
@@ -4071,10 +4070,10 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4071
4070
|
}
|
|
4072
4071
|
return extendPlanner;
|
|
4073
4072
|
}()
|
|
4074
|
-
/**
|
|
4075
|
-
* Handles copyying the planner Element. it can happen that also other planner elements are influenced
|
|
4076
|
-
* @param articleCopyRelation Holds the relation - which element with elementID is copyed and has a new Article. ElementToCopyID -> BasketID of new Article
|
|
4077
|
-
* @param params
|
|
4073
|
+
/**
|
|
4074
|
+
* Handles copyying the planner Element. it can happen that also other planner elements are influenced
|
|
4075
|
+
* @param articleCopyRelation Holds the relation - which element with elementID is copyed and has a new Article. ElementToCopyID -> BasketID of new Article
|
|
4076
|
+
* @param params
|
|
4078
4077
|
*/
|
|
4079
4078
|
}, {
|
|
4080
4079
|
key: "copyPlannerElement",
|
|
@@ -4164,13 +4163,13 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4164
4163
|
value: function initIDM3DMeta(IDM3DCatCodex) {
|
|
4165
4164
|
LOG.debug('No IDM3D Planner for BoxPlanner');
|
|
4166
4165
|
}
|
|
4167
|
-
/**
|
|
4168
|
-
* This function returns all elements that are influenced by copying them.
|
|
4169
|
-
* In the box Planner all elements under the Element to copy are copied as well
|
|
4170
|
-
* If the boxPlanner has a backside element, it returns also the elements on the opposide. Depending if current element is on the front or back.
|
|
4171
|
-
* @param elementId
|
|
4172
|
-
* @param params
|
|
4173
|
-
* @returns the list of plannerElements that have to be copied .
|
|
4166
|
+
/**
|
|
4167
|
+
* This function returns all elements that are influenced by copying them.
|
|
4168
|
+
* In the box Planner all elements under the Element to copy are copied as well
|
|
4169
|
+
* If the boxPlanner has a backside element, it returns also the elements on the opposide. Depending if current element is on the front or back.
|
|
4170
|
+
* @param elementId
|
|
4171
|
+
* @param params
|
|
4172
|
+
* @returns the list of plannerElements that have to be copied .
|
|
4174
4173
|
*/
|
|
4175
4174
|
}, {
|
|
4176
4175
|
key: "getPlannerElementsInfluencedByCopy",
|
|
@@ -4205,11 +4204,11 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4205
4204
|
return allElementsToCopy;
|
|
4206
4205
|
}
|
|
4207
4206
|
|
|
4208
|
-
/**
|
|
4209
|
-
* Delete Box Planner element
|
|
4210
|
-
* If the box planner has an active backside, then it also deletes the opposite element
|
|
4211
|
-
* @param elementId ElementID of the element that should be deleted.
|
|
4212
|
-
* @returns elementId of the next to select element
|
|
4207
|
+
/**
|
|
4208
|
+
* Delete Box Planner element
|
|
4209
|
+
* If the box planner has an active backside, then it also deletes the opposite element
|
|
4210
|
+
* @param elementId ElementID of the element that should be deleted.
|
|
4211
|
+
* @returns elementId of the next to select element
|
|
4213
4212
|
*/
|
|
4214
4213
|
}, {
|
|
4215
4214
|
key: "deletePlannerElement",
|
|
@@ -4284,8 +4283,8 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4284
4283
|
}
|
|
4285
4284
|
return deletePlannerElement;
|
|
4286
4285
|
}()
|
|
4287
|
-
/**
|
|
4288
|
-
* Get all Planner Elements used for View
|
|
4286
|
+
/**
|
|
4287
|
+
* Get all Planner Elements used for View
|
|
4289
4288
|
*/
|
|
4290
4289
|
)
|
|
4291
4290
|
}, {
|
|
@@ -4324,8 +4323,8 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4324
4323
|
value: function getDockedGroups() {
|
|
4325
4324
|
return [this.boxPlannerGrid.getAllElementIdsInGrid()];
|
|
4326
4325
|
}
|
|
4327
|
-
/**
|
|
4328
|
-
* Get Bounding Box of 2D Planning
|
|
4326
|
+
/**
|
|
4327
|
+
* Get Bounding Box of 2D Planning
|
|
4329
4328
|
*/
|
|
4330
4329
|
}, {
|
|
4331
4330
|
key: "getBoundingBox",
|
|
@@ -4333,15 +4332,15 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4333
4332
|
LOG.warn('BoxPlanner - get2DViewPlannerBoundingBox not implemented yet', 'WC_0012');
|
|
4334
4333
|
return new BoundingBox();
|
|
4335
4334
|
}
|
|
4336
|
-
/**
|
|
4337
|
-
* This function is called every time the transformation of a planner Element is changed in the view. For example when the user moves the 2D Shape around.
|
|
4338
|
-
* When it is the first action, all AVL and AVR docking Points are removed. When it is the last action "END" then the planner is updated an dockable docking points are searched.
|
|
4339
|
-
*
|
|
4340
|
-
* @param elementId
|
|
4341
|
-
* @param deltaMove
|
|
4342
|
-
* @param deltaAngleDeg
|
|
4343
|
-
* @param transState
|
|
4344
|
-
* @param autoDockingDistance //Gibt an in welchem Radius automatisch gedockt werden muss
|
|
4335
|
+
/**
|
|
4336
|
+
* This function is called every time the transformation of a planner Element is changed in the view. For example when the user moves the 2D Shape around.
|
|
4337
|
+
* When it is the first action, all AVL and AVR docking Points are removed. When it is the last action "END" then the planner is updated an dockable docking points are searched.
|
|
4338
|
+
*
|
|
4339
|
+
* @param elementId
|
|
4340
|
+
* @param deltaMove
|
|
4341
|
+
* @param deltaAngleDeg
|
|
4342
|
+
* @param transState
|
|
4343
|
+
* @param autoDockingDistance //Gibt an in welchem Radius automatisch gedockt werden muss
|
|
4345
4344
|
*/
|
|
4346
4345
|
}, {
|
|
4347
4346
|
key: "updatePlannerTrans",
|
|
@@ -4352,9 +4351,9 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4352
4351
|
return false;
|
|
4353
4352
|
}
|
|
4354
4353
|
|
|
4355
|
-
/**
|
|
4356
|
-
* This function updates the Planner. It is called after a configuration changed.
|
|
4357
|
-
* @returns it returns all elementIds that should be deleted
|
|
4354
|
+
/**
|
|
4355
|
+
* This function updates the Planner. It is called after a configuration changed.
|
|
4356
|
+
* @returns it returns all elementIds that should be deleted
|
|
4358
4357
|
*/
|
|
4359
4358
|
}, {
|
|
4360
4359
|
key: "updatePlanner",
|
|
@@ -4510,8 +4509,8 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4510
4509
|
}
|
|
4511
4510
|
return updatePlanner;
|
|
4512
4511
|
}()
|
|
4513
|
-
/*
|
|
4514
|
-
This function returns all informations that are needed to visualize the set in 3D
|
|
4512
|
+
/*
|
|
4513
|
+
This function returns all informations that are needed to visualize the set in 3D
|
|
4515
4514
|
*/
|
|
4516
4515
|
)
|
|
4517
4516
|
}, {
|
|
@@ -4566,8 +4565,8 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4566
4565
|
return this.plannerID;
|
|
4567
4566
|
}
|
|
4568
4567
|
|
|
4569
|
-
/**
|
|
4570
|
-
* This function returns the position information for each element. The infomration is returned as an object with elementId: posNr.
|
|
4568
|
+
/**
|
|
4569
|
+
* This function returns the position information for each element. The infomration is returned as an object with elementId: posNr.
|
|
4571
4570
|
*/
|
|
4572
4571
|
}, {
|
|
4573
4572
|
key: "getElementPosInfo",
|
|
@@ -4597,8 +4596,8 @@ var DivaBoxPlanner = /*#__PURE__*/function () {
|
|
|
4597
4596
|
// this.plannerBoundingBox.calcPlannerBoundingBox(this.getAllPlannerElements());
|
|
4598
4597
|
}
|
|
4599
4598
|
|
|
4600
|
-
/**
|
|
4601
|
-
* The planning is completed if at least one element is planned
|
|
4599
|
+
/**
|
|
4600
|
+
* The planning is completed if at least one element is planned
|
|
4602
4601
|
*/
|
|
4603
4602
|
}, {
|
|
4604
4603
|
key: "getPlanningIsComplete",
|