Savings product datatables (#1646)
Co-authored-by: Jose Alberto Hernandez <alberto@MacBook-Pro.local>
This commit is contained in:
co-authored by
Jose Alberto Hernandez
parent
b6c5f0e41e
commit
00ceeed3f2
@@ -14,3 +14,9 @@ export const entitySubTypeData: { displayValue: string, value: string }[] = [
|
||||
{ displayValue: 'Person', value: 'Person' },
|
||||
{ displayValue: 'Entity', value: 'Entity' },
|
||||
];
|
||||
|
||||
export const savingsSubTypeData: { displayValue: string, value: string }[] = [
|
||||
{ displayValue: 'Savings Product', value: 'Savings Product' },
|
||||
{ displayValue: 'Fixed Deposit', value: 'Fixed Deposit' },
|
||||
{ displayValue: 'Recurring Deposit', value: 'Recurring Deposit' },
|
||||
];
|
||||
|
||||
@@ -37,6 +37,15 @@
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field fxFlex="20%" *ngIf="showSavingsSubType">
|
||||
<mat-label>Savings SubType</mat-label>
|
||||
<mat-select formControlName="entitySubType">
|
||||
<mat-option *ngFor="let savingsSubType of savingsSubTypeData" [value]="savingsSubType.value">
|
||||
{{ savingsSubType.displayValue }}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<div fxFlex="14%" class="multi-row-wrapper">
|
||||
<mat-checkbox labelPosition="before" formControlName="multiRow" class="multi-row">Multi Row</mat-checkbox>
|
||||
</div>
|
||||
|
||||
@@ -13,7 +13,7 @@ import { PopoverService } from '../../../configuration-wizard/popover/popover.se
|
||||
import { ConfigurationWizardService } from '../../../configuration-wizard/configuration-wizard.service';
|
||||
|
||||
/** Data Imports */
|
||||
import { appTableData, entitySubTypeData } from '../app-table-data';
|
||||
import { appTableData, entitySubTypeData, savingsSubTypeData } from '../app-table-data';
|
||||
|
||||
/** Custom Components */
|
||||
import { ColumnDialogComponent } from '../column-dialog/column-dialog.component';
|
||||
@@ -38,7 +38,9 @@ export class CreateDataTableComponent implements OnInit, AfterViewInit {
|
||||
/** Application Table Data */
|
||||
appTableData = appTableData;
|
||||
entitySubTypeData = entitySubTypeData;
|
||||
savingsSubTypeData = savingsSubTypeData;
|
||||
showEntitySubType: boolean;
|
||||
showSavingsSubType: boolean;
|
||||
/** Column Data */
|
||||
columnData: DatatableColumn[] = [];
|
||||
/** Data passed to dialog. */
|
||||
@@ -97,6 +99,7 @@ export class CreateDataTableComponent implements OnInit, AfterViewInit {
|
||||
this.setColumns();
|
||||
this.dataTableForm.controls.apptableName.valueChanges.subscribe((value: any) => {
|
||||
this.showEntitySubType = (value === 'm_client');
|
||||
this.showSavingsSubType = (value === 'm_savings_product');
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user