feat: savings account actions (approve) (#906)

Fixes: #905
This commit is contained in:
Karan Takalkar
2020-06-24 22:30:18 +05:30
committed by GitHub
parent 9d64300137
commit a9cd990184
13 changed files with 279 additions and 125 deletions
@@ -3,7 +3,7 @@ import { Component } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
/**
* Create savings account actions component.
* Savings account actions component.
*/
@Component({
selector: 'mifosx-saving-account-actions',
@@ -12,15 +12,21 @@ import { Router, ActivatedRoute } from '@angular/router';
})
export class SavingAccountActionsComponent {
/** flag object to store possible actions and render appropriate UI to the user */
actions: { transaction: boolean } = { transaction: false };
/** Shares Account Data */
sharesAccountData: any;
/** Flag object to store possible actions and render appropriate UI to the user */
actions: {
'Approve': boolean
} = {
'Approve': false
};
constructor(private router: Router,
private route: ActivatedRoute) {
this.route.params.subscribe(params => {
this.actions[params['action']] = true;
});
/**
* @param {ActivatedRoute} route Activated Route
*/
constructor(private route: ActivatedRoute) {
const name = this.route.snapshot.params['name'];
this.actions[name] = true;
}
}