@colijnit/transaction 254.1.22 → 254.1.24

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.
@@ -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 = "254.1.22";
37
- this.publishDate = "12-7-2024 13:09:49";
36
+ this.symVer = "254.1.24";
37
+ this.publishDate = "15-7-2024 11:04:44";
38
38
  }
39
39
  return Version;
40
40
  }());
@@ -32630,6 +32630,7 @@
32630
32630
  this.paymentFailed = new rxjs.Subject();
32631
32631
  this.pollingForStatusStarted = new rxjs.Subject();
32632
32632
  this.pollingForStatusEnded = new rxjs.Subject();
32633
+ this.doNotFetchAmountToPayForRemaining = false;
32633
32634
  this._paymentStatusPollIntervalMs = 5000;
32634
32635
  this._paymentStatusMaxPollInterval = 60;
32635
32636
  this._paymentStatusPollIntervalCount = 0;
@@ -32742,15 +32743,19 @@
32742
32743
  if (info) {
32743
32744
  this.amountToPay = info.depositRemainderAmount;
32744
32745
  }
32745
- return [3 /*break*/, 4];
32746
- case 2: return [4 /*yield*/, this._paymentConnectorService.getRegisteredPaymentInfo(this.transactionUuid)];
32747
- case 3:
32746
+ return [3 /*break*/, 5];
32747
+ case 2:
32748
+ if (!this.doNotFetchAmountToPayForRemaining) return [3 /*break*/, 3];
32749
+ this.amountToPay = this.amount;
32750
+ return [3 /*break*/, 5];
32751
+ case 3: return [4 /*yield*/, this._paymentConnectorService.getRegisteredPaymentInfo(this.transactionUuid)];
32752
+ case 4:
32748
32753
  info = _a.sent();
32749
32754
  if (info) {
32750
32755
  this.amountToPay = this.amount - info.totalAmount;
32751
32756
  }
32752
- _a.label = 4;
32753
- case 4: return [2 /*return*/];
32757
+ _a.label = 5;
32758
+ case 5: return [2 /*return*/];
32754
32759
  }
32755
32760
  });
32756
32761
  });
@@ -33037,6 +33042,17 @@
33037
33042
  enumerable: false,
33038
33043
  configurable: true
33039
33044
  });
33045
+ Object.defineProperty(TransactionPaymentBaseComponent.prototype, "doNotFetchAmountToPayForRemaining", {
33046
+ get: function () {
33047
+ return this._doNotFetchAmountToPayForRemaining;
33048
+ },
33049
+ set: function (value) {
33050
+ this._doNotFetchAmountToPayForRemaining = value;
33051
+ this.paymentService.doNotFetchAmountToPayForRemaining = this._doNotFetchAmountToPayForRemaining;
33052
+ },
33053
+ enumerable: false,
33054
+ configurable: true
33055
+ });
33040
33056
  TransactionPaymentBaseComponent.prototype.ngOnInit = function () {
33041
33057
  return __awaiter(this, void 0, void 0, function () {
33042
33058
  var _this = this;
@@ -33157,6 +33173,7 @@
33157
33173
  showKeyPad: [{ type: i0.Input }],
33158
33174
  remainingPayment: [{ type: i0.Input }],
33159
33175
  currentPaymentMethod: [{ type: i0.Input }],
33176
+ doNotFetchAmountToPayForRemaining: [{ type: i0.Input }],
33160
33177
  payed: [{ type: i0.Output }]
33161
33178
  };
33162
33179
 
@@ -40512,7 +40529,7 @@
40512
40529
  TransactionHeaderPaymentComponent.decorators = [
40513
40530
  { type: i0.Component, args: [{
40514
40531
  selector: "co-transaction-header-payment",
40515
- template: "\n <div class=\"transaction-header-payment-wrapper\">\n <div class=\"transaction-header-payment-wrapper-content\" [class.show-remaining]=\"showRemainingPayment\">\n <co-transaction-header-block\n [firstBlockTemplate]=\"firstBlock\"\n [secondBlockTemplate]=\"secondBlock\"\n [thirdBlockTemplate]=\"thirdBlock\"\n [hiddenBlockTemplate]=\"hiddenBlock\"\n (headerClick)=\"showDialog = true\"\n >\n </co-transaction-header-block>\n <co-transaction-header-block *ngIf=\"showRemainingPayment\"\n [firstBlockTemplate]=\"firstBlockRest\"\n (headerClick)=\"showDialog = true\"\n >\n </co-transaction-header-block>\n </div>\n </div>\n <ng-template #firstBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"transaction-header-icon\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAvatarHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\"\n (click)=\"showDialog = true\"\n [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegular)\">\n </co-icon>\n </div>\n <div class=\"header-downpayment-amount-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'DOWNPAYMENT_AMOUNT' | localize\"></div>\n <co-transaction-header-deposit-amount class=\"transaction-header-deposit\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\"\n [transaction]=\"transaction\"\n [defaultEditMode]=\"false\"\n [showLabel]=\"false\"\n ></co-transaction-header-deposit-amount>\n </div>\n </div>\n </ng-template>\n <ng-template #firstBlockRest>\n <div class=\"transaction-header-block-row\">\n <div class=\"transaction-header-icon\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAvatarHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\"\n (click)=\"showPaymentDialog = true\"\n [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\">\n </co-icon>\n </div>\n <div class=\"header-remaining-payment-amount-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'REMAINING_PAYMENT' | localize\"></div>\n <co-transaction-header-remaining-amount class=\"transaction-header-remaining\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\"\n [transactionUuid]=\"transaction.transactionInfo.uuid\"\n (remainingAmountChange)=\"remainingToPay = $event\"\n ></co-transaction-header-remaining-amount>\n </div>\n </div>\n </ng-template>\n <ng-template #secondBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"header-downpayment-percentage-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentPercentageHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'%' | localize\"></div>\n <co-transaction-header-deposit-percentage class=\"transaction-header-deposit\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentPercentageHeader\"\n [transactionInfo]=\"transactionInfo\"\n [defaultEditMode]=\"false\"\n [showLabel]=\"false\"\n ></co-transaction-header-deposit-percentage>\n </div>\n </div>\n </ng-template>\n <ng-template #thirdBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"header-payment-button-wrapper\" (click)=\"openPayment($event)\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentPaymentHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\" [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\">\n </co-icon>\n <div class=\"spacer\"></div>\n <div class=\"payment-payed-wrapper\">\n <!--div class=\"header-payed-label co-transaction-label\" [textContent]=\"'DOWNPAYMENT_DONE' | localize\"></div-->\n <span class=\"payment-paid\" [class.success]=\"paid >= toPay\" [textContent]=\"(paid | coCurrency) || 0\"></span>\n </div>\n <!--co-transaction-header-payment-button *ngIf=\"transactionInfo.transactionKind !== transKind.PurchaseOrder\"\n [transactionInfo]=\"transactionInfo\"\n ></co-transaction-header-payment-button-->\n </div>\n </div>\n </ng-template>\n <ng-template #hiddenBlock>\n <!--div class=\"transaction-header-block-row\">\n <div class=\"header-branch-label co-transaction-label\" [textContent]=\"'BRANCH' | localize\"></div>\n <div class=\"branch-label\" [textContent]=\"transactionInfo.branch?.familyName\"></div>\n </div-->\n </ng-template>\n <co-transaction-header-popup *ngIf=\"showDialog\"\n [activeCategoryDescription]=\"'PAYMENT_INFORMATION'\"\n [relation]=\"relation\"\n [transaction]=\"transaction\"\n (closeClick)=\"showDialog = false\"></co-transaction-header-popup>\n<!--\n <co-dialog class=\"transaction-header-payment-dialog\" [headerTemplate]=\"headerTemplate\" *ngIf=\"showDialog\" (closeClick)=\"showDialog = false\">\n <ng-template #headerTemplate>\n <div class=\"co-dialog-header-title\" [textContent]=\"'PAYMENT_INFORMATION' | localize\"></div>\n <co-transaction-header-block\n [headerBlockTemplate]=\"headerBlock\"\n [firstBlockTemplate]=\"firstBlock\"\n [secondBlockTemplate]=\"secondBlock\"\n >\n </co-transaction-header-block>\n </ng-template>\n <div class=\"payment-dialog-section\">\n <co-deposit-payment [branch]=\"transactionInfo.branch?.relationNr\" [transactionUuid]=\"transactionInfo.uuid\"></co-deposit-payment>\n </div>\n </co-dialog>\n-->\n <co-dialog class=\"payment-dialog\" [modal]=\"true\" [headerTemplate]=\"headerTemplate\" *ngIf=\"showPaymentDialog\" (closeClick)=\"showPaymentDialog = false\">\n <ng-template #headerTemplate>\n <div class=\"co-dialog-wrapper-popup-title\">\n <co-icon [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\"></co-icon>\n <div class=\"co-dialog-header-title\" [textContent]=\"'PAYMENT_METHOD' | localize\"></div>\n </div>\n </ng-template>\n <co-payment\n [transId]=\"transactionInfo.id\"\n [branch]=\"transactionInfo.branch?.relationNr\"\n [transactionUuid]=\"transactionInfo.uuid\"\n [amount]=\"showRemainingPayment ? remainingToPay : toPay\"\n [remainingPayment]=\"showRemainingPayment\"\n [currencyId]=\"transactionInfo.currencyId\"\n ></co-payment>\n </co-dialog>\n ",
40532
+ template: "\n <div class=\"transaction-header-payment-wrapper\">\n <div class=\"transaction-header-payment-wrapper-content\" [class.show-remaining]=\"showRemainingPayment\">\n <co-transaction-header-block\n [firstBlockTemplate]=\"firstBlock\"\n [secondBlockTemplate]=\"secondBlock\"\n [thirdBlockTemplate]=\"thirdBlock\"\n [hiddenBlockTemplate]=\"hiddenBlock\"\n (headerClick)=\"showDialog = true\"\n >\n </co-transaction-header-block>\n <co-transaction-header-block *ngIf=\"showRemainingPayment\"\n [firstBlockTemplate]=\"firstBlockRest\"\n (headerClick)=\"showDialog = true\"\n >\n </co-transaction-header-block>\n </div>\n </div>\n <ng-template #firstBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"transaction-header-icon\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAvatarHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\"\n (click)=\"showDialog = true\"\n [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegular)\">\n </co-icon>\n </div>\n <div class=\"header-downpayment-amount-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'DOWNPAYMENT_AMOUNT' | localize\"></div>\n <co-transaction-header-deposit-amount class=\"transaction-header-deposit\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\"\n [transaction]=\"transaction\"\n [defaultEditMode]=\"false\"\n [showLabel]=\"false\"\n ></co-transaction-header-deposit-amount>\n </div>\n </div>\n </ng-template>\n <ng-template #firstBlockRest>\n <div class=\"transaction-header-block-row\">\n <div class=\"transaction-header-icon\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAvatarHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\"\n (click)=\"showPaymentDialog = true\"\n [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\">\n </co-icon>\n </div>\n <div class=\"header-remaining-payment-amount-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'REMAINING_PAYMENT' | localize\"></div>\n <co-transaction-header-remaining-amount class=\"transaction-header-remaining\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentAmountHeader\"\n [transactionUuid]=\"transaction.transactionInfo.uuid\"\n (remainingAmountChange)=\"remainingToPay = $event\"\n ></co-transaction-header-remaining-amount>\n </div>\n </div>\n </ng-template>\n <ng-template #secondBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"header-downpayment-percentage-wrapper\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentPercentageHeader\" screenConfigNativeElement>\n <div class=\"header-deposit-label co-transaction-label\" [textContent]=\"'%' | localize\"></div>\n <co-transaction-header-deposit-percentage class=\"transaction-header-deposit\"\n [screenConfigurationObject]=\"cfgNames.HeaderPaymentPercentageHeader\"\n [transactionInfo]=\"transactionInfo\"\n [defaultEditMode]=\"false\"\n [showLabel]=\"false\"\n ></co-transaction-header-deposit-percentage>\n </div>\n </div>\n </ng-template>\n <ng-template #thirdBlock>\n <div class=\"transaction-header-block-row\">\n <div class=\"header-payment-button-wrapper\" (click)=\"openPayment($event)\" [screenConfigurationObject]=\"cfgNames.HeaderPaymentPaymentHeader\" screenConfigNativeElement>\n <co-icon class=\"header-order-icon\" [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\">\n </co-icon>\n <div class=\"spacer\"></div>\n <div class=\"payment-payed-wrapper\">\n <!--div class=\"header-payed-label co-transaction-label\" [textContent]=\"'DOWNPAYMENT_DONE' | localize\"></div-->\n <span class=\"payment-paid\" [class.success]=\"paid >= toPay\" [textContent]=\"(paid | coCurrency) || 0\"></span>\n </div>\n <!--co-transaction-header-payment-button *ngIf=\"transactionInfo.transactionKind !== transKind.PurchaseOrder\"\n [transactionInfo]=\"transactionInfo\"\n ></co-transaction-header-payment-button-->\n </div>\n </div>\n </ng-template>\n <ng-template #hiddenBlock>\n <!--div class=\"transaction-header-block-row\">\n <div class=\"header-branch-label co-transaction-label\" [textContent]=\"'BRANCH' | localize\"></div>\n <div class=\"branch-label\" [textContent]=\"transactionInfo.branch?.familyName\"></div>\n </div-->\n </ng-template>\n <co-transaction-header-popup *ngIf=\"showDialog\"\n [activeCategoryDescription]=\"'PAYMENT_INFORMATION'\"\n [relation]=\"relation\"\n [transaction]=\"transaction\"\n (closeClick)=\"showDialog = false\"></co-transaction-header-popup>\n<!--\n <co-dialog class=\"transaction-header-payment-dialog\" [headerTemplate]=\"headerTemplate\" *ngIf=\"showDialog\" (closeClick)=\"showDialog = false\">\n <ng-template #headerTemplate>\n <div class=\"co-dialog-header-title\" [textContent]=\"'PAYMENT_INFORMATION' | localize\"></div>\n <co-transaction-header-block\n [headerBlockTemplate]=\"headerBlock\"\n [firstBlockTemplate]=\"firstBlock\"\n [secondBlockTemplate]=\"secondBlock\"\n >\n </co-transaction-header-block>\n </ng-template>\n <div class=\"payment-dialog-section\">\n <co-deposit-payment [branch]=\"transactionInfo.branch?.relationNr\" [transactionUuid]=\"transactionInfo.uuid\"></co-deposit-payment>\n </div>\n </co-dialog>\n-->\n <co-dialog class=\"payment-dialog\" [modal]=\"true\" [headerTemplate]=\"headerTemplate\" *ngIf=\"showPaymentDialog\" (closeClick)=\"showPaymentDialog = false\">\n <ng-template #headerTemplate>\n <div class=\"co-dialog-wrapper-popup-title\">\n <co-icon [iconData]=\"iconCacheService.getIcon(icons.CreditCardRegularCheck)\"></co-icon>\n <div class=\"co-dialog-header-title\" [textContent]=\"'PAYMENT_METHOD' | localize\"></div>\n </div>\n </ng-template>\n <co-payment\n [transId]=\"transactionInfo.id\"\n [branch]=\"transactionInfo.branch?.relationNr\"\n [transactionUuid]=\"transactionInfo.uuid\"\n [amount]=\"showRemainingPayment ? remainingToPay : toPay\"\n [remainingPayment]=\"showRemainingPayment\"\n [currencyId]=\"transactionInfo.currencyId\"\n [doNotFetchAmountToPayForRemaining]=\"true\"\n ></co-payment>\n </co-dialog>\n ",
40516
40533
  providers: [
40517
40534
  { provide: corecomponents_v12.SCREEN_CONFIG_ADAPTER_COMPONENT_INTERFACE_NAME, useExisting: i0.forwardRef(function () { return TransactionHeaderPaymentComponent; }) }
40518
40535
  ],
@@ -40550,7 +40567,7 @@
40550
40567
  request.transactionUuid = _this.transactionUuid;
40551
40568
  _this._paymentConnectorService.calculateAmountToPayWithLineSelection(request).then(function (data) {
40552
40569
  _this.transactionService.remainingAmount = data ? data.amountToPay : 0;
40553
- _this.remainingAmountChange.next(data ? data.amountSelected : 0);
40570
+ _this.remainingAmountChange.next(data ? data.amountToPay : 0);
40554
40571
  });
40555
40572
  }
40556
40573
  }));