feat(savings,deposits,current-accounts): streamline account activation flow
Matches the backend change that stopped auto-depositing money at activation: removes the opening-balance field from every Activate screen (Savings, Current, FD, RD) since funding now happens as a separate deposit afterward, and removes the Digital-Facility step from every Create wizard since every facility starts disabled by default and gets turned on later through Edit Nominee & Features. Also merges Approve+Activate into a single action for Savings, Current, FD and RD accounts -- one click takes the account straight to Active instead of two separate screens.
This commit is contained in:
+1
@@ -10,6 +10,7 @@
|
||||
<mat-card>
|
||||
<form [formGroup]="approveFixedDepositsAccountForm" (ngSubmit)="submit()">
|
||||
<mat-card-content>
|
||||
<p class="mat-body-2">This approves and activates the account in one step -- it goes straight to Active.</p>
|
||||
<div class="layout-column">
|
||||
<mat-form-field (click)="approvedOnDatePicker.open()">
|
||||
<mat-label>{{ 'labels.inputs.Approved On Date' | translate }}</mat-label>
|
||||
|
||||
+13
-3
@@ -81,8 +81,9 @@ export class ApproveFixedDepositsAccountComponent implements OnInit {
|
||||
}
|
||||
|
||||
/**
|
||||
* Submits the form and approves the fixed deposit account,
|
||||
* if successful redirects to the fixed deposit account.
|
||||
* Submits the form, approves the fixed deposit account, then immediately activates it on the
|
||||
* same date -- Approve and Activate are still two separate Fineract commands underneath (each
|
||||
* shows up in the audit trail), but the officer only sees and clicks through one step.
|
||||
*/
|
||||
submit() {
|
||||
const approveFixedDepositsAccountFormData = this.approveFixedDepositsAccountForm.value;
|
||||
@@ -98,7 +99,16 @@ export class ApproveFixedDepositsAccountComponent implements OnInit {
|
||||
locale
|
||||
};
|
||||
this.fixedDepositsService.executeFixedDepositsAccountCommand(this.accountId, 'approve', data).subscribe(() => {
|
||||
this.router.navigate(['../../'], { relativeTo: this.route });
|
||||
const activationData = {
|
||||
activatedOnDate: approveFixedDepositsAccountFormData.approvedOnDate,
|
||||
dateFormat,
|
||||
locale
|
||||
};
|
||||
this.fixedDepositsService
|
||||
.executeFixedDepositsAccountCommand(this.accountId, 'activate', activationData)
|
||||
.subscribe(() => {
|
||||
this.router.navigate(['../../'], { relativeTo: this.route });
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
+1
@@ -10,6 +10,7 @@
|
||||
<mat-card>
|
||||
<form [formGroup]="approveRecurringDepositsAccountForm" (ngSubmit)="submit()">
|
||||
<mat-card-content>
|
||||
<p class="mat-body-2">This approves and activates the account in one step -- it goes straight to Active.</p>
|
||||
<div class="layout-column">
|
||||
<mat-form-field (click)="approvedOnDatePicker.open()">
|
||||
<mat-label>{{ 'labels.inputs.Approved On Date' | translate }}</mat-label>
|
||||
|
||||
+13
-3
@@ -81,8 +81,9 @@ export class ApproveRecurringDepositsAccountComponent implements OnInit {
|
||||
}
|
||||
|
||||
/**
|
||||
* Submits the form and approves the recurring deposit account,
|
||||
* if successful redirects to the recurring deposit account.
|
||||
* Submits the form, approves the recurring deposit account, then immediately activates it on
|
||||
* the same date -- Approve and Activate are still two separate Fineract commands underneath
|
||||
* (each shows up in the audit trail), but the officer only sees and clicks through one step.
|
||||
*/
|
||||
submit() {
|
||||
const approveRecurringDepositsAccountFormData = this.approveRecurringDepositsAccountForm.value;
|
||||
@@ -103,7 +104,16 @@ export class ApproveRecurringDepositsAccountComponent implements OnInit {
|
||||
this.recurringDepositsService
|
||||
.executeRecurringDepositsAccountCommand(this.accountId, 'approve', data)
|
||||
.subscribe(() => {
|
||||
this.router.navigate(['../../'], { relativeTo: this.route });
|
||||
const activationData = {
|
||||
activatedOnDate: approveRecurringDepositsAccountFormData.approvedOnDate,
|
||||
dateFormat,
|
||||
locale
|
||||
};
|
||||
this.recurringDepositsService
|
||||
.executeRecurringDepositsAccountCommand(this.accountId, 'activate', activationData)
|
||||
.subscribe(() => {
|
||||
this.router.navigate(['../../'], { relativeTo: this.route });
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user