@hmcts/ccpay-web-component 6.1.5 → 6.1.6

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.
@@ -3751,25 +3751,25 @@ class AddRemissionComponent {
3751
3751
  this.viewCompStatus = '';
3752
3752
  this.isRefundRemission = true;
3753
3753
  this.errorMessage = '';
3754
+ this.isConfirmationBtnDisabled = false;
3754
3755
  }
3755
3756
  confirmRetroRemission() {
3756
- if (!this.isConfirmationBtnDisabled) {
3757
- this.retroRemission = true;
3758
- this.remissionamt = this.remissionForm.controls.amount.value;
3759
- const requestBody = new AddRetroRemissionRequest(this.remissionamt, this.remissionForm.controls.remissionCode.value);
3760
- this.paymentViewService.postPaymentGroupWithRetroRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(response => {
3761
- if (JSON.parse(response)) {
3762
- this.isRemissionApplied = true;
3763
- this.viewCompStatus = '';
3764
- this.viewStatus = 'retroremissionconfirmationpage';
3765
- this.remissionReference = JSON.parse(response).remission_reference;
3766
- }
3767
- }, (error) => {
3768
- this.errorMessage = error;
3769
- this.isConfirmationBtnDisabled = false;
3770
- this.cd.detectChanges();
3771
- });
3772
- }
3757
+ this.isConfirmationBtnDisabled = true;
3758
+ this.retroRemission = true;
3759
+ this.remissionamt = this.remissionForm.controls.amount.value;
3760
+ const requestBody = new AddRetroRemissionRequest(this.remissionamt, this.remissionForm.controls.remissionCode.value);
3761
+ this.paymentViewService.postPaymentGroupWithRetroRemissions(decodeURIComponent(this.paymentGroupRef).trim(), this.fee.id, requestBody).subscribe(response => {
3762
+ if (JSON.parse(response)) {
3763
+ this.isRemissionApplied = true;
3764
+ this.viewCompStatus = '';
3765
+ this.viewStatus = 'retroremissionconfirmationpage';
3766
+ this.remissionReference = JSON.parse(response).remission_reference;
3767
+ }
3768
+ }, (error) => {
3769
+ this.errorMessage = error;
3770
+ this.isConfirmationBtnDisabled = false;
3771
+ this.cd.detectChanges();
3772
+ });
3773
3773
  }
3774
3774
  processRefund() {
3775
3775
  this.errorMessage = '';