refactor: Loans Module (#1150)

Fixes: #1149
This commit is contained in:
Muskan Khedia
2020-07-22 20:32:55 +05:30
committed by GitHub
parent f618bb3cda
commit 55280eae2a
65 changed files with 622 additions and 470 deletions
@@ -33,7 +33,8 @@ export class LoanAccountActionsComponent {
withdrawn_by_client: boolean,
undo_disbursal: boolean,
loan_screen_reports: boolean,
approve: boolean } = {
approve: boolean,
add_loan_charge: boolean } = {
close: false,
undo_approval: false,
write_off: false,
@@ -54,7 +55,8 @@ export class LoanAccountActionsComponent {
withdrawn_by_client: false,
undo_disbursal: false,
loan_screen_reports: false,
approve: false };
approve: false,
add_loan_charge: false };
actionButtonData: any;
actionName: any;
@@ -74,6 +76,9 @@ export class LoanAccountActionsComponent {
if (this.actionName === 'change-loan-officer') {
this.actionName = 'assign-loan-officer';
}
for (const key of Object.keys(this.actions)) {
this.actions[key] = false;
}
this.actions[this.actionName.replace(/-/g, '_')] = true;
});
}