Fix waive loan charge button

This commit is contained in:
Jose Alberto Hernandez
2022-10-28 16:52:28 +02:00
committed by Arnold Gálovics
parent eaa58a7caf
commit 1b9df689d9
2 changed files with 3 additions and 3 deletions
@@ -133,7 +133,7 @@ export class BreadcrumbComponent implements OnInit, AfterViewInit {
} else if (routeData.breadcrumb === 'Loan Products') {
breadcrumbLabel = routeData.loanProduct.name;
} else if (routeData.breadcrumb === 'Charges') {
breadcrumbLabel = routeData.charge.name;
breadcrumbLabel = routeData.loansAccountCharge.name;
} else if (routeData.breadcrumb === 'Saving Products') {
breadcrumbLabel = routeData.savingProduct.name;
} else if (routeData.breadcrumb === 'Share Products') {
@@ -90,7 +90,7 @@ export class ViewChargeComponent {
dateFormat,
locale
};
this.loansService.executeLoansAccountChargesCommand(this.chargeData.accountId, 'paycharge', dataObject, this.chargeData.id)
this.loansService.executeLoansAccountChargesCommand(this.chargeData.loanId, 'paycharge', dataObject, this.chargeData.id)
.subscribe(() => {
this.reload();
});
@@ -105,7 +105,7 @@ export class ViewChargeComponent {
const waiveChargeDialogRef = this.dialog.open(ConfirmationDialogComponent, { data: { heading: 'Waive Charge', dialogContext: `Are you sure you want to waive charge with id: ${this.chargeData.id}`, type: 'Basic' } });
waiveChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.confirm) {
this.loansService.executeLoansAccountChargesCommand(this.chargeData.accountId, 'waive', {}, this.chargeData.id)
this.loansService.executeLoansAccountChargesCommand(this.chargeData.loanId, 'waive', {}, this.chargeData.id)
.subscribe(() => {
this.reload();
});