@colijnit/transaction 256.1.28 → 256.1.29
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/bundles/colijnit-transaction.umd.js +279 -109
- package/bundles/colijnit-transaction.umd.js.map +1 -1
- package/colijnit-transaction.metadata.json +1 -1
- package/esm2015/lib/component/core/base/service/transaction-header.service.js +13 -1
- package/esm2015/lib/component/core/base/transaction-base.component.js +1 -5
- package/esm2015/lib/component/core/base/transaction-header-base.component.js +7 -1
- package/esm2015/lib/component/core/base/transaction-line-base.component.js +7 -1
- package/esm2015/lib/component/transaction-card/transaction-card-invoice/transaction-card-invoice.component.js +2 -2
- package/esm2015/lib/component/transaction-create-wizard/transaction-create-wizard.component.js +50 -28
- package/esm2015/lib/component/transaction-internal/transaction-internal.component.js +15 -4
- package/esm2015/lib/component/transaction-line/transaction-invoice-line/transaction-invoice-line-base.component.js +31 -11
- package/esm2015/lib/component/transaction-line/transaction-invoice-line/transaction-invoice-line.component.js +4 -4
- package/esm2015/lib/component/transaction-line/transaction-order-delivery-line/transaction-order-delivery-line-base.component.js +31 -12
- package/esm2015/lib/component/transaction-line/transaction-order-delivery-line/transaction-order-delivery-line.component.js +4 -4
- package/esm2015/lib/component/transaction-quick-access/transaction-quick-access-invoice/transaction-quick-access-invoice.component.js +2 -2
- package/esm2015/lib/component/transaction-quick-access/transaction-quick-access-order-delivery/transaction-quick-access-order-delivery.component.js +2 -2
- package/esm2015/lib/enum/icon.enum.js +3 -1
- package/esm2015/lib/model/icon-svg.js +3 -1
- package/esm2015/lib/service/transaction-connector-adapter.service.js +19 -1
- package/esm2015/lib/service/transaction-connector.service.js +6 -1
- package/esm2015/lib/service/transaction-mapping.service.js +2 -2
- package/esm2015/lib/service/transaction.service.js +13 -1
- package/esm2015/lib/transaction-version.js +3 -3
- package/fesm2015/colijnit-transaction.js +261 -133
- package/fesm2015/colijnit-transaction.js.map +1 -1
- package/lib/component/core/base/service/transaction-header.service.d.ts +4 -0
- package/lib/component/core/base/transaction-base.component.d.ts +0 -4
- package/lib/component/core/base/transaction-header-base.component.d.ts +2 -0
- package/lib/component/core/base/transaction-line-base.component.d.ts +2 -0
- package/lib/component/transaction-create-wizard/transaction-create-wizard.component.d.ts +8 -3
- package/lib/component/transaction-internal/transaction-internal.component.d.ts +4 -2
- package/lib/component/transaction-line/transaction-invoice-line/transaction-invoice-line-base.component.d.ts +3 -1
- package/lib/component/transaction-line/transaction-order-delivery-line/transaction-order-delivery-line-base.component.d.ts +3 -1
- package/lib/component/transaction-service-overview/style/_layout.scss +28 -3
- package/lib/enum/icon.enum.d.ts +2 -0
- package/lib/service/transaction-connector-adapter.service.d.ts +1 -0
- package/lib/service/transaction-connector.service.d.ts +1 -0
- package/lib/service/transaction.service.d.ts +1 -0
- package/package.json +2 -2
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
function Version() {
|
|
34
34
|
this.name = "@colijnit/transaction";
|
|
35
35
|
this.description = "Colijn IT transaction package";
|
|
36
|
-
this.symVer = "256.1.
|
|
37
|
-
this.publishDate = "
|
|
36
|
+
this.symVer = "256.1.29";
|
|
37
|
+
this.publishDate = "18-12-2024 16:12:43";
|
|
38
38
|
}
|
|
39
39
|
return Version;
|
|
40
40
|
}());
|
|
@@ -795,6 +795,8 @@
|
|
|
795
795
|
Icon["RegularWarehouseClock"] = "regular_warehouse_clock";
|
|
796
796
|
Icon["Remark"] = "remark";
|
|
797
797
|
Icon["Resize"] = "resize";
|
|
798
|
+
Icon["ScrewdriverWrenchLight"] = "screwdriver_wrench_light";
|
|
799
|
+
Icon["ScrewdriverWrenchRegular"] = "screwdriver_wrench_regular";
|
|
798
800
|
Icon["ServiceCartRegular"] = "service_cart_regular";
|
|
799
801
|
Icon["ShareSolid"] = "share_solid";
|
|
800
802
|
Icon["SharpLightTruckMovingClock"] = "sharp_light_truck_moving_clock";
|
|
@@ -952,6 +954,8 @@
|
|
|
952
954
|
"regular_warehouse_clock": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 512\"><path d=\"M0 176.3c0-29.3 17.8-55.7 44.9-66.7L299 6.6c13.5-5.5 28.6-5.5 42.1 0l254 103c27.2 11 45 37.4 45 66.7L640 488l0-120 0-101.2c-12.9-18.3-29.2-34-48-46.3l0-44.2c0-9.8-5.9-18.6-15-22.2L323 51.1c-1.9-.8-4.1-.8-6 0L63 154.1c-9.1 3.7-15 12.5-15 22.2L48 488c0 13.3-10.7 24-24 24s-24-10.7-24-24L0 176.3zM96 232c0-22.1 17.9-40 40-40l360 0c-46.8 0-89.3 18.2-120.8 48L144 240l0 40 199.5 0c-8.5 14.8-15 30.9-19 48L144 328l0 48 176.2 0c.7 16.7 3.8 32.8 8.9 48L144 424l0 40 204.5 0c12.3 18.8 28 35.1 46.3 48l-274.5 0-.3 0c-13.3 0-24-10.7-24-24l0-256zM352 368c0-79.5 64.5-144 144-144s144 64.5 144 144s-64.5 144-144 144s-144-64.5-144-144zm128-64l0 64c0 8.8 7.2 16 16 16l48 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0 0-48c0-8.8-7.2-16-16-16s-16 7.2-16 16zm16-112l8 0c2.5 0 4.9 .2 7.2 .7c-5-.4-10.1-.7-15.2-.7z\"/></svg>",
|
|
953
955
|
"remark": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 30 30\"><g ><path d=\"M15,.93C6.72,.93,0,5.83,0,11.89c0,2.12,.84,4.09,2.27,5.77h-.16c.16,.1,.28,.22,.43,.32,.4,.44,.86,.85,1.35,1.24,3.07,3.75,.06,8.71-3.25,9.84,5.79-1.34,9.31-3.89,10.9-6.53,1.11,.19,2.27,.31,3.46,.31,8.28,0,15-4.91,15-10.96S23.28,.93,15,.93Z\" fill=\"#484f60\"/></g></svg>",
|
|
954
956
|
"resize": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 51 51\"><polygon points=\"1.1 49.9 1.1 30.6 7.8 37.3 37.3 8 30.6 1.3 49.9 1.3 49.9 20.6 43.2 13.9 13.7 43.2 20.5 49.9 1.1 49.9\" fill=\"#4d5050\"/></svg>",
|
|
957
|
+
"screwdriver_wrench_light": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path d=\"M64.7 34.6L160 107.9l0 52.1-52.1 0L34.6 64.7 64.7 34.6zM192 169.3c0-.4 0-.9 0-1.3l0-64c0-7.5-3.5-14.5-9.4-19L78.6 5C69.1-2.4 55.6-1.5 47 7L7 47c-8.5 8.5-9.4 22-2.1 31.6l80 104c4.5 5.9 11.6 9.4 19 9.4l64 0c.4 0 .9 0 1.3 0L271.2 293.9c-19.5 30-16.2 70.5 10.1 96.8l112 112c12.5 12.5 32.8 12.5 45.3 0l64-64c12.5-12.5 12.5-32.8 0-45.3l-112-112c-26.3-26.3-66.8-29.7-96.8-10.1L192 169.3zM304 304c17.7-17.7 46.3-17.7 64 0L480 416l-64 64L304 368c-17.7-17.7-17.7-46.3 0-64zM104 424a16 16 0 1 0 -32 0 16 16 0 1 0 32 0zM23.2 376.8C8.3 391.7 0 411.8 0 432.8C0 476.5 35.5 512 79.2 512c21 0 41.1-8.3 56-23.2L238.5 385.5c-5.7-11.2-9.3-23.1-10.9-35.3L112.1 465.7c-8.7 8.7-20.6 13.6-32.9 13.6c-25.7 0-46.6-20.8-46.6-46.6c0-12.3 4.9-24.2 13.6-32.9L189.1 257l-23.1-23.1L23.2 376.8zM479.4 160c0 44.8-23.1 84.1-58 106.8l23.5 23.5c40.7-29 67.2-76.6 67.2-130.3c0-24.8-5.7-48.3-15.7-69.3c-4.4-9.2-16.5-10.5-23.7-3.3l-67.9 67.9c-3 3-7.1 4.7-11.3 4.7L368 160c-8.8 0-16-7.2-16-16l0-25.4c0-4.2 1.7-8.3 4.7-11.3l67.9-67.9c7.2-7.2 5.9-19.3-3.3-23.7C400.3 5.7 376.8 0 352 0C296.1 0 246.9 28.6 218.3 72.1l26 20C266.8 56.3 306.7 32.6 352 32.6c10.3 0 20.2 1.2 29.7 3.5L333.6 84.2c-9.1 9.1-14.2 21.5-14.2 34.4l0 25.4c0 26.9 21.8 48.6 48.6 48.6l25.4 0c12.9 0 25.3-5.1 34.4-14.2l48.1-48.1c2.3 9.5 3.5 19.5 3.5 29.7z\"/></svg>",
|
|
958
|
+
"screwdriver_wrench_regular": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path d=\"M78.6 5C69.1-2.4 55.6-1.5 47 7L7 47c-8.5 8.5-9.4 22-2.1 31.6l80 104c4.5 5.9 11.6 9.4 19 9.4l54.1 0 109 109c-14.7 29-10 65.4 14.3 89.6l112 112c12.5 12.5 32.8 12.5 45.3 0l64-64c12.5-12.5 12.5-32.8 0-45.3l-112-112c-24.2-24.2-60.6-29-89.6-14.3l-109-109 0-54.1c0-7.5-3.5-14.5-9.4-19L78.6 5zM23.2 376.8C8.3 391.7 0 411.8 0 432.8C0 476.5 35.5 512 79.2 512c21 0 41.1-8.3 56-23.2L238.5 385.5c-8.9-17.6-12.8-37.1-11.6-56.3L101.3 454.9c-5.9 5.8-13.8 9.1-22.1 9.1C62 464 48 450 48 432.8c0-8.3 3.3-16.2 9.1-22.1L194.3 273.5l-33.9-33.9L23.2 376.8zM463.9 164c-1.4 38.9-22.6 72.8-53.8 91.8c1.1 1 2.1 2 3.1 3l31.6 31.6c40.7-29 67.2-76.6 67.2-130.3c0-24.8-5.7-48.3-15.7-69.3c-4.4-9.2-16.5-10.5-23.7-3.3l-67.9 67.9c-3 3-7.1 4.7-11.3 4.7L368 160c-8.8 0-16-7.2-16-16l0-25.4c0-4.2 1.7-8.3 4.7-11.3l67.9-67.9c7.2-7.2 5.9-19.3-3.3-23.7C400.3 5.7 376.8 0 352 0C294.7 0 244.4 30.1 216.2 75.4C221.2 84 224 93.8 224 104l0 40.8 16 16 0-.8c0-60.5 48-109.9 108-111.9L322.7 73.4s0 0 0 0c-12 12-18.7 28.3-18.7 45.3l0 25.4c0 35.3 28.7 64 64 64l25.4 0c17 0 33.3-6.7 45.3-18.7L463.9 164z\"/></svg>",
|
|
955
959
|
"service_cart_regular": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 512\"><path d=\"M64 24C64 10.7 74.7 0 88 0h45.5c22 0 41.5 12.8 50.6 32h411c26.3 0 45.5 25 38.6 50.4l-41 152.3c-8.5 31.4-37 53.3-69.5 53.3H234.7l5.4 28.5c2.2 11.3 12.1 19.5 23.6 19.5H552c13.3 0 24 10.7 24 24s-10.7 24-24 24H263.7c-34.6 0-64.3-24.6-70.7-58.5l-51.6-271c-.7-3.8-4-6.5-7.9-6.5H88C74.7 48 64 37.3 64 24zM225.6 240H523.2c10.9 0 20.4-7.3 23.2-17.8L584.7 80H195.1l30.5 160zM192 464a48 48 0 1 1 96 0 48 48 0 1 1 -96 0zm336-48a48 48 0 1 1 0 96 48 48 0 1 1 0-96zM24 96h80c13.3 0 24 10.7 24 24s-10.7 24-24 24H24c-13.3 0-24-10.7-24-24s10.7-24 24-24zm0 80h96c13.3 0 24 10.7 24 24s-10.7 24-24 24H24c-13.3 0-24-10.7-24-24s10.7-24 24-24zm0 80H136c13.3 0 24 10.7 24 24s-10.7 24-24 24H24c-13.3 0-24-10.7-24-24s10.7-24 24-24z\"/></svg>",
|
|
956
960
|
"share_solid": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path d=\"M503.7 226.2l-176 151.1c-15.38 13.3-39.69 2.545-39.69-18.16V272.1C132.9 274.3 66.06 312.8 111.4 457.8c5.031 16.09-14.41 28.56-28.06 18.62C39.59 444.6 0 383.8 0 322.3c0-152.2 127.4-184.4 288-186.3V56.02c0-20.67 24.28-31.46 39.69-18.16l176 151.1C514.8 199.4 514.8 216.6 503.7 226.2z\"/></svg>",
|
|
957
961
|
"sharp_light_truck_moving_clock": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 512\"><path d=\"M32 64l0 240 0 32c13.4-10 30-16 48-16c26.2 0 49.4 12.6 64 32c14.6-19.4 37.8-32 64-32c32.8 0 61 19.7 73.3 48c12.9 0 25.8 0 38.7 0c0 10.9 1 21.6 2.9 32c-11.6 0-23.3 0-34.9 0c0 44.2-35.8 80-80 80c-26.2 0-49.4-12.6-64-32c-14.6 19.4-37.8 32-64 32c-44.2 0-80-35.8-80-80c0-10.7 0-21.3 0-32c0-21.3 0-42.7 0-64C0 224 0 144 0 64C0 53.3 0 42.7 0 32c10.7 0 21.3 0 32 0c138.7 0 277.3 0 416 0c10.7 0 21.3 0 32 0c0 10.7 0 21.3 0 32c0 21.3 0 42.7 0 64c24 0 48 0 72 0c2.4 0 4.7 0 7.1 0c1.6 1.8 3.2 3.5 4.8 5.3c24 26.7 48 53.3 72 80c1.4 1.5 2.7 3.1 4.1 4.6c0 2 0 4.1 0 6.1c0 10.7 0 21.3 0 32c0 3.6 0 7.2 0 10.8c-11.7-16.6-26.2-31.1-42.8-42.8c1.8 0 3.6 0 5.3 0c-19.2-21.3-38.4-42.7-57.6-64c-21.6 0-43.3 0-64.9 0c0 10.9 0 21.8 0 32.7c-11 1-21.7 3-32 5.9c0-44.9 0-89.8 0-134.6c-138.7 0-277.3 0-416 0zM256 400c0-17.1-9.1-33-24-41.6s-33.1-8.6-48 0s-24 24.4-24 41.6s9.1 33 24 41.6s33.1 8.6 48 0s24-24.4 24-41.6zM80 448c17.1 0 33-9.1 41.6-24s8.6-33.1 0-48S97.1 352 80 352s-33 9.1-41.6 24s-8.6 33.1 0 48S62.9 448 80 448zm528-80c0-40-21.3-77-56-97s-77.3-20-112 0s-56 57-56 97s21.3 77 56 97s77.3 20 112 0s56-57 56-97zm-256 0c0-51.4 27.4-99 72-124.7s99.4-25.7 144 0s72 73.3 72 124.7s-27.4 99-72 124.7s-99.4 25.7-144 0S352 419.4 352 368zm160-64l0 48c10.7 0 21.3 0 32 0c5.3 0 10.7 0 16 0c0 10.7 0 21.3 0 32c-5.3 0-10.7 0-16 0c-16 0-32 0-48 0c-5.3 0-10.7 0-16 0c0-5.3 0-10.7 0-16c0-21.3 0-42.7 0-64c0-5.3 0-10.7 0-16c10.7 0 21.3 0 32 0c0 5.3 0 10.7 0 16z\"/></svg>",
|
|
@@ -4181,6 +4185,27 @@
|
|
|
4181
4185
|
});
|
|
4182
4186
|
});
|
|
4183
4187
|
};
|
|
4188
|
+
TransactionConnectorAdapterService.prototype.changeTransactionLineQuantitySelectNone = function (uuid) {
|
|
4189
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
4190
|
+
var _this = this;
|
|
4191
|
+
return __generator(this, function (_a) {
|
|
4192
|
+
return [2 /*return*/, new Promise(function (resolve, reject) {
|
|
4193
|
+
var request = {
|
|
4194
|
+
transactionUuid: uuid
|
|
4195
|
+
};
|
|
4196
|
+
return _this.connector.changeTransactionLineQuantitySelectNone(request).then(function (result) {
|
|
4197
|
+
if (result.validationResult && result.validationResult.success) {
|
|
4198
|
+
resolve(_this._boFactory.makeWithRawBackendData(transactionInfoResponse_bo.TransactionInfoResponse, result.resultObject));
|
|
4199
|
+
}
|
|
4200
|
+
else {
|
|
4201
|
+
_this._handleExceptionFromResponse(result);
|
|
4202
|
+
reject(null);
|
|
4203
|
+
}
|
|
4204
|
+
});
|
|
4205
|
+
})];
|
|
4206
|
+
});
|
|
4207
|
+
});
|
|
4208
|
+
};
|
|
4184
4209
|
TransactionConnectorAdapterService.prototype.changeTransactionLineCommissionCode = function (uuid, lineUuid, code) {
|
|
4185
4210
|
return __awaiter(this, void 0, void 0, function () {
|
|
4186
4211
|
var request, response;
|
|
@@ -9852,6 +9877,13 @@
|
|
|
9852
9877
|
});
|
|
9853
9878
|
});
|
|
9854
9879
|
};
|
|
9880
|
+
TransactionConnectorService.prototype.changeTransactionLineQuantitySelectNone = function (uuid) {
|
|
9881
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
9882
|
+
return __generator(this, function (_a) {
|
|
9883
|
+
return [2 /*return*/, this._adapterService.changeTransactionLineQuantitySelectNone(uuid)];
|
|
9884
|
+
});
|
|
9885
|
+
});
|
|
9886
|
+
};
|
|
9855
9887
|
TransactionConnectorService.prototype.resolvePendingLineReason = function (pendingLineValues) {
|
|
9856
9888
|
return __awaiter(this, void 0, void 0, function () {
|
|
9857
9889
|
return __generator(this, function (_a) {
|
|
@@ -12372,10 +12404,6 @@
|
|
|
12372
12404
|
this.readonly = false;
|
|
12373
12405
|
this.showLoader = false;
|
|
12374
12406
|
this.relationChange = new i0.EventEmitter();
|
|
12375
|
-
this.canAllLinesBeDelivered = false;
|
|
12376
|
-
this.canAllLinesBeInvoiced = false;
|
|
12377
|
-
this.hasLinesToDeliver = false;
|
|
12378
|
-
this.hasLinesToInvoice = false;
|
|
12379
12407
|
this.decimals = 0;
|
|
12380
12408
|
this.committing = false;
|
|
12381
12409
|
this.headerTooltipMessages = [];
|
|
@@ -12752,6 +12780,10 @@
|
|
|
12752
12780
|
this.isPurchaseOrder = false;
|
|
12753
12781
|
this.reservationMode = false;
|
|
12754
12782
|
this.readonly = false;
|
|
12783
|
+
this.canAllLinesBeDelivered = false;
|
|
12784
|
+
this.canAllLinesBeInvoiced = false;
|
|
12785
|
+
this.hasLinesToDeliver = false;
|
|
12786
|
+
this.hasLinesToInvoice = false;
|
|
12755
12787
|
this.relationSet = new rxjs.BehaviorSubject(false);
|
|
12756
12788
|
this.transactionSet = new rxjs.BehaviorSubject(false);
|
|
12757
12789
|
this.transactionInfoSet = new rxjs.BehaviorSubject(false);
|
|
@@ -12790,6 +12822,14 @@
|
|
|
12790
12822
|
}
|
|
12791
12823
|
if (this._transaction.transactionLines) {
|
|
12792
12824
|
this.transactionLines = this._transaction.transactionLines;
|
|
12825
|
+
this.canAllLinesBeDelivered = this.transactionLines.filter(function (l) { return l.articleLineStatus ? (l.articleLineStatus.quantityToDeliver === 0) : false; }).length === 0;
|
|
12826
|
+
this.canAllLinesBeInvoiced = this.transactionLines.filter(function (l) { return l.articleLineStatus ? (l.articleLineStatus.quantityToInvoice === 0) : false; }).length === 0;
|
|
12827
|
+
this.hasLinesToDeliver = this.transactionInfo.allowPartialDelivery ?
|
|
12828
|
+
this.transactionLines.filter(function (l) { return l.articleLineStatus ? l.articleLineStatus.quantityToDeliver !== 0 : false; }).length > 0 :
|
|
12829
|
+
this.transactionLines.filter(function (l) { return l.articleLineStatus ? l.articleLineStatus.quantityToDeliver === 0 : false; }).length === 0;
|
|
12830
|
+
this.hasLinesToInvoice = this.transactionInfo.allowPartialDelivery ?
|
|
12831
|
+
this.transactionLines.filter(function (l) { return l.articleLineStatus ? l.articleLineStatus.quantityToInvoice !== 0 : false; }).length > 0 :
|
|
12832
|
+
this.transactionLines.filter(function (l) { return l.articleLineStatus ? l.articleLineStatus.quantityToInvoice === 0 : false; }).length === 0;
|
|
12793
12833
|
}
|
|
12794
12834
|
if (this._transaction.deliveryCostLines) {
|
|
12795
12835
|
this.deliveryCostLines = this._transaction.deliveryCostLines;
|
|
@@ -13125,6 +13165,20 @@
|
|
|
13125
13165
|
enumerable: false,
|
|
13126
13166
|
configurable: true
|
|
13127
13167
|
});
|
|
13168
|
+
Object.defineProperty(TransactionLineBaseComponent.prototype, "canAllLinesBeDelivered", {
|
|
13169
|
+
get: function () {
|
|
13170
|
+
return this.transactionHeaderService.canAllLinesBeDelivered;
|
|
13171
|
+
},
|
|
13172
|
+
enumerable: false,
|
|
13173
|
+
configurable: true
|
|
13174
|
+
});
|
|
13175
|
+
Object.defineProperty(TransactionLineBaseComponent.prototype, "canAllLinesBeInvoiced", {
|
|
13176
|
+
get: function () {
|
|
13177
|
+
return this.transactionHeaderService.canAllLinesBeInvoiced;
|
|
13178
|
+
},
|
|
13179
|
+
enumerable: false,
|
|
13180
|
+
configurable: true
|
|
13181
|
+
});
|
|
13128
13182
|
Object.defineProperty(TransactionLineBaseComponent.prototype, "model", {
|
|
13129
13183
|
get: function () {
|
|
13130
13184
|
return this.transactionLine;
|
|
@@ -13578,6 +13632,20 @@
|
|
|
13578
13632
|
enumerable: false,
|
|
13579
13633
|
configurable: true
|
|
13580
13634
|
});
|
|
13635
|
+
Object.defineProperty(TransactionHeaderBaseComponent.prototype, "hasLinesToDeliver", {
|
|
13636
|
+
get: function () {
|
|
13637
|
+
return this.transactionHeaderService.hasLinesToDeliver;
|
|
13638
|
+
},
|
|
13639
|
+
enumerable: false,
|
|
13640
|
+
configurable: true
|
|
13641
|
+
});
|
|
13642
|
+
Object.defineProperty(TransactionHeaderBaseComponent.prototype, "hasLinesToInvoice", {
|
|
13643
|
+
get: function () {
|
|
13644
|
+
return this.transactionHeaderService.hasLinesToInvoice;
|
|
13645
|
+
},
|
|
13646
|
+
enumerable: false,
|
|
13647
|
+
configurable: true
|
|
13648
|
+
});
|
|
13581
13649
|
TransactionHeaderBaseComponent.prototype.ngOnInit = function () {
|
|
13582
13650
|
var _this = this;
|
|
13583
13651
|
_super.prototype.ngOnInit.call(this);
|
|
@@ -16609,6 +16677,28 @@
|
|
|
16609
16677
|
});
|
|
16610
16678
|
});
|
|
16611
16679
|
};
|
|
16680
|
+
TransactionService.prototype.updateQuantitySelectNone = function (uuid, saveTransaction, rememberTransaction) {
|
|
16681
|
+
if (saveTransaction === void 0) { saveTransaction = true; }
|
|
16682
|
+
if (rememberTransaction === void 0) { rememberTransaction = true; }
|
|
16683
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
16684
|
+
var response;
|
|
16685
|
+
return __generator(this, function (_a) {
|
|
16686
|
+
switch (_a.label) {
|
|
16687
|
+
case 0: return [4 /*yield*/, this.connector.changeTransactionLineQuantitySelectNone(uuid)];
|
|
16688
|
+
case 1:
|
|
16689
|
+
response = _a.sent();
|
|
16690
|
+
if (!response) return [3 /*break*/, 3];
|
|
16691
|
+
this.transactionDirty = true;
|
|
16692
|
+
return [4 /*yield*/, this.handleLineOperationStatuses(response, saveTransaction, rememberTransaction)];
|
|
16693
|
+
case 2:
|
|
16694
|
+
_a.sent();
|
|
16695
|
+
this.transactionEventService.quantitySelectedLineChanged.next(true);
|
|
16696
|
+
return [2 /*return*/, true];
|
|
16697
|
+
case 3: return [2 /*return*/, false];
|
|
16698
|
+
}
|
|
16699
|
+
});
|
|
16700
|
+
});
|
|
16701
|
+
};
|
|
16612
16702
|
TransactionService.prototype.updateDeliveryDateTransactionLine = function (uuid, lineUuid, date) {
|
|
16613
16703
|
return __awaiter(this, void 0, void 0, function () {
|
|
16614
16704
|
var response;
|
|
@@ -25092,6 +25182,7 @@
|
|
|
25092
25182
|
_this._subscriptions = [];
|
|
25093
25183
|
_this.showCheckbox = false;
|
|
25094
25184
|
_this.checkboxReadonly = false;
|
|
25185
|
+
_this.localAmountSelected = 0;
|
|
25095
25186
|
return _this;
|
|
25096
25187
|
}
|
|
25097
25188
|
TransactionOrderDeliveryLineBaseComponent.prototype.ngOnInit = function () {
|
|
@@ -25101,11 +25192,13 @@
|
|
|
25101
25192
|
this._subscriptions.push(this.transactionEventService.selectAllSalesOrderLinesForDelivery.subscribe(function (value) {
|
|
25102
25193
|
if (_this.lineQuantityToDeliver !== 0) {
|
|
25103
25194
|
_this.transactionLine.selected = value;
|
|
25195
|
+
_this.transactionLine.amountSelected = _this.localAmountSelected;
|
|
25104
25196
|
_this.transactionEventService.lineSelectedForDelivery.next({ lineUuid: _this.transactionLine.uuid, selected: _this.transactionLine.selected });
|
|
25105
25197
|
}
|
|
25106
25198
|
_this.detectChanges();
|
|
25107
25199
|
}));
|
|
25108
25200
|
this._checkCheckbox();
|
|
25201
|
+
this._checkAmounts();
|
|
25109
25202
|
};
|
|
25110
25203
|
TransactionOrderDeliveryLineBaseComponent.prototype.ngOnDestroy = function () {
|
|
25111
25204
|
this._subscriptions.forEach(function (s) { return s.unsubscribe(); });
|
|
@@ -25120,23 +25213,33 @@
|
|
|
25120
25213
|
switch (_a.label) {
|
|
25121
25214
|
case 0:
|
|
25122
25215
|
this.transactionLine.selected = checked;
|
|
25123
|
-
|
|
25216
|
+
if (this.transactionLine.selected) {
|
|
25217
|
+
this.transactionLine.amountSelected = this.localAmountSelected;
|
|
25218
|
+
}
|
|
25219
|
+
else {
|
|
25220
|
+
this.transactionLine.amountSelected = 0;
|
|
25221
|
+
}
|
|
25222
|
+
return [4 /*yield*/, this.updateSelectedQuantity(this.transactionLine.amountSelected)];
|
|
25124
25223
|
case 1:
|
|
25125
25224
|
_a.sent();
|
|
25225
|
+
//TODO check if this is truly necessary
|
|
25226
|
+
this._checkAmounts();
|
|
25227
|
+
this.detectChanges();
|
|
25126
25228
|
return [2 /*return*/];
|
|
25127
25229
|
}
|
|
25128
25230
|
});
|
|
25129
25231
|
});
|
|
25130
25232
|
};
|
|
25131
|
-
TransactionOrderDeliveryLineBaseComponent.prototype.updateSelectedQuantity = function () {
|
|
25233
|
+
TransactionOrderDeliveryLineBaseComponent.prototype.updateSelectedQuantity = function (amount) {
|
|
25132
25234
|
return __awaiter(this, void 0, void 0, function () {
|
|
25133
25235
|
var request;
|
|
25134
25236
|
return __generator(this, function (_a) {
|
|
25135
25237
|
switch (_a.label) {
|
|
25136
25238
|
case 0:
|
|
25239
|
+
this.transactionLine.amountSelected = amount;
|
|
25137
25240
|
request = new changeLineQuantitySelectedLineRequest.ChangeLineQuantitySelectedLineRequest();
|
|
25138
25241
|
request.lineUuid = this.transactionLine.uuid;
|
|
25139
|
-
request.newQuantitySelected =
|
|
25242
|
+
request.newQuantitySelected = amount;
|
|
25140
25243
|
return [4 /*yield*/, this.transactionService.updateQuantitySelectedTransactionLine(this.transactionInfo.uuid, [request], false, false)];
|
|
25141
25244
|
case 1:
|
|
25142
25245
|
_a.sent();
|
|
@@ -25147,24 +25250,20 @@
|
|
|
25147
25250
|
};
|
|
25148
25251
|
TransactionOrderDeliveryLineBaseComponent.prototype.transactionLineSet = function () {
|
|
25149
25252
|
_super.prototype.transactionLineSet.call(this);
|
|
25150
|
-
if (this.transactionLine.amountSelected === undefined) {
|
|
25151
|
-
if (!this.transactionInfo.allowPartialDelivery) {
|
|
25152
|
-
this.transactionLine.amountSelected = this.transactionLine.amount;
|
|
25153
|
-
}
|
|
25154
|
-
else {
|
|
25155
|
-
this.transactionLine.amountSelected = 0;
|
|
25156
|
-
}
|
|
25157
|
-
}
|
|
25158
25253
|
this._checkCheckbox();
|
|
25254
|
+
this._checkAmounts();
|
|
25159
25255
|
};
|
|
25160
25256
|
TransactionOrderDeliveryLineBaseComponent.prototype.transactionInfoSet = function () {
|
|
25161
25257
|
_super.prototype.transactionInfoSet.call(this);
|
|
25162
25258
|
this._checkCheckbox();
|
|
25259
|
+
this._checkAmounts();
|
|
25163
25260
|
};
|
|
25164
25261
|
TransactionOrderDeliveryLineBaseComponent.prototype._checkCheckbox = function () {
|
|
25165
25262
|
if (this.transactionInfo && this.transactionLine) {
|
|
25166
25263
|
if (this.transactionInfo.allowPartialDelivery) {
|
|
25167
25264
|
this.showCheckbox = this.lineQuantityToDeliver !== 0 && !this.lineIsDelivered;
|
|
25265
|
+
this.checkboxReadonly = !this.showCheckbox;
|
|
25266
|
+
this.selected = ((this.transactionLine.amountSelected !== 0) && (this.transactionLine.amountSelected !== undefined));
|
|
25168
25267
|
}
|
|
25169
25268
|
else {
|
|
25170
25269
|
this.showCheckbox = this.canAllLinesBeDelivered && !this.lineIsDelivered;
|
|
@@ -25175,6 +25274,16 @@
|
|
|
25175
25274
|
this.detectChanges();
|
|
25176
25275
|
}
|
|
25177
25276
|
};
|
|
25277
|
+
TransactionOrderDeliveryLineBaseComponent.prototype._checkAmounts = function () {
|
|
25278
|
+
if (this.transactionInfo && this.transactionLine) {
|
|
25279
|
+
if (this.transactionInfo.allowPartialDelivery) {
|
|
25280
|
+
this.localAmountSelected = this.transactionLine.selected ? this.transactionLine.amountSelected : this.transactionLineService.lineQuantityToDeliver;
|
|
25281
|
+
}
|
|
25282
|
+
else {
|
|
25283
|
+
this.localAmountSelected = this.transactionLineService.lineQuantityToDeliver;
|
|
25284
|
+
}
|
|
25285
|
+
}
|
|
25286
|
+
};
|
|
25178
25287
|
return TransactionOrderDeliveryLineBaseComponent;
|
|
25179
25288
|
}(TransactionLineBaseComponent));
|
|
25180
25289
|
TransactionOrderDeliveryLineBaseComponent.decorators = [
|
|
@@ -25213,7 +25322,7 @@
|
|
|
25213
25322
|
TransactionOrderDeliveryLineComponent.decorators = [
|
|
25214
25323
|
{ type: i0.Component, args: [{
|
|
25215
25324
|
selector: "co-transaction-order-delivery-line",
|
|
25216
|
-
template: "\n <co-transaction-base-line\n [transactionInfo]=\"transactionInfo\"\n [transactionLine]=\"transactionLine\"\n [preview]=\"preview\"\n [isFirst]=\"isFirst\"\n [checkbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [checkboxValue]=\"transactionLine.selected\"\n [checkboxReadonly]=\"checkboxReadonly\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n >\n <div class=\"transaction-line-wrapper\" [class.transaction-not-definitive]=\"!transactionInfo.transactionDefinitive\">\n <div *ngIf=!preview class=\"transaction-line-extended-wrapper\">\n <div class=\"column1\">\n <co-transaction-line-statusbar\n class=\"status-bar-wrapper\"\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderDeliveryNote\"></co-transaction-line-statusbar>\n </div>\n <div class=\"column2\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button\n [screenConfigurationObject]=\"cfgNames.LineWarehouse\"\n [readonly]=\"readonly\"></co-transaction-line-warehouse-button>\n </div>\n </div>\n </div>\n <div class=\"column3\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"column4\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-input-number-picker class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineQuantityToDeliver\"\n [(model)]=\"
|
|
25325
|
+
template: "\n <co-transaction-base-line\n [transactionInfo]=\"transactionInfo\"\n [transactionLine]=\"transactionLine\"\n [preview]=\"preview\"\n [isFirst]=\"isFirst\"\n [checkbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [checkboxValue]=\"transactionLine.selected\"\n [checkboxReadonly]=\"checkboxReadonly\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n >\n <div class=\"transaction-line-wrapper\" [class.transaction-not-definitive]=\"!transactionInfo.transactionDefinitive\">\n <div *ngIf=!preview class=\"transaction-line-extended-wrapper\">\n <div class=\"column1\">\n <co-transaction-line-statusbar\n class=\"status-bar-wrapper\"\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderDeliveryNote\"></co-transaction-line-statusbar>\n </div>\n <div class=\"column2\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button\n [screenConfigurationObject]=\"cfgNames.LineWarehouse\"\n [readonly]=\"readonly\"></co-transaction-line-warehouse-button>\n </div>\n </div>\n </div>\n <div class=\"column3\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"column4\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-input-number-picker class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineQuantityToDeliver\"\n [(model)]=\"localAmountSelected\"\n [decimals]=\"decimals\"\n [min]=\"!transactionInfo.allowPartialDelivery ? transactionLine.amount : 0\"\n [max]=\"transactionLineService?.lineQuantityToDeliver\"\n [forceReadonly]=\"(!transactionLine.selected) || transactionLineService?.lineQuantityToDeliver === 0 || readonly || !transactionInfo.allowPartialDelivery\"\n (modelChange)=\"updateSelectedQuantity(localAmountSelected)\"\n >\n </co-input-number-picker>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'TOTAL'\"></co-transaction-line-label>\n <co-editable-label class=\"transaction-line-totals-total price\"\n [model]=\"transactionLine.displayNetLineTotal | coCurrency: true\"\n [editModel]=\"transactionLine.displayNetLineTotal\"\n [readonly]=\"true\"\n ></co-editable-label>\n </div>\n </div>\n </div>\n </div>\n </div>\n </co-transaction-base-line>\n ",
|
|
25217
25326
|
encapsulation: i0.ViewEncapsulation.None,
|
|
25218
25327
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
25219
25328
|
},] }
|
|
@@ -25379,10 +25488,11 @@
|
|
|
25379
25488
|
});
|
|
25380
25489
|
};
|
|
25381
25490
|
TransactionQuickAccessOrderDeliveryComponent.prototype._createRequestLines = function (selectedLines) {
|
|
25491
|
+
var _this = this;
|
|
25382
25492
|
return selectedLines.map(function (line) {
|
|
25383
25493
|
var transactionLineReportingRequest = new transactionLineReportingRequest_bo.TransactionLineReportingRequest();
|
|
25384
25494
|
transactionLineReportingRequest.lineNr = line.lineNr;
|
|
25385
|
-
transactionLineReportingRequest.amount = line.amountSelected;
|
|
25495
|
+
transactionLineReportingRequest.amount = _this.transactionInfo.allowPartialDelivery ? line.amountSelected : line.articleLineStatus.quantityToDeliver;
|
|
25386
25496
|
return transactionLineReportingRequest;
|
|
25387
25497
|
});
|
|
25388
25498
|
};
|
|
@@ -26876,10 +26986,11 @@
|
|
|
26876
26986
|
});
|
|
26877
26987
|
};
|
|
26878
26988
|
TransactionQuickAccessInvoiceComponent.prototype._createRequestLines = function (selectedLines) {
|
|
26989
|
+
var _this = this;
|
|
26879
26990
|
return selectedLines.map(function (line) {
|
|
26880
26991
|
var transactionLineReportingRequest = new transactionLineReportingRequest_bo.TransactionLineReportingRequest();
|
|
26881
26992
|
transactionLineReportingRequest.lineNr = line.lineNr;
|
|
26882
|
-
transactionLineReportingRequest.amount = line.amountSelected;
|
|
26993
|
+
transactionLineReportingRequest.amount = _this.transactionInfo.allowPartialDelivery ? line.amountSelected : line.articleLineStatus.quantityToInvoice;
|
|
26883
26994
|
return transactionLineReportingRequest;
|
|
26884
26995
|
});
|
|
26885
26996
|
};
|
|
@@ -26913,6 +27024,7 @@
|
|
|
26913
27024
|
_this._subscriptions = [];
|
|
26914
27025
|
_this.showCheckbox = false;
|
|
26915
27026
|
_this.checkboxReadonly = false;
|
|
27027
|
+
_this.localAmountSelected = 0;
|
|
26916
27028
|
return _this;
|
|
26917
27029
|
}
|
|
26918
27030
|
TransactionInvoiceLineBaseComponent.prototype.ngOnInit = function () {
|
|
@@ -26927,6 +27039,7 @@
|
|
|
26927
27039
|
_this.detectChanges();
|
|
26928
27040
|
}));
|
|
26929
27041
|
this._checkCheckbox();
|
|
27042
|
+
this._checkAmounts();
|
|
26930
27043
|
};
|
|
26931
27044
|
TransactionInvoiceLineBaseComponent.prototype.ngOnDestroy = function () {
|
|
26932
27045
|
this._subscriptions.forEach(function (s) { return s.unsubscribe(); });
|
|
@@ -26934,12 +27047,8 @@
|
|
|
26934
27047
|
};
|
|
26935
27048
|
TransactionInvoiceLineBaseComponent.prototype.transactionLineSet = function () {
|
|
26936
27049
|
_super.prototype.transactionLineSet.call(this);
|
|
26937
|
-
|
|
26938
|
-
|
|
26939
|
-
}
|
|
26940
|
-
if (this.transactionLine.amountSelected === undefined) {
|
|
26941
|
-
this.transactionLine.amountSelected = 0;
|
|
26942
|
-
}
|
|
27050
|
+
this._checkCheckbox();
|
|
27051
|
+
this._checkAmounts();
|
|
26943
27052
|
};
|
|
26944
27053
|
TransactionInvoiceLineBaseComponent.prototype.handleSelectCheckboxClick = function (checked) {
|
|
26945
27054
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -26947,23 +27056,33 @@
|
|
|
26947
27056
|
switch (_a.label) {
|
|
26948
27057
|
case 0:
|
|
26949
27058
|
this.transactionLine.selected = checked;
|
|
26950
|
-
|
|
27059
|
+
if (this.transactionLine.selected) {
|
|
27060
|
+
this.transactionLine.amountSelected = this.localAmountSelected;
|
|
27061
|
+
}
|
|
27062
|
+
else {
|
|
27063
|
+
this.transactionLine.amountSelected = 0;
|
|
27064
|
+
}
|
|
27065
|
+
return [4 /*yield*/, this.updateSelectedQuantity(this.transactionLine.amountSelected)];
|
|
26951
27066
|
case 1:
|
|
26952
27067
|
_a.sent();
|
|
27068
|
+
//TODO check if this is truly necessary
|
|
27069
|
+
this._checkAmounts();
|
|
27070
|
+
this.detectChanges();
|
|
26953
27071
|
return [2 /*return*/];
|
|
26954
27072
|
}
|
|
26955
27073
|
});
|
|
26956
27074
|
});
|
|
26957
27075
|
};
|
|
26958
|
-
TransactionInvoiceLineBaseComponent.prototype.updateSelectedQuantity = function () {
|
|
27076
|
+
TransactionInvoiceLineBaseComponent.prototype.updateSelectedQuantity = function (amount) {
|
|
26959
27077
|
return __awaiter(this, void 0, void 0, function () {
|
|
26960
27078
|
var request;
|
|
26961
27079
|
return __generator(this, function (_a) {
|
|
26962
27080
|
switch (_a.label) {
|
|
26963
27081
|
case 0:
|
|
27082
|
+
this.transactionLine.amountSelected = amount;
|
|
26964
27083
|
request = new changeLineQuantitySelectedLineRequest.ChangeLineQuantitySelectedLineRequest();
|
|
26965
27084
|
request.lineUuid = this.transactionLine.uuid;
|
|
26966
|
-
request.newQuantitySelected =
|
|
27085
|
+
request.newQuantitySelected = amount;
|
|
26967
27086
|
return [4 /*yield*/, this.transactionService.updateQuantitySelectedTransactionLine(this.transactionInfo.uuid, [request], false, false)];
|
|
26968
27087
|
case 1:
|
|
26969
27088
|
_a.sent();
|
|
@@ -26975,7 +27094,9 @@
|
|
|
26975
27094
|
TransactionInvoiceLineBaseComponent.prototype._checkCheckbox = function () {
|
|
26976
27095
|
if (this.transactionInfo && this.transactionLine) {
|
|
26977
27096
|
if (this.transactionInfo.allowPartialDelivery) {
|
|
26978
|
-
this.showCheckbox = this.lineQuantityToInvoice !== 0 && !this.lineIsInvoiced;
|
|
27097
|
+
this.showCheckbox = (this.lineQuantityToInvoice !== 0 && !this.lineIsInvoiced);
|
|
27098
|
+
this.checkboxReadonly = !this.showCheckbox;
|
|
27099
|
+
this.selected = ((this.transactionLine.amountSelected !== 0) && (this.transactionLine.amountSelected !== undefined));
|
|
26979
27100
|
}
|
|
26980
27101
|
else {
|
|
26981
27102
|
this.showCheckbox = this.canAllLinesBeInvoiced && !this.lineIsInvoiced;
|
|
@@ -26986,6 +27107,16 @@
|
|
|
26986
27107
|
this.detectChanges();
|
|
26987
27108
|
}
|
|
26988
27109
|
};
|
|
27110
|
+
TransactionInvoiceLineBaseComponent.prototype._checkAmounts = function () {
|
|
27111
|
+
if (this.transactionInfo && this.transactionLine) {
|
|
27112
|
+
if (this.transactionInfo.allowPartialDelivery) {
|
|
27113
|
+
this.localAmountSelected = this.transactionLine.selected ? this.transactionLine.amountSelected : this.transactionLineService.lineQuantityToInvoice;
|
|
27114
|
+
}
|
|
27115
|
+
else {
|
|
27116
|
+
this.localAmountSelected = this.transactionLineService.lineQuantityToInvoice;
|
|
27117
|
+
}
|
|
27118
|
+
}
|
|
27119
|
+
};
|
|
26989
27120
|
return TransactionInvoiceLineBaseComponent;
|
|
26990
27121
|
}(TransactionLineBaseComponent));
|
|
26991
27122
|
TransactionInvoiceLineBaseComponent.decorators = [
|
|
@@ -27024,7 +27155,7 @@
|
|
|
27024
27155
|
TransactionInvoiceLineComponent.decorators = [
|
|
27025
27156
|
{ type: i0.Component, args: [{
|
|
27026
27157
|
selector: "co-transaction-invoice-line",
|
|
27027
|
-
template: "\n <co-transaction-base-line\n [transactionInfo]=\"transactionInfo\"\n [transactionLine]=\"transactionLine\"\n [preview]=\"preview\"\n [isFirst]=\"isFirst\"\n [checkbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [checkboxValue]=\"transactionLine.selected\"\n [checkboxReadonly]=\"checkboxReadonly\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n >\n <div class=\"transaction-line-wrapper\" [class.transaction-not-definitive]=\"!transactionInfo.transactionDefinitive\">\n <div *ngIf=!preview class=\"transaction-line-extended-wrapper\">\n <div class=\"column1\">\n <co-transaction-line-statusbar\n class=\"status-bar-wrapper\"\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderInvoice\"></co-transaction-line-statusbar>\n </div>\n <div class=\"column2\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button\n [screenConfigurationObject]=\"cfgNames.LineWarehouse\"\n [readonly]=\"readonly\"></co-transaction-line-warehouse-button>\n </div>\n </div>\n </div>\n <div class=\"column3\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"column4\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-input-number-picker class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineQuantityToInvoice\"\n [(model)]=\"
|
|
27158
|
+
template: "\n <co-transaction-base-line\n [transactionInfo]=\"transactionInfo\"\n [transactionLine]=\"transactionLine\"\n [preview]=\"preview\"\n [isFirst]=\"isFirst\"\n [checkbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [checkboxValue]=\"transactionLine.selected\"\n [checkboxReadonly]=\"checkboxReadonly\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n >\n <div class=\"transaction-line-wrapper\" [class.transaction-not-definitive]=\"!transactionInfo.transactionDefinitive\">\n <div *ngIf=!preview class=\"transaction-line-extended-wrapper\">\n <div class=\"column1\">\n <co-transaction-line-statusbar\n class=\"status-bar-wrapper\"\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderInvoice\"></co-transaction-line-statusbar>\n </div>\n <div class=\"column2\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button\n [screenConfigurationObject]=\"cfgNames.LineWarehouse\"\n [readonly]=\"readonly\"></co-transaction-line-warehouse-button>\n </div>\n </div>\n </div>\n <div class=\"column3\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"column4\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-input-number-picker class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineQuantityToInvoice\"\n [(model)]=\"localAmountSelected\"\n [decimals]=\"decimals\"\n [min]=\"1\"\n [max]=\"transactionLineService?.lineQuantityToInvoice\"\n [forceReadonly]=\"(!transactionLine.selected) || transactionLineService?.lineQuantityToInvoice === 0 || readonly || !transactionInfo.allowPartialDelivery\"\n (modelChange)=\"updateSelectedQuantity(localAmountSelected)\"\n >\n </co-input-number-picker>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\" *ngIf=\"!lineIsInvoiced\">\n <co-transaction-line-label [insideLabel]=\"'TOTAL'\"></co-transaction-line-label>\n <co-editable-label class=\"transaction-line-totals-total price\"\n [model]=\"transactionLine.displayNetLineTotal | coCurrency: true\"\n [editModel]=\"transactionLine.displayNetLineTotal\"\n [readonly]=\"true\"\n ></co-editable-label>\n </div>\n </div>\n </div>\n </div>\n </div>\n </co-transaction-base-line>\n ",
|
|
27028
27159
|
encapsulation: i0.ViewEncapsulation.None,
|
|
27029
27160
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
27030
27161
|
},] }
|
|
@@ -27174,7 +27305,7 @@
|
|
|
27174
27305
|
TransactionCardInvoiceComponent.decorators = [
|
|
27175
27306
|
{ type: i0.Component, args: [{
|
|
27176
27307
|
selector: "co-transaction-card-invoice",
|
|
27177
|
-
template: "\n <div class=\"transaction-card-wrapper\">\n <co-transaction-card-header\n [showActionButtons]=\"true\"\n [showCheckbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [showThumbnail]=\"false\"\n [expanded]=\"expanded\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n (expandClicked)=\"expanded = !expanded\">\n <div class=\"transaction-line-totals-amount card-button\" *ngIf=\"lineQuantityToInvoice !== 0\">\n <co-input-number-picker class=\"amount-number-picker\"\n [(model)]=\"transactionLine.amountSelected\"\n [decimals]=\"decimals\"\n [min]=\"1\"\n [max]=\"transactionLine.amount\"\n [readonly]=\"readonly\"\n (modelChange)=\"updateSelectedQuantity()\">\n </co-input-number-picker>\n </div>\n </co-transaction-card-header>\n <div class=\"transaction-card-content-wrapper\">\n <div class=\"content-base top-base\">\n <div class=\"transaction-field-wrapper status-bar\">\n <co-transaction-line-statusbar\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderDeliveryNote\"></co-transaction-line-statusbar>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button></co-transaction-line-warehouse-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"content-base bottom-base\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-transaction-line-amount class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineAmount\"\n ></co-transaction-line-amount>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'TOTAL'\"></co-transaction-line-label>\n <co-editable-label class=\"transaction-line-totals-total price\"\n [model]=\"transactionLine.displayNetLineTotal | coCurrency: true\"\n [editModel]=\"transactionLine.displayNetLineTotal\"\n [readonly]=\"true\"\n ></co-editable-label>\n </div>\n </div>\n </div>\n <div class=\"content-expanded\" *ngIf=\"expanded\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_DATE'\"></co-transaction-line-label>\n <co-transaction-line-delivery-date-button></co-transaction-line-delivery-date-button>\n </div>\n </div>\n </div>\n </div>\n\n <co-transaction-card-footer\n [transactionTypeCategory]=\"category.SalesOrderInvoice\"\n [expanded]=\"expanded\"\n ></co-transaction-card-footer>\n </div>\n ",
|
|
27308
|
+
template: "\n <div class=\"transaction-card-wrapper\">\n <co-transaction-card-header\n [showActionButtons]=\"true\"\n [showCheckbox]=\"showCheckbox && transactionInfo.transactionDefinitive\"\n [showThumbnail]=\"false\"\n [expanded]=\"expanded\"\n (checkboxValueChanged)=\"handleSelectCheckboxClick($event)\"\n (expandClicked)=\"expanded = !expanded\">\n <div class=\"transaction-line-totals-amount card-button\" *ngIf=\"lineQuantityToInvoice !== 0\">\n <co-input-number-picker class=\"amount-number-picker\"\n [(model)]=\"transactionLine.amountSelected\"\n [decimals]=\"decimals\"\n [min]=\"1\"\n [max]=\"transactionLine.amount\"\n [readonly]=\"readonly\"\n (modelChange)=\"updateSelectedQuantity(transactionLine.amountSelected)\">\n </co-input-number-picker>\n </div>\n </co-transaction-card-header>\n <div class=\"transaction-card-content-wrapper\">\n <div class=\"content-base top-base\">\n <div class=\"transaction-field-wrapper status-bar\">\n <co-transaction-line-statusbar\n [screenConfigurationObject]=\"cfgNames.StatusBar\"\n [configNames]=\"statusBarConfigNames\"\n [activeCategory]=\"category.SalesOrderDeliveryNote\"></co-transaction-line-statusbar>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'WAREHOUSE'\"></co-transaction-line-label>\n <co-transaction-line-warehouse-button></co-transaction-line-warehouse-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button></co-transaction-line-delivery-button>\n </div>\n </div>\n </div>\n <div class=\"content-base bottom-base\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'PRICE'\"></co-transaction-line-label>\n <co-transaction-line-price class=\"transaction-line-totals-price price\"\n [screenConfigurationObject]=\"cfgNames.LinePrice\"\n [showLabel]=\"false\"\n [defaultEditMode]=\"false\"\n ></co-transaction-line-price>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DISCOUNT'\"></co-transaction-line-label>\n <co-transaction-line-discount-button *ngIf=\"!preview\"\n [screenConfigurationObject]=\"cfgNames.LineDiscount\"\n [configNames]=\"discountConfigNames\"\n ></co-transaction-line-discount-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'QUANTITY'\"></co-transaction-line-label>\n <co-transaction-line-amount class=\"amount-number-picker\"\n [screenConfigurationObject]=\"cfgNames.LineAmount\"\n ></co-transaction-line-amount>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'TOTAL'\"></co-transaction-line-label>\n <co-editable-label class=\"transaction-line-totals-total price\"\n [model]=\"transactionLine.displayNetLineTotal | coCurrency: true\"\n [editModel]=\"transactionLine.displayNetLineTotal\"\n [readonly]=\"true\"\n ></co-editable-label>\n </div>\n </div>\n </div>\n <div class=\"content-expanded\" *ngIf=\"expanded\">\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_METHOD'\"></co-transaction-line-label>\n <co-transaction-line-delivery-button\n [screenConfigurationObject]=\"cfgNames.LineDeliveryMethod\"\n ></co-transaction-line-delivery-button>\n </div>\n </div>\n <div class=\"transaction-field-wrapper\">\n <div class=\"inside-field\">\n <co-transaction-line-label [insideLabel]=\"'DELIVERY_DATE'\"></co-transaction-line-label>\n <co-transaction-line-delivery-date-button></co-transaction-line-delivery-date-button>\n </div>\n </div>\n </div>\n </div>\n\n <co-transaction-card-footer\n [transactionTypeCategory]=\"category.SalesOrderInvoice\"\n [expanded]=\"expanded\"\n ></co-transaction-card-footer>\n </div>\n ",
|
|
27178
27309
|
encapsulation: i0.ViewEncapsulation.None
|
|
27179
27310
|
},] }
|
|
27180
27311
|
];
|
|
@@ -29989,7 +30120,7 @@
|
|
|
29989
30120
|
// {title: 'DELIVERY_NOTE', icon: Icon.MemoCircleCheckRegular, category: TransactionTypeCategory.SalesOrderDeliveryNote, component: TransactionSalesDeliveryButtonBarButtonComponent, cfgName: this.cfgNames.RubricDelivery},
|
|
29990
30121
|
//]],
|
|
29991
30122
|
[transactionKind_enum.TransactionKind.ServiceOrder, [
|
|
29992
|
-
{ title: 'SERVICE', icon: Icon.
|
|
30123
|
+
{ title: 'SERVICE', icon: Icon.ScrewdriverWrenchRegular, category: TransactionTypeCategory.ServiceOrderService, component: TransactionServiceServiceButtonBarButtonComponent },
|
|
29993
30124
|
{ title: 'OVERVIEW', icon: Icon.CartShoppingRegular, category: TransactionTypeCategory.ServiceOrderOverview, component: TransactionSalesOverviewButtonBarButtonComponent, cfgName: this.cfgNames.RubricOverview },
|
|
29994
30125
|
{ title: 'PURCHASE', icon: Icon.PalletBoxesSharpRegular, category: TransactionTypeCategory.ServiceOrderPurchase, component: TransactionSalesPurchaseButtonBarButtonComponent, cfgName: this.cfgNames.RubricPurchase },
|
|
29995
30126
|
{ title: 'ALLOCATION', icon: Icon.ShelvesRegular, category: TransactionTypeCategory.ServiceOrderAllocation, component: TransactionSalesAllocationButtonBarButtonComponent, cfgName: this.cfgNames.RubricAllocate },
|
|
@@ -53260,8 +53391,77 @@
|
|
|
53260
53391
|
showClass: [{ type: i0.HostBinding, args: ['class.co-shopping-cart',] }]
|
|
53261
53392
|
};
|
|
53262
53393
|
|
|
53394
|
+
var LineSelectionService = /** @class */ (function () {
|
|
53395
|
+
function LineSelectionService(_transactionEventService, _transactionService) {
|
|
53396
|
+
var _this = this;
|
|
53397
|
+
this._transactionEventService = _transactionEventService;
|
|
53398
|
+
this._transactionService = _transactionService;
|
|
53399
|
+
this._subs = [];
|
|
53400
|
+
this._selectedLineUuidsForDelivery = [];
|
|
53401
|
+
this._selectedLineUuidsForInvoice = [];
|
|
53402
|
+
this._subs.push(this._transactionEventService.lineSelectedForDelivery.subscribe(function (data) {
|
|
53403
|
+
if (_this._checkAllLinesSelectedForDelivery(data)) {
|
|
53404
|
+
_this._selectedLineUuidsForDelivery.length = 0;
|
|
53405
|
+
_this._transactionEventService.allLinesSelectedForDelivery.next();
|
|
53406
|
+
}
|
|
53407
|
+
}), this._transactionEventService.lineSelectedForInvoice.subscribe(function (data) {
|
|
53408
|
+
if (_this._checkAllLinesSelectedForInvoice(data)) {
|
|
53409
|
+
_this._selectedLineUuidsForInvoice.length = 0;
|
|
53410
|
+
_this._transactionEventService.allLinesSelectedForInvoice.next();
|
|
53411
|
+
}
|
|
53412
|
+
}));
|
|
53413
|
+
}
|
|
53414
|
+
LineSelectionService.prototype.ngOnDestroy = function () {
|
|
53415
|
+
this._subs.forEach(function (s) { return s.unsubscribe(); });
|
|
53416
|
+
};
|
|
53417
|
+
LineSelectionService.prototype._checkAllLinesSelectedForDelivery = function (data) {
|
|
53418
|
+
var _this = this;
|
|
53419
|
+
if (data && data.lineUuid) {
|
|
53420
|
+
if (!data.selected) {
|
|
53421
|
+
return true;
|
|
53422
|
+
}
|
|
53423
|
+
this._selectedLineUuidsForDelivery.push(data.lineUuid);
|
|
53424
|
+
var transactionLinesForDelivery = this._transactionService.currentTransaction.transactionLines.filter(function (l) { return l.articleLineStatus && l.articleLineStatus.quantityToDeliver !== 0; });
|
|
53425
|
+
if (this._transactionService.currentTransaction.deliveryCostLines) {
|
|
53426
|
+
transactionLinesForDelivery = transactionLinesForDelivery.concat(this._transactionService.currentTransaction.deliveryCostLines);
|
|
53427
|
+
}
|
|
53428
|
+
var notFound = transactionLinesForDelivery.filter(function (l) { return _this._selectedLineUuidsForDelivery.indexOf(l.uuid) < 0; });
|
|
53429
|
+
return notFound.length === 0;
|
|
53430
|
+
}
|
|
53431
|
+
return false;
|
|
53432
|
+
};
|
|
53433
|
+
LineSelectionService.prototype._checkAllLinesSelectedForInvoice = function (data) {
|
|
53434
|
+
var _this = this;
|
|
53435
|
+
if (data && data.lineUuid) {
|
|
53436
|
+
if (!data.selected) {
|
|
53437
|
+
return true;
|
|
53438
|
+
}
|
|
53439
|
+
this._selectedLineUuidsForInvoice.push(data.lineUuid);
|
|
53440
|
+
var transactionLinesForInvoice = this._transactionService.currentTransaction.transactionLines.filter(function (l) { return l.articleLineStatus && l.articleLineStatus.quantityToInvoice !== 0; });
|
|
53441
|
+
if (this._transactionService.currentTransaction.deliveryCostLines) {
|
|
53442
|
+
transactionLinesForInvoice = transactionLinesForInvoice.concat(this._transactionService.currentTransaction.deliveryCostLines);
|
|
53443
|
+
}
|
|
53444
|
+
var notFound = transactionLinesForInvoice.filter(function (l) { return _this._selectedLineUuidsForInvoice.indexOf(l.uuid) < 0; });
|
|
53445
|
+
return notFound.length === 0;
|
|
53446
|
+
}
|
|
53447
|
+
return false;
|
|
53448
|
+
};
|
|
53449
|
+
return LineSelectionService;
|
|
53450
|
+
}());
|
|
53451
|
+
LineSelectionService.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function LineSelectionService_Factory() { return new LineSelectionService(i0__namespace.ɵɵinject(TransactionEventService), i0__namespace.ɵɵinject(TransactionService)); }, token: LineSelectionService, providedIn: "root" });
|
|
53452
|
+
LineSelectionService.decorators = [
|
|
53453
|
+
{ type: i0.Injectable, args: [{
|
|
53454
|
+
providedIn: "root"
|
|
53455
|
+
},] }
|
|
53456
|
+
];
|
|
53457
|
+
LineSelectionService.ctorParameters = function () { return [
|
|
53458
|
+
{ type: TransactionEventService },
|
|
53459
|
+
{ type: TransactionService }
|
|
53460
|
+
]; };
|
|
53461
|
+
|
|
53263
53462
|
var TransactionInternalComponent = /** @class */ (function () {
|
|
53264
|
-
function TransactionInternalComponent(iconCacheService, service, transactionEventService, _transactionConnectorService, _transactionEventService, _screenConfigurationService, _dialogService, _purchaseConfirmationService, _deliveryPlanningService, _transactionBaseService, _changeDetector, _transactionHeaderService
|
|
53463
|
+
function TransactionInternalComponent(iconCacheService, service, transactionEventService, _transactionConnectorService, _transactionEventService, _screenConfigurationService, _dialogService, _purchaseConfirmationService, _deliveryPlanningService, _transactionBaseService, _changeDetector, _transactionHeaderService, _lineSelection //Do not remove this. While it is not directly used it has its own important subscriptions.
|
|
53464
|
+
) {
|
|
53265
53465
|
this.iconCacheService = iconCacheService;
|
|
53266
53466
|
this.service = service;
|
|
53267
53467
|
this.transactionEventService = transactionEventService;
|
|
@@ -53274,6 +53474,7 @@
|
|
|
53274
53474
|
this._transactionBaseService = _transactionBaseService;
|
|
53275
53475
|
this._changeDetector = _changeDetector;
|
|
53276
53476
|
this._transactionHeaderService = _transactionHeaderService;
|
|
53477
|
+
this._lineSelection = _lineSelection;
|
|
53277
53478
|
this.categories = TransactionTypeCategory;
|
|
53278
53479
|
this.viewModes = corecomponents_v12.ContentViewMode;
|
|
53279
53480
|
this.icons = Icon;
|
|
@@ -53410,7 +53611,21 @@
|
|
|
53410
53611
|
// this.service.relation = relation;
|
|
53411
53612
|
// }
|
|
53412
53613
|
TransactionInternalComponent.prototype.handleButtonBarButtonClicked = function (button) {
|
|
53413
|
-
this
|
|
53614
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
53615
|
+
return __generator(this, function (_b) {
|
|
53616
|
+
switch (_b.label) {
|
|
53617
|
+
case 0:
|
|
53618
|
+
if (!(this.activeCategory !== button.category && this.transaction)) return [3 /*break*/, 2];
|
|
53619
|
+
return [4 /*yield*/, this.service.updateQuantitySelectNone(this.transaction.transactionInfo.uuid, false, false)];
|
|
53620
|
+
case 1:
|
|
53621
|
+
_b.sent();
|
|
53622
|
+
_b.label = 2;
|
|
53623
|
+
case 2:
|
|
53624
|
+
this.activeCategory = button.category;
|
|
53625
|
+
return [2 /*return*/];
|
|
53626
|
+
}
|
|
53627
|
+
});
|
|
53628
|
+
});
|
|
53414
53629
|
};
|
|
53415
53630
|
TransactionInternalComponent.prototype.handleShowSidePanel = function (line, force) {
|
|
53416
53631
|
if (force === void 0) { force = false; }
|
|
@@ -53692,7 +53907,8 @@
|
|
|
53692
53907
|
{ type: DeliveryPlanningService },
|
|
53693
53908
|
{ type: TransactionBaseService },
|
|
53694
53909
|
{ type: i0.ChangeDetectorRef },
|
|
53695
|
-
{ type: TransactionHeaderService }
|
|
53910
|
+
{ type: TransactionHeaderService },
|
|
53911
|
+
{ type: LineSelectionService }
|
|
53696
53912
|
]; };
|
|
53697
53913
|
TransactionInternalComponent.propDecorators = {
|
|
53698
53914
|
sidePanelComponents: [{ type: i0.ViewChildren, args: [TransactionLineSidePanelComponent,] }],
|
|
@@ -59248,19 +59464,22 @@
|
|
|
59248
59464
|
];
|
|
59249
59465
|
|
|
59250
59466
|
var TransactionCreateWizardComponent = /** @class */ (function () {
|
|
59251
|
-
function TransactionCreateWizardComponent(createService, relationService, transactionScreenConfigurationService) {
|
|
59467
|
+
function TransactionCreateWizardComponent(createService, relationService, transactionScreenConfigurationService, _headerService) {
|
|
59252
59468
|
this.createService = createService;
|
|
59253
59469
|
this.relationService = relationService;
|
|
59254
59470
|
this.transactionScreenConfigurationService = transactionScreenConfigurationService;
|
|
59471
|
+
this._headerService = _headerService;
|
|
59255
59472
|
this.transKind = transactionKind_enum.TransactionKind;
|
|
59256
59473
|
this.Icon = Icon;
|
|
59257
59474
|
this.transactionFinished = new i0.EventEmitter();
|
|
59258
59475
|
//This can be an input once the component is adjusted to work to create more transactions.
|
|
59259
59476
|
this.transactionType = transactionKind_enum.TransactionKind.ServiceOrder;
|
|
59260
59477
|
this.noLockOnCustomerSet = false;
|
|
59478
|
+
this.isReady = false;
|
|
59261
59479
|
this._externallyProvidedTransaction = null;
|
|
59262
59480
|
//for bundle puroses where an new, non transaction based, service should always start with the customer already set
|
|
59263
59481
|
this._externallyProvidedCustomer = null;
|
|
59482
|
+
this._subs = [];
|
|
59264
59483
|
}
|
|
59265
59484
|
Object.defineProperty(TransactionCreateWizardComponent.prototype, "externallyProvidedTransaction", {
|
|
59266
59485
|
set: function (transaction) {
|
|
@@ -59288,9 +59507,16 @@
|
|
|
59288
59507
|
};
|
|
59289
59508
|
TransactionCreateWizardComponent.prototype.ngOnInit = function () {
|
|
59290
59509
|
return __awaiter(this, void 0, void 0, function () {
|
|
59510
|
+
var _this = this;
|
|
59291
59511
|
return __generator(this, function (_a) {
|
|
59292
59512
|
switch (_a.label) {
|
|
59293
|
-
case 0:
|
|
59513
|
+
case 0:
|
|
59514
|
+
this._subs.push(this.createService.transactionUpdated.subscribe(function (transaction) {
|
|
59515
|
+
if (transaction) {
|
|
59516
|
+
_this._headerService.transaction = transaction;
|
|
59517
|
+
}
|
|
59518
|
+
}));
|
|
59519
|
+
return [4 /*yield*/, this.createService.prepareAfterSalesSystemParam()];
|
|
59294
59520
|
case 1:
|
|
59295
59521
|
_a.sent();
|
|
59296
59522
|
if (this.createService.afterSalesSystemParam) {
|
|
@@ -59302,11 +59528,22 @@
|
|
|
59302
59528
|
this.createService.transactionKind = this.transactionType;
|
|
59303
59529
|
this.createService.createNewRelation();
|
|
59304
59530
|
this._processExternalSettings();
|
|
59531
|
+
this._headerService.relation = new customerFullObject_bo.CustomerFullObject();
|
|
59532
|
+
this._headerService.createCloneRelation();
|
|
59533
|
+
this.isReady = true;
|
|
59305
59534
|
return [2 /*return*/];
|
|
59306
59535
|
}
|
|
59307
59536
|
});
|
|
59308
59537
|
});
|
|
59309
59538
|
};
|
|
59539
|
+
TransactionCreateWizardComponent.prototype.ngOnDestroy = function () {
|
|
59540
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
59541
|
+
return __generator(this, function (_a) {
|
|
59542
|
+
this._subs.forEach(function (s) { return s.unsubscribe(); });
|
|
59543
|
+
return [2 /*return*/];
|
|
59544
|
+
});
|
|
59545
|
+
});
|
|
59546
|
+
};
|
|
59310
59547
|
TransactionCreateWizardComponent.prototype.handleRelationValidation = function () {
|
|
59311
59548
|
return __awaiter(this, void 0, void 0, function () {
|
|
59312
59549
|
var valid, _a;
|
|
@@ -59519,15 +59756,16 @@
|
|
|
59519
59756
|
TransactionCreateWizardComponent.decorators = [
|
|
59520
59757
|
{ type: i0.Component, args: [{
|
|
59521
59758
|
selector: "co-transaction-create-wizard",
|
|
59522
|
-
template: "\n <co-click-block></co-click-block>\n <co-simple-vertical-stepper [stepButtonLabels]=\"['Volgende', 'Volgende', 'Volgende', 'Volgende', 'Afronden']\"\n
|
|
59523
|
-
providers: [TransactionCreateService],
|
|
59759
|
+
template: "\n <co-click-block></co-click-block>\n <ng-container *ngIf=\"isReady\">\n <co-simple-vertical-stepper [stepButtonLabels]=\"['Volgende', 'Volgende', 'Volgende', 'Volgende', 'Afronden']\"\n #stepper [titleIcon]=\"Icon.ServiceCartRegular\" [title]=\"'CREATE_SERVICE' | localize\" [doNotShowOKOnSteps]=\"[3]\">\n <co-stepper-step #stepRelationSection [index]=\"1\" [label]=\"'PERSONAL_DATA' | localize\" (validateStep)=\"handleRelationValidation()\">\n\n <co-transaction-header-popup-relation #relationSection [noLockOnCustomerSet]=\"noLockOnCustomerSet\" [forceReadonly]=\"noLockOnCustomerSet\"\n *ngIf=\"stepRelationSection.show\"\n class=\"category-content\"\n [forceReadonly]=\"(createService.currentTransaction.transactionInfo.uuid !== undefined)\"\n [showInvoiceAddress]=\"false\" [showPrivacy]=\"false\" [showMessageForChangeCustomer]=\"true\"\n (changeCustomerRequested)=\"resetWizard()\"\n ></co-transaction-header-popup-relation>\n </co-stepper-step>\n <co-stepper-step #stepTransactionSection [index]=\"2\" [label]=\"'HOW_TO_CREATE_SERVICE' | localize\" (validateStep)=\"handleTransactionValidation()\">\n <co-transaction-header-popup-create-service #transactionSection [relation]=\"createService.relation\" [forceReadonly]=\"(createService.currentTransaction.transactionInfo.uuid !== undefined)\"\n [afterSalesSystem]=\"createService.afterSalesSystemParam\"></co-transaction-header-popup-create-service>\n </co-stepper-step>\n <co-stepper-step #stepWizardSection [index]=\"3\" [label]=\"'SERVICE_WIZARD' | localize\" (validateStep)=\"handleWizardValidation()\">\n <co-transaction-header-popup-service-wizard #wizardSection (wizardFinished)=\"wizardFinished()\" (skipWizard)=\"skipWizard()\"></co-transaction-header-popup-service-wizard>\n </co-stepper-step>\n <co-stepper-step #stepServiceFieldsSection [index]=\"4\" [label]=\"'SERVICE_INFO' | localize\" (validateStep)=\"handleServiceInfoValidation()\">\n <co-transaction-header-popup-service-fields #serviceFieldsSection></co-transaction-header-popup-service-fields>\n </co-stepper-step>\n <co-stepper-step [index]=\"5\" [label]=\"'FINISH' | localize\">\n </co-stepper-step>\n </co-simple-vertical-stepper>\n </ng-container>\n\n ",
|
|
59760
|
+
providers: [TransactionCreateService, TransactionHeaderService],
|
|
59524
59761
|
encapsulation: i0.ViewEncapsulation.None
|
|
59525
59762
|
},] }
|
|
59526
59763
|
];
|
|
59527
59764
|
TransactionCreateWizardComponent.ctorParameters = function () { return [
|
|
59528
59765
|
{ type: TransactionCreateService },
|
|
59529
59766
|
{ type: TransactionRelationService },
|
|
59530
|
-
{ type: TransactionScreenConfigurationService }
|
|
59767
|
+
{ type: TransactionScreenConfigurationService },
|
|
59768
|
+
{ type: TransactionHeaderService }
|
|
59531
59769
|
]; };
|
|
59532
59770
|
TransactionCreateWizardComponent.propDecorators = {
|
|
59533
59771
|
stepper: [{ type: i0.ViewChild, args: ["stepper",] }],
|
|
@@ -59770,74 +60008,6 @@
|
|
|
59770
60008
|
{ type: TransactionSettingsService }
|
|
59771
60009
|
]; };
|
|
59772
60010
|
|
|
59773
|
-
var LineSelectionService = /** @class */ (function () {
|
|
59774
|
-
function LineSelectionService(_transactionEventService, _transactionService) {
|
|
59775
|
-
var _this = this;
|
|
59776
|
-
this._transactionEventService = _transactionEventService;
|
|
59777
|
-
this._transactionService = _transactionService;
|
|
59778
|
-
this._subs = [];
|
|
59779
|
-
this._selectedLineUuidsForDelivery = [];
|
|
59780
|
-
this._selectedLineUuidsForInvoice = [];
|
|
59781
|
-
this._subs.push(this._transactionEventService.lineSelectedForDelivery.subscribe(function (data) {
|
|
59782
|
-
if (_this._checkAllLinesSelectedForDelivery(data)) {
|
|
59783
|
-
_this._selectedLineUuidsForDelivery.length = 0;
|
|
59784
|
-
_this._transactionEventService.allLinesSelectedForDelivery.next();
|
|
59785
|
-
}
|
|
59786
|
-
}), this._transactionEventService.lineSelectedForInvoice.subscribe(function (data) {
|
|
59787
|
-
if (_this._checkAllLinesSelectedForInvoice(data)) {
|
|
59788
|
-
_this._selectedLineUuidsForInvoice.length = 0;
|
|
59789
|
-
_this._transactionEventService.allLinesSelectedForInvoice.next();
|
|
59790
|
-
}
|
|
59791
|
-
}));
|
|
59792
|
-
}
|
|
59793
|
-
LineSelectionService.prototype.ngOnDestroy = function () {
|
|
59794
|
-
this._subs.forEach(function (s) { return s.unsubscribe(); });
|
|
59795
|
-
};
|
|
59796
|
-
LineSelectionService.prototype._checkAllLinesSelectedForDelivery = function (data) {
|
|
59797
|
-
var _this = this;
|
|
59798
|
-
if (data && data.lineUuid) {
|
|
59799
|
-
if (!data.selected) {
|
|
59800
|
-
return true;
|
|
59801
|
-
}
|
|
59802
|
-
this._selectedLineUuidsForDelivery.push(data.lineUuid);
|
|
59803
|
-
var transactionLinesForDelivery = this._transactionService.currentTransaction.transactionLines.filter(function (l) { return l.articleLineStatus && l.articleLineStatus.quantityToDeliver !== 0; });
|
|
59804
|
-
if (this._transactionService.currentTransaction.deliveryCostLines) {
|
|
59805
|
-
transactionLinesForDelivery = transactionLinesForDelivery.concat(this._transactionService.currentTransaction.deliveryCostLines);
|
|
59806
|
-
}
|
|
59807
|
-
var notFound = transactionLinesForDelivery.filter(function (l) { return _this._selectedLineUuidsForDelivery.indexOf(l.uuid) < 0; });
|
|
59808
|
-
return notFound.length === 0;
|
|
59809
|
-
}
|
|
59810
|
-
return false;
|
|
59811
|
-
};
|
|
59812
|
-
LineSelectionService.prototype._checkAllLinesSelectedForInvoice = function (data) {
|
|
59813
|
-
var _this = this;
|
|
59814
|
-
if (data && data.lineUuid) {
|
|
59815
|
-
if (!data.selected) {
|
|
59816
|
-
return true;
|
|
59817
|
-
}
|
|
59818
|
-
this._selectedLineUuidsForInvoice.push(data.lineUuid);
|
|
59819
|
-
var transactionLinesForInvoice = this._transactionService.currentTransaction.transactionLines.filter(function (l) { return l.articleLineStatus && l.articleLineStatus.quantityToInvoice !== 0; });
|
|
59820
|
-
if (this._transactionService.currentTransaction.deliveryCostLines) {
|
|
59821
|
-
transactionLinesForInvoice = transactionLinesForInvoice.concat(this._transactionService.currentTransaction.deliveryCostLines);
|
|
59822
|
-
}
|
|
59823
|
-
var notFound = transactionLinesForInvoice.filter(function (l) { return _this._selectedLineUuidsForInvoice.indexOf(l.uuid) < 0; });
|
|
59824
|
-
return notFound.length === 0;
|
|
59825
|
-
}
|
|
59826
|
-
return false;
|
|
59827
|
-
};
|
|
59828
|
-
return LineSelectionService;
|
|
59829
|
-
}());
|
|
59830
|
-
LineSelectionService.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function LineSelectionService_Factory() { return new LineSelectionService(i0__namespace.ɵɵinject(TransactionEventService), i0__namespace.ɵɵinject(TransactionService)); }, token: LineSelectionService, providedIn: "root" });
|
|
59831
|
-
LineSelectionService.decorators = [
|
|
59832
|
-
{ type: i0.Injectable, args: [{
|
|
59833
|
-
providedIn: "root"
|
|
59834
|
-
},] }
|
|
59835
|
-
];
|
|
59836
|
-
LineSelectionService.ctorParameters = function () { return [
|
|
59837
|
-
{ type: TransactionEventService },
|
|
59838
|
-
{ type: TransactionService }
|
|
59839
|
-
]; };
|
|
59840
|
-
|
|
59841
60011
|
/**
|
|
59842
60012
|
* Generated bundle index. Do not edit.
|
|
59843
60013
|
*/
|