@colijnit/transaction 256.1.3 → 256.1.5
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 +155 -102
- package/bundles/colijnit-transaction.umd.js.map +1 -1
- package/colijnit-transaction-256.1.4.tgz +0 -0
- package/colijnit-transaction.metadata.json +1 -1
- package/esm2015/lib/component/checkout/checkout.component.js +17 -1
- package/esm2015/lib/component/core/base/transaction-payment-base.component.js +10 -1
- package/esm2015/lib/component/payment/payment.component.js +5 -1
- package/esm2015/lib/component/payment/payment.module.js +4 -3
- package/esm2015/lib/component/transaction/transaction.component.js +15 -1
- package/esm2015/lib/component/transaction-header/transaction-header-payment/transaction-header-payment.component.js +3 -2
- package/esm2015/lib/component/transaction-line-fields/transaction-line-delivery-date-button.component.js +37 -19
- package/esm2015/lib/component/transaction-line-fields/transaction-line-supplier-delivery-date-button.component.js +13 -13
- package/esm2015/lib/component/transaction-search/service/transaction-search.service.js +4 -1
- package/esm2015/lib/component/transaction-search/transaction-search-result/transaction-search-result.component.js +28 -14
- package/esm2015/lib/component/transaction-search/transaction-search-tile/transaction-search-sales-order-tile/transaction-search-sales-order-tile.component.js +1 -21
- package/esm2015/lib/service/transaction-base.service.js +10 -1
- package/esm2015/lib/service/transaction-connector.service.js +29 -31
- package/esm2015/lib/transaction-version.js +3 -3
- package/fesm2015/colijnit-transaction.js +163 -94
- package/fesm2015/colijnit-transaction.js.map +1 -1
- package/lib/component/checkout/checkout.component.d.ts +1 -0
- package/lib/component/core/base/transaction-payment-base.component.d.ts +1 -0
- package/lib/component/transaction-line/transaction-line/style/_layout.scss +4 -2
- package/lib/component/transaction-line-fields/transaction-line-delivery-date-button.component.d.ts +1 -1
- package/lib/component/transaction-line-fields/transaction-line-supplier-delivery-date-button.component.d.ts +1 -2
- package/lib/component/transaction-search/service/transaction-search.service.d.ts +3 -1
- package/lib/component/transaction-search/transaction-search-result/transaction-search-result.component.d.ts +2 -3
- package/lib/component/transaction-search/transaction-search-tile/transaction-search-sales-order-tile/transaction-search-sales-order-tile.component.d.ts +0 -3
- package/lib/service/transaction-base.service.d.ts +1 -0
- package/package.json +3 -3
|
@@ -3,8 +3,8 @@ export class Version {
|
|
|
3
3
|
constructor() {
|
|
4
4
|
this.name = "@colijnit/transaction";
|
|
5
5
|
this.description = "Colijn IT transaction package";
|
|
6
|
-
this.symVer = "256.1.
|
|
7
|
-
this.publishDate = "
|
|
6
|
+
this.symVer = "256.1.5";
|
|
7
|
+
this.publishDate = "24-10-2024 16:56:37";
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
10
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHJhbnNhY3Rpb24tdmVyc2lvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL3RyYW5zYWN0aW9uL3NyYy9saWIvdHJhbnNhY3Rpb24tdmVyc2lvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSx1REFBdUQ7QUFDdkQsTUFBTSxPQUFPLE9BQU87SUFBcEI7UUFDUyxTQUFJLEdBQUcsdUJBQXVCLENBQUM7UUFDL0IsZ0JBQVcsR0FBRywrQkFBK0IsQ0FBQztRQUM5QyxXQUFNLEdBQUcsU0FBUyxDQUFDO1FBQ25CLGdCQUFXLEdBQUcscUJBQXFCLENBQUM7SUFDN0MsQ0FBQztDQUFBIiwic291cmNlc0NvbnRlbnQiOlsiLy8gdGhpcyBmaWxlIGlzIGR5bmFtaWNhbGx5IGNyZWF0ZWQsIGRvIG5vdCBjaGFuZ2UgdGhpc1xuZXhwb3J0IGNsYXNzIFZlcnNpb24ge1xuICBwdWJsaWMgbmFtZSA9IFwiQGNvbGlqbml0L3RyYW5zYWN0aW9uXCI7XG4gIHB1YmxpYyBkZXNjcmlwdGlvbiA9IFwiQ29saWpuIElUIHRyYW5zYWN0aW9uIHBhY2thZ2VcIjtcbiAgcHVibGljIHN5bVZlciA9IFwiMjU2LjEuNVwiO1xuICBwdWJsaWMgcHVibGlzaERhdGUgPSBcIjI0LTEwLTIwMjQgMTY6NTY6MzdcIjtcbn0iXX0=
|
|
@@ -278,8 +278,8 @@ class Version {
|
|
|
278
278
|
constructor() {
|
|
279
279
|
this.name = "@colijnit/transaction";
|
|
280
280
|
this.description = "Colijn IT transaction package";
|
|
281
|
-
this.symVer = "256.1.
|
|
282
|
-
this.publishDate = "
|
|
281
|
+
this.symVer = "256.1.5";
|
|
282
|
+
this.publishDate = "24-10-2024 16:56:37";
|
|
283
283
|
}
|
|
284
284
|
}
|
|
285
285
|
|
|
@@ -6672,55 +6672,55 @@ class TransactionConnectorService {
|
|
|
6672
6672
|
}
|
|
6673
6673
|
getCommissionCodes(languageCode) {
|
|
6674
6674
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6675
|
-
const domainName = DomainName.CommissionCode;
|
|
6676
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6677
|
-
|
|
6678
|
-
}).getValue(languageCode, domainName);
|
|
6675
|
+
//const domainName: DomainName = DomainName.CommissionCode;
|
|
6676
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6677
|
+
return this._adapterService.getCommissionCodes(languageCode);
|
|
6678
|
+
//}).getValue(languageCode, domainName);
|
|
6679
6679
|
});
|
|
6680
6680
|
}
|
|
6681
6681
|
getInOutCollection(languageCode) {
|
|
6682
6682
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6683
|
-
const domainName = DomainName.InOutCollection;
|
|
6684
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6685
|
-
|
|
6686
|
-
}).getValue(languageCode, domainName);
|
|
6683
|
+
//const domainName: DomainName = DomainName.InOutCollection;
|
|
6684
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6685
|
+
return this._adapterService.getInOutCollection(languageCode);
|
|
6686
|
+
//}).getValue(languageCode, domainName);
|
|
6687
6687
|
});
|
|
6688
6688
|
}
|
|
6689
6689
|
getYesNoCollection(languageCode) {
|
|
6690
6690
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6691
|
-
const domainName = DomainName.YesNo;
|
|
6692
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6693
|
-
|
|
6694
|
-
}).getValue(languageCode, domainName);
|
|
6691
|
+
//const domainName: DomainName = DomainName.YesNo;
|
|
6692
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6693
|
+
return this._adapterService.getYesNoCollection(languageCode);
|
|
6694
|
+
//}).getValue(languageCode, domainName);
|
|
6695
6695
|
});
|
|
6696
6696
|
}
|
|
6697
6697
|
getPriceKindCollection(languageCode) {
|
|
6698
6698
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6699
|
-
const domainName = DomainName.PriceKind;
|
|
6700
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6701
|
-
|
|
6702
|
-
}).getValue(languageCode, domainName);
|
|
6699
|
+
//const domainName: DomainName = DomainName.PriceKind;
|
|
6700
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6701
|
+
return this._adapterService.getPriceKindCollection(languageCode);
|
|
6702
|
+
//}).getValue(languageCode, domainName);
|
|
6703
6703
|
});
|
|
6704
6704
|
}
|
|
6705
6705
|
getPriorityCollection(languageCode) {
|
|
6706
6706
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6707
|
-
const domainName = DomainName.Priority;
|
|
6708
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6709
|
-
|
|
6710
|
-
}).getValue(languageCode, domainName);
|
|
6707
|
+
// const domainName: DomainName = DomainName.Priority;
|
|
6708
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6709
|
+
return this._adapterService.getPriorityCollection(languageCode);
|
|
6710
|
+
// }).getValue(languageCode, domainName);
|
|
6711
6711
|
});
|
|
6712
6712
|
}
|
|
6713
6713
|
getEntryTypes(languageCode) {
|
|
6714
|
-
const domainName = DomainName.ServiceCommunicationType;
|
|
6715
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6716
|
-
|
|
6717
|
-
}).getValue(languageCode, domainName);
|
|
6714
|
+
// const domainName: DomainName = DomainName.ServiceCommunicationType;
|
|
6715
|
+
//return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6716
|
+
return this._adapterService.getEntryTypes(languageCode);
|
|
6717
|
+
//}).getValue(languageCode, domainName);
|
|
6718
6718
|
}
|
|
6719
6719
|
getDomainTypes(languageCode) {
|
|
6720
|
-
const domainName = DomainName.TransType;
|
|
6721
|
-
return this._selectMultipleParameterizedCacheService.requestCache(CoDomainValue, (languageCode, domainName) => {
|
|
6722
|
-
|
|
6723
|
-
}).getValue(languageCode, domainName);
|
|
6720
|
+
// const domainName: DomainName = DomainName.TransType;
|
|
6721
|
+
// return this._selectMultipleParameterizedCacheService.requestCache<CoDomainValue>(CoDomainValue, (languageCode: string, domainName: DomainName) => {
|
|
6722
|
+
return this._adapterService.getDomainTypes(languageCode);
|
|
6723
|
+
//}).getValue(languageCode, domainName);
|
|
6724
6724
|
}
|
|
6725
6725
|
getCauseCodes() {
|
|
6726
6726
|
return this._adapterService.getCauseCodes();
|
|
@@ -9519,6 +9519,14 @@ class TransactionBaseService extends BaseModuleService {
|
|
|
9519
9519
|
this.invoiceAddressSameAsDelivery = true;
|
|
9520
9520
|
this.getRelationOnRememberCurrentTransaction = true;
|
|
9521
9521
|
this.currentTransaction = new TransactionInfoResponse();
|
|
9522
|
+
/*public set cashRegistersDirty(value: boolean) {
|
|
9523
|
+
this._cashRegistersDirty = value;
|
|
9524
|
+
//this.transactionEventService.transactionDirty.next(this._transactionDirty);
|
|
9525
|
+
}
|
|
9526
|
+
|
|
9527
|
+
public get cashRegistersDirty(): boolean {
|
|
9528
|
+
return this._cashRegistersDirty;
|
|
9529
|
+
}*/
|
|
9522
9530
|
this.purchasePortalLine = [];
|
|
9523
9531
|
this.docDeliveryBatch = new DocDeliveryBatch();
|
|
9524
9532
|
this.internalParameterAllowsDropShipment = false;
|
|
@@ -9544,6 +9552,7 @@ class TransactionBaseService extends BaseModuleService {
|
|
|
9544
9552
|
this._invoiceCompleted = false;
|
|
9545
9553
|
this._alreadyLocked = false;
|
|
9546
9554
|
this._transactionDirty = false;
|
|
9555
|
+
this._cashRegistersDirty = false;
|
|
9547
9556
|
this._salesOrderConfirmationSent = false;
|
|
9548
9557
|
this._subs = [];
|
|
9549
9558
|
}
|
|
@@ -12761,12 +12770,28 @@ class CheckoutComponent {
|
|
|
12761
12770
|
if (this.checkoutRelation && this.stepRelation) {
|
|
12762
12771
|
const valid = this.checkoutRelation.submit();
|
|
12763
12772
|
if (valid) {
|
|
12773
|
+
this.checkForAndSetSearchAddress();
|
|
12764
12774
|
this.stepRelation.completed = yield this.saveRelation();
|
|
12765
12775
|
}
|
|
12766
12776
|
return valid;
|
|
12767
12777
|
}
|
|
12768
12778
|
});
|
|
12769
12779
|
}
|
|
12780
|
+
//If a relation has no search address set the first active address to be such.
|
|
12781
|
+
checkForAndSetSearchAddress() {
|
|
12782
|
+
if (this.service.relation.activeAddresses.length > 0) {
|
|
12783
|
+
let searchAddressFound = false;
|
|
12784
|
+
this.service.relation.activeAddresses.forEach(address => {
|
|
12785
|
+
if (address.searchAddress) {
|
|
12786
|
+
searchAddressFound = true;
|
|
12787
|
+
return;
|
|
12788
|
+
}
|
|
12789
|
+
});
|
|
12790
|
+
if (!searchAddressFound) {
|
|
12791
|
+
this.service.relation.activeAddresses[0].searchAddress = true;
|
|
12792
|
+
}
|
|
12793
|
+
}
|
|
12794
|
+
}
|
|
12770
12795
|
handleDeliveryValidation() {
|
|
12771
12796
|
return __awaiter(this, void 0, void 0, function* () {
|
|
12772
12797
|
if (this.checkoutDelivery && this.stepDelivery) {
|
|
@@ -16600,6 +16625,8 @@ class TransactionSearchService {
|
|
|
16600
16625
|
[TransactionKind.CashDesk, "SEARCH_NUMBER_OR_CUSTOMER"]
|
|
16601
16626
|
]);
|
|
16602
16627
|
this.transactionsPerPage = 20;
|
|
16628
|
+
this.resultSubject = new BehaviorSubject(false);
|
|
16629
|
+
this.resultsUpdated = this.resultSubject.asObservable();
|
|
16603
16630
|
this._currentPage = 1;
|
|
16604
16631
|
this._transactionType = TransactionKind.SalesOrder;
|
|
16605
16632
|
this._subs = [];
|
|
@@ -16655,6 +16682,7 @@ class TransactionSearchService {
|
|
|
16655
16682
|
var _a, _b;
|
|
16656
16683
|
this.transactions = (_a = result.transactions) !== null && _a !== void 0 ? _a : [];
|
|
16657
16684
|
this.resultCount = (_b = result.count) !== null && _b !== void 0 ? _b : undefined;
|
|
16685
|
+
this.resultSubject.next(true);
|
|
16658
16686
|
});
|
|
16659
16687
|
this.setPreviousSearchRequest();
|
|
16660
16688
|
});
|
|
@@ -17172,25 +17200,6 @@ class TransactionSearchSalesOrderTileComponent extends TransactionSearchTileBase
|
|
|
17172
17200
|
statusBarGF: this.cfgNames.StatusBarGF
|
|
17173
17201
|
};
|
|
17174
17202
|
this.showAvatar = true;
|
|
17175
|
-
this.selectedTransactions = [];
|
|
17176
|
-
}
|
|
17177
|
-
onTransactionSelected(checked) {
|
|
17178
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
17179
|
-
console.log(checked);
|
|
17180
|
-
console.log(this.transaction);
|
|
17181
|
-
// save selected transactions
|
|
17182
|
-
if (checked) {
|
|
17183
|
-
this.selectedTransactions.push(this.transaction);
|
|
17184
|
-
}
|
|
17185
|
-
else {
|
|
17186
|
-
// const transId = this.transaction.id;
|
|
17187
|
-
// const index = this.selectedTransactions.findIndex(transaction => transaction.id === transId);
|
|
17188
|
-
// if (index !== -1) {
|
|
17189
|
-
// this.selectedTransactions.splice(index, 1);
|
|
17190
|
-
// }
|
|
17191
|
-
}
|
|
17192
|
-
console.log(this.selectedTransactions);
|
|
17193
|
-
});
|
|
17194
17203
|
}
|
|
17195
17204
|
}
|
|
17196
17205
|
TransactionSearchSalesOrderTileComponent.decorators = [
|
|
@@ -27146,40 +27155,58 @@ class TransactionLineDeliveryDateButtonComponent extends TransactionBaseComponen
|
|
|
27146
27155
|
this.showCalender = true;
|
|
27147
27156
|
this._calendarPopupComponentRef = this._overlayService.createComponent(CalendarComponent, {
|
|
27148
27157
|
parentForOverlay: this.parentComponent,
|
|
27149
|
-
selectedDate: new Date(this.transactionLine.deliveryDate
|
|
27158
|
+
selectedDate: new Date(this.transactionLine.deliveryDate
|
|
27159
|
+
? this.transactionLine.deliveryDate
|
|
27160
|
+
: new Date())
|
|
27150
27161
|
}, {
|
|
27151
27162
|
dateSelected: (date) => this._handleDateChanged(date),
|
|
27152
27163
|
clickedOutside: () => this.handleShowHideClick()
|
|
27153
27164
|
});
|
|
27154
27165
|
}
|
|
27166
|
+
// private _handleDateChanged(date: Date): void {
|
|
27167
|
+
// if (this.commitWhenDateSelected) {
|
|
27168
|
+
// this.handleCommit(date);
|
|
27169
|
+
// } else {
|
|
27170
|
+
// this.transactionLine.deliveryDate = date;
|
|
27171
|
+
// this.handleShowHideClick();
|
|
27172
|
+
// this.detectChanges();
|
|
27173
|
+
// }
|
|
27174
|
+
// }
|
|
27155
27175
|
_handleDateChanged(date) {
|
|
27156
|
-
|
|
27157
|
-
this.handleCommit(date);
|
|
27158
|
-
}
|
|
27159
|
-
else {
|
|
27160
|
-
this.transactionLine.deliveryDate = date;
|
|
27161
|
-
this.handleShowHideClick();
|
|
27162
|
-
this.detectChanges();
|
|
27163
|
-
}
|
|
27176
|
+
this.handleCommit(date);
|
|
27164
27177
|
}
|
|
27165
27178
|
_hidePopup() {
|
|
27166
27179
|
this.showCalender = false;
|
|
27167
27180
|
this._overlayService.removeComponent(this._calendarPopupComponentRef);
|
|
27168
27181
|
}
|
|
27182
|
+
// protected async commit(date: Date): Promise<boolean> {
|
|
27183
|
+
// if (this.transactionLine.deliveryDate !== date) {
|
|
27184
|
+
// const oldDate = this.transactionLine.deliveryDate;
|
|
27185
|
+
// const success = await this.transactionService.updateDeliveryDateTransactionLine(this.transactionInfo.uuid, this.transactionLine.uuid, date);
|
|
27186
|
+
// if (!success) {
|
|
27187
|
+
// this.transactionLine.deliveryDate = oldDate;
|
|
27188
|
+
// } else {
|
|
27189
|
+
// this.handleShowHideClick();
|
|
27190
|
+
// }
|
|
27191
|
+
// return success;
|
|
27192
|
+
// }
|
|
27193
|
+
// return true;
|
|
27194
|
+
// }
|
|
27169
27195
|
commit(date) {
|
|
27170
27196
|
return __awaiter(this, void 0, void 0, function* () {
|
|
27171
27197
|
if (this.transactionLine.deliveryDate !== date) {
|
|
27172
27198
|
const oldDate = this.transactionLine.deliveryDate;
|
|
27173
27199
|
const success = yield this.transactionService.updateDeliveryDateTransactionLine(this.transactionInfo.uuid, this.transactionLine.uuid, date);
|
|
27174
|
-
|
|
27175
|
-
|
|
27176
|
-
|
|
27177
|
-
else {
|
|
27178
|
-
this.handleShowHideClick();
|
|
27179
|
-
}
|
|
27200
|
+
!success && (this.transactionLine.deliveryDate = oldDate);
|
|
27201
|
+
this.handleShowHideClick();
|
|
27202
|
+
this.detectChanges();
|
|
27180
27203
|
return success;
|
|
27181
27204
|
}
|
|
27182
|
-
|
|
27205
|
+
else {
|
|
27206
|
+
this.handleShowHideClick();
|
|
27207
|
+
this.detectChanges();
|
|
27208
|
+
return true;
|
|
27209
|
+
}
|
|
27183
27210
|
});
|
|
27184
27211
|
}
|
|
27185
27212
|
}
|
|
@@ -27195,8 +27222,8 @@ TransactionLineDeliveryDateButtonComponent.decorators = [
|
|
|
27195
27222
|
[iconData]="iconCacheService.getIcon(icons.SharpLightTruckMovingClock)"
|
|
27196
27223
|
[label]="transactionLine.deliveryDate | date:'d MMM yyyy'"
|
|
27197
27224
|
[rightIconData]="iconCacheService.getIcon(icons.CalendarDayRegular)"
|
|
27198
|
-
(click)="handleShowHideClick()"
|
|
27199
|
-
|
|
27225
|
+
(click)="handleShowHideClick()">
|
|
27226
|
+
</co-transaction-button>
|
|
27200
27227
|
`,
|
|
27201
27228
|
providers: [
|
|
27202
27229
|
OverlayService,
|
|
@@ -30219,7 +30246,7 @@ TransactionPurchasePortalLineConfirmedDeliveryDateModule.decorators = [
|
|
|
30219
30246
|
];
|
|
30220
30247
|
|
|
30221
30248
|
class TransactionLineSupplierDeliveryDateButtonComponent extends TransactionBaseComponent {
|
|
30222
|
-
constructor(transactionEventService, service, iconCacheService, transactionScreenConfigurationService, dictionaryService, imageService, changeDetector, _overlayService
|
|
30249
|
+
constructor(transactionEventService, service, iconCacheService, transactionScreenConfigurationService, dictionaryService, imageService, changeDetector, _overlayService) {
|
|
30223
30250
|
super(transactionEventService, iconCacheService, transactionScreenConfigurationService, imageService, dictionaryService, service, changeDetector);
|
|
30224
30251
|
this.transactionEventService = transactionEventService;
|
|
30225
30252
|
this.service = service;
|
|
@@ -30229,7 +30256,6 @@ class TransactionLineSupplierDeliveryDateButtonComponent extends TransactionBase
|
|
|
30229
30256
|
this.imageService = imageService;
|
|
30230
30257
|
this.changeDetector = changeDetector;
|
|
30231
30258
|
this._overlayService = _overlayService;
|
|
30232
|
-
this._elementRef = _elementRef;
|
|
30233
30259
|
this.icons = Icon;
|
|
30234
30260
|
this.showCalender = false;
|
|
30235
30261
|
}
|
|
@@ -30271,14 +30297,16 @@ TransactionLineSupplierDeliveryDateButtonComponent.decorators = [
|
|
|
30271
30297
|
{ type: Component, args: [{
|
|
30272
30298
|
selector: 'co-transaction-line-supplier-delivery-date-button',
|
|
30273
30299
|
template: `
|
|
30274
|
-
|
|
30275
|
-
|
|
30276
|
-
|
|
30277
|
-
|
|
30278
|
-
|
|
30279
|
-
|
|
30280
|
-
|
|
30281
|
-
|
|
30300
|
+
<co-transaction-button
|
|
30301
|
+
#parentComponent
|
|
30302
|
+
class="big center-align"
|
|
30303
|
+
[hidden]="hidden"
|
|
30304
|
+
[readonly]="readonly"
|
|
30305
|
+
[iconData]="iconCacheService.getIcon(icons.RegularIndustryClock)"
|
|
30306
|
+
[label]="transactionLine.purchasePortalLine.deliveryDateConfirmed | date:'d MMM yyyy'"
|
|
30307
|
+
[rightIconData]="iconCacheService.getIcon(icons.CalendarDayRegular)"
|
|
30308
|
+
(click)="handleShowHideClick()">
|
|
30309
|
+
</co-transaction-button>
|
|
30282
30310
|
`,
|
|
30283
30311
|
providers: [
|
|
30284
30312
|
OverlayService,
|
|
@@ -30298,8 +30326,7 @@ TransactionLineSupplierDeliveryDateButtonComponent.ctorParameters = () => [
|
|
|
30298
30326
|
{ type: DictionaryService },
|
|
30299
30327
|
{ type: TransactionImageService },
|
|
30300
30328
|
{ type: ChangeDetectorRef },
|
|
30301
|
-
{ type: OverlayService }
|
|
30302
|
-
{ type: ElementRef }
|
|
30329
|
+
{ type: OverlayService }
|
|
30303
30330
|
];
|
|
30304
30331
|
TransactionLineSupplierDeliveryDateButtonComponent.propDecorators = {
|
|
30305
30332
|
parentComponent: [{ type: ViewChild, args: ['parentComponent', { read: ElementRef },] }],
|
|
@@ -31366,6 +31393,14 @@ class TransactionPaymentBaseComponent {
|
|
|
31366
31393
|
this.icons = Icon;
|
|
31367
31394
|
this.showKeyPad = true;
|
|
31368
31395
|
this._remainingPayment = false;
|
|
31396
|
+
/*@Input()
|
|
31397
|
+
public set showPaymentDate(value: boolean) {
|
|
31398
|
+
this._showPaymentDate = value;
|
|
31399
|
+
}
|
|
31400
|
+
|
|
31401
|
+
public get showPaymentDate(): boolean {
|
|
31402
|
+
return this._showPaymentDate;
|
|
31403
|
+
}*/
|
|
31369
31404
|
this.payed = new EventEmitter();
|
|
31370
31405
|
this.paymentMethodIdx = 0;
|
|
31371
31406
|
this.cashRegisterIdx = 0;
|
|
@@ -31380,6 +31415,7 @@ class TransactionPaymentBaseComponent {
|
|
|
31380
31415
|
// public statusMessage: string = "";
|
|
31381
31416
|
this.subs = [];
|
|
31382
31417
|
this._amount = 0;
|
|
31418
|
+
this._showPaymentDate = false;
|
|
31383
31419
|
}
|
|
31384
31420
|
set transId(value) {
|
|
31385
31421
|
this._transId = value;
|
|
@@ -31605,6 +31641,7 @@ class PaymentComponent extends TransactionPaymentBaseComponent {
|
|
|
31605
31641
|
super(...arguments);
|
|
31606
31642
|
this.showClass = true;
|
|
31607
31643
|
}
|
|
31644
|
+
/* public paymentDate:Date = new Date();*/
|
|
31608
31645
|
cashRegisterSelected(cashRegister, index) {
|
|
31609
31646
|
super.cashRegisterSelected(cashRegister, index);
|
|
31610
31647
|
this.activeCashRegister = cashRegister;
|
|
@@ -31663,6 +31700,9 @@ PaymentComponent.decorators = [
|
|
|
31663
31700
|
[disabled]="paymentService.amountToPay === 0"></co-button>
|
|
31664
31701
|
</div>
|
|
31665
31702
|
</div>
|
|
31703
|
+
<!--<div class="payment-bookdate" *ngIf="showPaymentDate">
|
|
31704
|
+
<co-input-date [(model)]="paymentDate"></co-input-date>
|
|
31705
|
+
</div>-->
|
|
31666
31706
|
<div class="payment-error-message" *ngIf="paymentService.statusMessage"
|
|
31667
31707
|
[textContent]="paymentService.statusMessage"></div>
|
|
31668
31708
|
</div>
|
|
@@ -31994,7 +32034,8 @@ PaymentModule.decorators = [
|
|
|
31994
32034
|
LoaderModule,
|
|
31995
32035
|
PaymentToPayModule,
|
|
31996
32036
|
IconModule,
|
|
31997
|
-
ListOfValuesModule
|
|
32037
|
+
ListOfValuesModule,
|
|
32038
|
+
InputDatePickerModule
|
|
31998
32039
|
],
|
|
31999
32040
|
declarations: [
|
|
32000
32041
|
PaymentComponent
|
|
@@ -40739,8 +40780,9 @@ TransactionHeaderPaymentComponent.decorators = [
|
|
|
40739
40780
|
[remainingPayment]="showRemainingPayment"
|
|
40740
40781
|
[currencyId]="transactionInfo.currencyId"
|
|
40741
40782
|
[doNotFetchAmountToPayForRemaining]="true"
|
|
40783
|
+
|
|
40742
40784
|
></co-payment>
|
|
40743
|
-
</co-dialog>
|
|
40785
|
+
</co-dialog> <!--[showPaymentDate]="true"-->
|
|
40744
40786
|
`,
|
|
40745
40787
|
providers: [
|
|
40746
40788
|
{ provide: SCREEN_CONFIG_ADAPTER_COMPONENT_INTERFACE_NAME, useExisting: forwardRef(() => TransactionHeaderPaymentComponent) }
|
|
@@ -47834,8 +47876,6 @@ class TransactionSearchResultComponent {
|
|
|
47834
47876
|
this.transactionClick = new EventEmitter();
|
|
47835
47877
|
this.screenConfigLoaded = false;
|
|
47836
47878
|
this.salesOrdersPageActive = false;
|
|
47837
|
-
this.batchDeliveryButtonLoader = true;
|
|
47838
|
-
this.selectAllOrders = false;
|
|
47839
47879
|
this.showProcessOrdersLoader = false;
|
|
47840
47880
|
this.selectedTransactions = [];
|
|
47841
47881
|
this._subs = [];
|
|
@@ -47874,6 +47914,10 @@ class TransactionSearchResultComponent {
|
|
|
47874
47914
|
if (config && config.length > 0) {
|
|
47875
47915
|
this.screenConfigLoaded = true;
|
|
47876
47916
|
}
|
|
47917
|
+
}), this.searchService.resultsUpdated.subscribe(() => {
|
|
47918
|
+
if (this.salesOrdersPageActive && this.batchCategory === 'levering') {
|
|
47919
|
+
this.markSelectedTransactions();
|
|
47920
|
+
}
|
|
47877
47921
|
}));
|
|
47878
47922
|
}
|
|
47879
47923
|
ngOnDestroy() {
|
|
@@ -47884,18 +47928,16 @@ class TransactionSearchResultComponent {
|
|
|
47884
47928
|
this.transactionClick.emit(transaction);
|
|
47885
47929
|
}
|
|
47886
47930
|
onSelectedClick(transaction) {
|
|
47887
|
-
console.log(transaction);
|
|
47888
47931
|
if (transaction.selected) {
|
|
47889
47932
|
this.selectedTransactions.push(transaction);
|
|
47890
47933
|
}
|
|
47891
47934
|
else {
|
|
47892
|
-
|
|
47893
|
-
|
|
47894
|
-
|
|
47895
|
-
|
|
47896
|
-
|
|
47935
|
+
const transId = transaction.transId;
|
|
47936
|
+
const index = this.selectedTransactions.findIndex(transaction => transaction.transId === transId);
|
|
47937
|
+
if (index !== -1) {
|
|
47938
|
+
this.selectedTransactions.splice(index, 1);
|
|
47939
|
+
}
|
|
47897
47940
|
}
|
|
47898
|
-
console.log(this.selectedTransactions);
|
|
47899
47941
|
}
|
|
47900
47942
|
onPreviousClick() {
|
|
47901
47943
|
this.searchService.currentPage -= 1;
|
|
@@ -47906,6 +47948,16 @@ class TransactionSearchResultComponent {
|
|
|
47906
47948
|
onPageClick(pageNr) {
|
|
47907
47949
|
this.searchService.currentPage = pageNr;
|
|
47908
47950
|
}
|
|
47951
|
+
markSelectedTransactions() {
|
|
47952
|
+
if (this.searchService.resultsUpdated) {
|
|
47953
|
+
this.searchService.transactions.forEach(transaction => {
|
|
47954
|
+
const matchingObject = this.selectedTransactions.find(selectedTransaction => selectedTransaction.transId === transaction.transId);
|
|
47955
|
+
if (matchingObject) {
|
|
47956
|
+
transaction.selected = true;
|
|
47957
|
+
}
|
|
47958
|
+
});
|
|
47959
|
+
}
|
|
47960
|
+
}
|
|
47909
47961
|
dragStarted(ev, transaction) {
|
|
47910
47962
|
this._deliveryPlanningService.dragging = true;
|
|
47911
47963
|
this._deliveryPlanningService.currentTransId = transaction.transId;
|
|
@@ -47943,7 +47995,7 @@ class TransactionSearchResultComponent {
|
|
|
47943
47995
|
printDeliveryNoteRequest = new PrintDeliveryNoteRequest();
|
|
47944
47996
|
}
|
|
47945
47997
|
this.transactionService.printDeliveryNotes(printDeliveryNotesRequest)
|
|
47946
|
-
.then((
|
|
47998
|
+
.then(() => {
|
|
47947
47999
|
this.showProcessOrdersLoader = false;
|
|
47948
48000
|
})
|
|
47949
48001
|
.catch(() => {
|
|
@@ -47951,8 +48003,12 @@ class TransactionSearchResultComponent {
|
|
|
47951
48003
|
});
|
|
47952
48004
|
});
|
|
47953
48005
|
}
|
|
47954
|
-
onSelectAllOrders() {
|
|
47955
|
-
this.searchService.transactions.forEach(item => item.selected = !
|
|
48006
|
+
onSelectAllOrders(allSelected) {
|
|
48007
|
+
this.searchService.transactions.forEach(item => item.selected = !allSelected);
|
|
48008
|
+
this.selectedTransactions = [];
|
|
48009
|
+
if (!allSelected) {
|
|
48010
|
+
this.selectedTransactions.push(...this.searchService.transactions);
|
|
48011
|
+
}
|
|
47956
48012
|
}
|
|
47957
48013
|
_createRequestLines(selectedLines) {
|
|
47958
48014
|
return selectedLines.map((line) => {
|
|
@@ -47974,7 +48030,7 @@ TransactionSearchResultComponent.decorators = [
|
|
|
47974
48030
|
<co-input-checkbox
|
|
47975
48031
|
[model]="checkIfAllSelected()"
|
|
47976
48032
|
[label]="'SELECT_ALL_ORDERS' | localize"
|
|
47977
|
-
(modelChange)="onSelectAllOrders()">
|
|
48033
|
+
(modelChange)="onSelectAllOrders(checkIfAllSelected())">
|
|
47978
48034
|
</co-input-checkbox>
|
|
47979
48035
|
<co-quick-send-button
|
|
47980
48036
|
*ngIf="checkIfSelected()"
|
|
@@ -55266,6 +55322,19 @@ class TransactionComponent {
|
|
|
55266
55322
|
}
|
|
55267
55323
|
});
|
|
55268
55324
|
}
|
|
55325
|
+
else if (this.transactionKind === TransactionKind.CashDesk) {
|
|
55326
|
+
this._transactionConnectorService.connectionInitialized.pipe(take(1)).subscribe((loaded) => {
|
|
55327
|
+
if (loaded) {
|
|
55328
|
+
this._screenConfigurationService.loadConfig([this.transactionKind]).then(() => __awaiter(this, void 0, void 0, function* () {
|
|
55329
|
+
if (this.transactionNr) {
|
|
55330
|
+
yield this.service.getTransactionByNrAndKind(this.transactionNr, this.transactionKind);
|
|
55331
|
+
}
|
|
55332
|
+
this._prepareHeader();
|
|
55333
|
+
this.screenConfigLoaded = true;
|
|
55334
|
+
}));
|
|
55335
|
+
}
|
|
55336
|
+
});
|
|
55337
|
+
}
|
|
55269
55338
|
}
|
|
55270
55339
|
_prepareHeader() {
|
|
55271
55340
|
if (this._screenConfigurationService.getObjectConfigurationFor(this.cfgNames.RelationInfoHeader).immediatelyHidden() &&
|