Fixed Recurring Deposit views
This commit is contained in:
committed by
Adam Saghy
parent
927562a872
commit
9766644fb8
+1
-13
@@ -32,17 +32,6 @@
|
||||
|
||||
</mat-step>
|
||||
|
||||
<mat-step [stepControl]="recurringDepositAccountCurrencyForm">
|
||||
|
||||
<ng-template matStepLabel>{{"labels.inputs.CURRENCY" | translate }}</ng-template>
|
||||
|
||||
<mifosx-recurring-deposits-account-currency-step
|
||||
[recurringDepositsAccountTemplate]="recurringDepositsAccountTemplate"
|
||||
[recurringDepositsAccountProductTemplate]="recurringDepositsAccountProductTemplate">
|
||||
</mifosx-recurring-deposits-account-currency-step>
|
||||
|
||||
</mat-step>
|
||||
|
||||
<mat-step [stepControl]="recurringDepositAccountTermsForm">
|
||||
|
||||
<ng-template matStepLabel>{{"labels.inputs.TERMS" | translate }}</ng-template>
|
||||
@@ -83,8 +72,7 @@
|
||||
<mifosx-recurring-deposits-account-charges-step
|
||||
[recurringDepositsAccountTemplate]="recurringDepositsAccountTemplate"
|
||||
[recurringDepositsAccountProductTemplate]="recurringDepositsAccountProductTemplate"
|
||||
[recurringDepositAccountFormValid]="recurringDepositAccountFormValid"
|
||||
[currencyCode]="recurringDepositAccountCurrencyForm.get('currencyCode')">
|
||||
[recurringDepositAccountFormValid]="recurringDepositAccountFormValid">
|
||||
</mifosx-recurring-deposits-account-charges-step>
|
||||
|
||||
</mat-step>
|
||||
|
||||
-8
@@ -9,7 +9,6 @@ import { SettingsService } from 'app/settings/settings.service';
|
||||
/** Step Components */
|
||||
import { RecurringDepositsAccountDetailsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-details-step/recurring-deposits-account-details-step.component';
|
||||
import { RecurringDepositsAccountTermsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-terms-step/recurring-deposits-account-terms-step.component';
|
||||
import { RecurringDepositsAccountCurrencyStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-currency-step/recurring-deposits-account-currency-step.component';
|
||||
import { RecurringDepositsAccountSettingsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-settings-step/recurring-deposits-account-settings-step.component';
|
||||
import { RecurringDepositsAccountChargesStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-charges-step/recurring-deposits-account-charges-step.component';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
@@ -26,7 +25,6 @@ export class CreateRecurringDepositsAccountComponent implements OnInit {
|
||||
|
||||
/** Imports all the step component */
|
||||
@ViewChild(RecurringDepositsAccountDetailsStepComponent, { static: true }) recurringDepositsAccountDetailsStep: RecurringDepositsAccountDetailsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountCurrencyStepComponent, { static: true }) recurringDepositAccountCurrencyStep: RecurringDepositsAccountCurrencyStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountTermsStepComponent, { static: true }) recurringDepositAccountTermsStep: RecurringDepositsAccountTermsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountSettingsStepComponent, { static: true }) recurringDepositAccountSettingsStep: RecurringDepositsAccountSettingsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountChargesStepComponent, { static: true }) recurringDepositAccountChargesStep: RecurringDepositsAccountChargesStepComponent;
|
||||
@@ -63,11 +61,6 @@ export class CreateRecurringDepositsAccountComponent implements OnInit {
|
||||
return this.recurringDepositsAccountDetailsStep.recurringDepositAccountDetailsForm;
|
||||
}
|
||||
|
||||
/** Get Recurring Deposit Account Currency Form Data */
|
||||
get recurringDepositAccountCurrencyForm() {
|
||||
return this.recurringDepositAccountCurrencyStep.recurringDepositAccountCurrencyForm;
|
||||
}
|
||||
|
||||
/** Get Recurring Deposit Account Terms Form Data */
|
||||
get recurringDepositAccountTermsForm() {
|
||||
return this.recurringDepositAccountTermsStep.recurringDepositAccountTermsForm;
|
||||
@@ -91,7 +84,6 @@ export class CreateRecurringDepositsAccountComponent implements OnInit {
|
||||
get recurringDepositAccountData() {
|
||||
return {
|
||||
...this.recurringDepositsAccountDetailsStep.recurringDepositAccountDetails,
|
||||
...this.recurringDepositAccountCurrencyStep.recurringDepositAccountCurrency,
|
||||
...this.recurringDepositAccountTermsStep.recurringDepositAccountTerms,
|
||||
...this.recurringDepositAccountSettingsStep.recurringDepositAccountSettings,
|
||||
...this.recurringDepositAccountChargesStep.recurringDepositAccountCharges,
|
||||
|
||||
+1
-13
@@ -32,17 +32,6 @@
|
||||
|
||||
</mat-step>
|
||||
|
||||
<mat-step [stepControl]="recurringDepositAccountCurrencyForm">
|
||||
|
||||
<ng-template matStepLabel>{{"labels.inputs.CURRENCY" | translate }}</ng-template>
|
||||
|
||||
<mifosx-recurring-deposits-account-currency-step
|
||||
[recurringDepositsAccountTemplate]="recurringDepositsAccountAndTemplate"
|
||||
[recurringDepositsAccountProductTemplate]="recurringDepositsAccountProductTemplate">
|
||||
</mifosx-recurring-deposits-account-currency-step>
|
||||
|
||||
</mat-step>
|
||||
|
||||
<mat-step [stepControl]="recurringDepositAccountTermsForm">
|
||||
|
||||
<ng-template matStepLabel>{{"labels.inputs.TERMS" | translate }}</ng-template>
|
||||
@@ -83,8 +72,7 @@
|
||||
<mifosx-recurring-deposits-account-charges-step
|
||||
[recurringDepositsAccountTemplate]="recurringDepositsAccountAndTemplate"
|
||||
[recurringDepositsAccountProductTemplate]="recurringDepositsAccountProductTemplate"
|
||||
[recurringDepositAccountFormValid]="recurringDepositAccountFormValidAndNotPristine"
|
||||
[currencyCode]="recurringDepositAccountCurrencyForm.get('currencyCode')">
|
||||
[recurringDepositAccountFormValid]="recurringDepositAccountFormValidAndNotPristine">
|
||||
</mifosx-recurring-deposits-account-charges-step>
|
||||
|
||||
</mat-step>
|
||||
|
||||
-8
@@ -9,7 +9,6 @@ import { SettingsService } from 'app/settings/settings.service';
|
||||
/** Step Components */
|
||||
import { RecurringDepositsAccountDetailsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-details-step/recurring-deposits-account-details-step.component';
|
||||
import { RecurringDepositsAccountTermsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-terms-step/recurring-deposits-account-terms-step.component';
|
||||
import { RecurringDepositsAccountCurrencyStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-currency-step/recurring-deposits-account-currency-step.component';
|
||||
import { RecurringDepositsAccountSettingsStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-settings-step/recurring-deposits-account-settings-step.component';
|
||||
import { RecurringDepositsAccountChargesStepComponent } from '../recurring-deposits-account-stepper/recurring-deposits-account-charges-step/recurring-deposits-account-charges-step.component';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
@@ -26,7 +25,6 @@ export class EditRecurringDepositAccountComponent implements OnInit {
|
||||
|
||||
/** Imports all the step component */
|
||||
@ViewChild(RecurringDepositsAccountDetailsStepComponent, { static: true }) recurringDepositsAccountDetailsStep: RecurringDepositsAccountDetailsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountCurrencyStepComponent, { static: true }) recurringDepositAccountCurrencyStep: RecurringDepositsAccountCurrencyStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountTermsStepComponent, { static: true }) recurringDepositAccountTermsStep: RecurringDepositsAccountTermsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountSettingsStepComponent, { static: true }) recurringDepositAccountSettingsStep: RecurringDepositsAccountSettingsStepComponent;
|
||||
@ViewChild(RecurringDepositsAccountChargesStepComponent, { static: true }) recurringDepositAccountChargesStep: RecurringDepositsAccountChargesStepComponent;
|
||||
@@ -63,11 +61,6 @@ export class EditRecurringDepositAccountComponent implements OnInit {
|
||||
return this.recurringDepositsAccountDetailsStep.recurringDepositAccountDetailsForm;
|
||||
}
|
||||
|
||||
/** Get Recurring Deposit Account Currency Form Data */
|
||||
get recurringDepositAccountCurrencyForm() {
|
||||
return this.recurringDepositAccountCurrencyStep.recurringDepositAccountCurrencyForm;
|
||||
}
|
||||
|
||||
/** Get Recurring Deposit Account Terms Form Data */
|
||||
get recurringDepositAccountTermsForm() {
|
||||
return this.recurringDepositAccountTermsStep.recurringDepositAccountTermsForm;
|
||||
@@ -97,7 +90,6 @@ export class EditRecurringDepositAccountComponent implements OnInit {
|
||||
get recurringDepositAccountData() {
|
||||
return {
|
||||
...this.recurringDepositsAccountDetailsStep.recurringDepositAccountDetails,
|
||||
...this.recurringDepositAccountCurrencyStep.recurringDepositAccountCurrency,
|
||||
...this.recurringDepositAccountTermsStep.recurringDepositAccountTerms,
|
||||
...this.recurringDepositAccountSettingsStep.recurringDepositAccountSettings,
|
||||
...this.recurringDepositAccountChargesStep.recurringDepositAccountCharges,
|
||||
|
||||
+1
-2
@@ -3,8 +3,7 @@
|
||||
<mat-form-field fxFlex="48%">
|
||||
<mat-label>{{"labels.inputs.Charge" | translate }}</mat-label>
|
||||
<mat-select #charge>
|
||||
<mat-option *ngFor="let charge of chargeData | chargesFilter:chargesDataSource:currencyCode.value"
|
||||
[value]="charge">
|
||||
<mat-option *ngFor="let charge of chargeData" [value]="charge">
|
||||
{{ charge.name }}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
|
||||
+16
-9
@@ -13,6 +13,7 @@ import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-
|
||||
import { InputBase } from 'app/shared/form-dialog/formfield/model/input-base';
|
||||
import { SettingsService } from 'app/settings/settings.service';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { Charge, Currency } from 'app/shared/models/general.model';
|
||||
|
||||
/**
|
||||
* Recurring Deposit Account Charges Step
|
||||
@@ -39,6 +40,8 @@ export class RecurringDepositsAccountChargesStepComponent implements OnInit, OnC
|
||||
pristine = true;
|
||||
/** For Edit Recurring Deposits Account Form */
|
||||
isChargesPatched = false;
|
||||
/** Currency Code */
|
||||
currency: Currency | null = null;
|
||||
|
||||
constructor(public dialog: MatDialog,
|
||||
private dateUtils: Dates,
|
||||
@@ -46,19 +49,23 @@ export class RecurringDepositsAccountChargesStepComponent implements OnInit, OnC
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.currencyCode.valueChanges.subscribe(() => {
|
||||
if (!this.isChargesPatched && this.recurringDepositsAccountTemplate.charges) {
|
||||
this.chargesDataSource = this.recurringDepositsAccountTemplate.charges.map((charge: any) => ({ ...charge, id: charge.chargeId })) || [];
|
||||
this.isChargesPatched = true;
|
||||
} else {
|
||||
this.chargesDataSource = [];
|
||||
}
|
||||
});
|
||||
this.chargesDataSource = [];
|
||||
if (this.recurringDepositsAccountTemplate.id && this.recurringDepositsAccountTemplate.charges) {
|
||||
this.chargesDataSource = this.recurringDepositsAccountTemplate.charges.map((charge: any) => ({...charge, id: charge.chargeId})) || [];
|
||||
}
|
||||
}
|
||||
|
||||
ngOnChanges() {
|
||||
if (this.currency == null) {
|
||||
if (this.recurringDepositsAccountTemplate.currency) {
|
||||
this.currency = this.recurringDepositsAccountTemplate.currency;
|
||||
} else if (this.recurringDepositsAccountProductTemplate && this.recurringDepositsAccountProductTemplate.currency) {
|
||||
this.currency = this.recurringDepositsAccountProductTemplate.currency;
|
||||
}
|
||||
}
|
||||
if (this.recurringDepositsAccountProductTemplate) {
|
||||
this.chargeData = this.recurringDepositsAccountProductTemplate.chargeOptions;
|
||||
this.chargeData = this.recurringDepositsAccountProductTemplate.chargeOptions
|
||||
.filter((c: Charge) => c.currency.code === this.currency.code);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
-29
@@ -1,29 +0,0 @@
|
||||
<form [formGroup]="recurringDepositAccountCurrencyForm">
|
||||
|
||||
<div fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column">
|
||||
|
||||
<mat-form-field fxFlex="48%">
|
||||
<mat-label>{{"labels.inputs.Currency" | translate }}</mat-label>
|
||||
<input type="text" matInput formControlName="currencyCode" matTooltip="Add Currency" matTooltipPosition="above" required>
|
||||
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field fxFlex="48%">
|
||||
<mat-label>{{"labels.inputs.Decimal Places" | translate }}</mat-label>
|
||||
<input type="number" matInput formControlName="decimalPlaces" required matTooltip="Add Decimal Places" matTooltipPosition="above">
|
||||
</mat-form-field>
|
||||
|
||||
</div>
|
||||
|
||||
<div fxLayout="row" class="margin-t" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="2%">
|
||||
<button mat-raised-button matStepperPrevious>
|
||||
<fa-icon icon="arrow-left" class="m-r-10"></fa-icon>
|
||||
{{"labels.buttons.Previous" | translate }}
|
||||
</button>
|
||||
<button mat-raised-button matStepperNext>
|
||||
{{"labels.buttons.Next" | translate }}
|
||||
<fa-icon icon="arrow-right" class="m-l-10"></fa-icon>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
-25
@@ -1,25 +0,0 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { RecurringDepositsAccountCurrencyStepComponent } from './recurring-deposits-account-currency-step.component';
|
||||
|
||||
describe('RecurringDepositsAccountCurrencyStepComponent', () => {
|
||||
let component: RecurringDepositsAccountCurrencyStepComponent;
|
||||
let fixture: ComponentFixture<RecurringDepositsAccountCurrencyStepComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ RecurringDepositsAccountCurrencyStepComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(RecurringDepositsAccountCurrencyStepComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
-54
@@ -1,54 +0,0 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, Input, OnChanges } from '@angular/core';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
|
||||
|
||||
/**
|
||||
* Recurring Deposit Account Currency Step
|
||||
*/
|
||||
@Component({
|
||||
selector: 'mifosx-recurring-deposits-account-currency-step',
|
||||
templateUrl: './recurring-deposits-account-currency-step.component.html',
|
||||
styleUrls: ['./recurring-deposits-account-currency-step.component.scss']
|
||||
})
|
||||
export class RecurringDepositsAccountCurrencyStepComponent implements OnInit, OnChanges {
|
||||
|
||||
|
||||
@Input() recurringDepositsAccountTemplate: any;
|
||||
@Input() recurringDepositsAccountProductTemplate: any;
|
||||
|
||||
/** Recurring Deposit Account Currency Form */
|
||||
recurringDepositAccountCurrencyForm: UntypedFormGroup;
|
||||
/** Currency Data */
|
||||
currencyData: any;
|
||||
|
||||
constructor(private formBuilder: UntypedFormBuilder) {
|
||||
this.createRecurringDepositAccountCurrencyForm();
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
}
|
||||
|
||||
ngOnChanges() {
|
||||
if (this.recurringDepositsAccountProductTemplate) {
|
||||
this.recurringDepositAccountCurrencyForm.patchValue({
|
||||
'currencyCode': this.recurringDepositsAccountProductTemplate.currency.code,
|
||||
'decimalPlaces': this.recurringDepositsAccountProductTemplate.currency.decimalPlaces
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
createRecurringDepositAccountCurrencyForm() {
|
||||
this.recurringDepositAccountCurrencyForm = this.formBuilder.group({
|
||||
'currencyCode': [{ value: '', disabled: true }],
|
||||
'decimalPlaces': [{ value: '', disabled: true }]
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns Recurring Deposits Account Currency Form
|
||||
*/
|
||||
get recurringDepositAccountCurrency() {
|
||||
return this.recurringDepositAccountCurrencyForm.value;
|
||||
}
|
||||
|
||||
}
|
||||
+7
-2
@@ -14,7 +14,7 @@
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field fxFlex="48%" (click)="submittedOnDatePicker.open()">
|
||||
<mat-form-field fxFlex="48%" (click)="submittedOnDatePicker.open()" *ngIf="isProductSelected">
|
||||
<mat-label>{{"labels.inputs.Submitted On" | translate }}</mat-label>
|
||||
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="submittedOnDatePicker"
|
||||
formControlName="submittedOnDate" required>
|
||||
@@ -25,7 +25,7 @@
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field fxFlex="48%">
|
||||
<mat-form-field fxFlex="48%" *ngIf="isProductSelected">
|
||||
<mat-label>{{"labels.inputs.Field Officer" | translate }}</mat-label>
|
||||
<mat-select formControlName="fieldOfficerId">
|
||||
<mat-option *ngFor="let officer of fieldOfficerData" [value]="officer.id">
|
||||
@@ -34,6 +34,11 @@
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field fxFlex="48%" *ngIf="isProductSelected">
|
||||
<mat-label>{{"labels.inputs.External id" | translate}}</mat-label>
|
||||
<input matInput formControlName="externalId" matTooltip="{{ 'tooltips.Provides an external id' | translate}}">
|
||||
</mat-form-field>
|
||||
|
||||
</div>
|
||||
|
||||
<div fxLayout="row" class="margin-t" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="2%">
|
||||
|
||||
+6
-1
@@ -32,6 +32,8 @@ export class RecurringDepositsAccountDetailsStepComponent implements OnInit {
|
||||
/** Recurring Deposits Account Details Form */
|
||||
recurringDepositAccountDetailsForm: UntypedFormGroup;
|
||||
|
||||
isProductSelected = false;
|
||||
|
||||
/** Recurring Deposits Account Template with product data */
|
||||
@Output() recurringDepositsAccountProductTemplate = new EventEmitter();
|
||||
|
||||
@@ -56,6 +58,7 @@ export class RecurringDepositsAccountDetailsStepComponent implements OnInit {
|
||||
this.recurringDepositAccountDetailsForm.patchValue({
|
||||
'productId': this.recurringDepositsAccountTemplate.depositProductId,
|
||||
'submittedOnDate': this.recurringDepositsAccountTemplate.timeline.submittedOnDate && new Date(this.recurringDepositsAccountTemplate.timeline.submittedOnDate),
|
||||
'externalId': this.recurringDepositsAccountTemplate.externalId
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -68,7 +71,8 @@ export class RecurringDepositsAccountDetailsStepComponent implements OnInit {
|
||||
this.recurringDepositAccountDetailsForm = this.formBuilder.group({
|
||||
'productId': ['', Validators.required],
|
||||
'submittedOnDate': ['', Validators.required],
|
||||
'fieldOfficerId': ['']
|
||||
'fieldOfficerId': [''],
|
||||
'externalId': ['']
|
||||
});
|
||||
}
|
||||
|
||||
@@ -81,6 +85,7 @@ export class RecurringDepositsAccountDetailsStepComponent implements OnInit {
|
||||
this.recurringDepositsService.getRecurringDepositsAccountTemplate(clientId, productId).subscribe((response: any) => {
|
||||
this.recurringDepositsAccountProductTemplate.emit(response);
|
||||
this.fieldOfficerData = response.fieldOfficerOptions;
|
||||
this.isProductSelected = true;
|
||||
if (!this.isFieldOfficerPatched && this.recurringDepositsAccountTemplate.fieldOfficerId) {
|
||||
this.recurringDepositAccountDetailsForm.get('fieldOfficerId').patchValue(this.recurringDepositsAccountTemplate.fieldOfficerId);
|
||||
this.isFieldOfficerPatched = true;
|
||||
|
||||
+2
-2
@@ -77,9 +77,9 @@
|
||||
fxFlex="60%">{{ recurringDepositAccountData.lockinPeriodFrequency + ' ' + (recurringDepositAccountData.lockinPeriodFrequencyType | find:recurringDepositsAccountProductTemplate.lockinPeriodFrequencyTypeOptions:'id':'value') }}</span>
|
||||
</div>
|
||||
|
||||
<div fxFlexFill>
|
||||
<div fxFlexFill *ngIf="recurringDepositAccountData.mandatoryRecommendedDepositAmount">
|
||||
<span fxFlex="40%">{{"labels.inputs.Recurring Deposit Amount" | translate }}:</span>
|
||||
<span fxFlex="60%">{{ recurringDepositAccountData?.mandatoryRecommendedDepositAmount}}</span>
|
||||
<span fxFlex="60%">{{ recurringDepositAccountData.mandatoryRecommendedDepositAmount | formatNumber}}</span>
|
||||
</div>
|
||||
|
||||
<div fxFlexFill>
|
||||
|
||||
+5
-5
@@ -38,7 +38,7 @@
|
||||
<mat-label>{{"labels.inputs.Recurring Deposit Amount" | translate }}</mat-label>
|
||||
<input type="number" matInput formControlName="mandatoryRecommendedDepositAmount" required>
|
||||
<mat-error>
|
||||
{{"labels.inputs.Recurring Deposit Amount" | translate }} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" |translate}}</strong>
|
||||
{{"labels.inputs.Recurring Deposit Amount" | translate }} {{ "labels.commons.is" | translate }} <strong>{{ "labels.commons.required" | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<mat-label>{{"labels.inputs.Deposit Frequency" | translate }}</mat-label>
|
||||
<input type="number" matInput formControlName="recurringFrequency" required>
|
||||
<mat-error>
|
||||
{{"labels.inputs.Deposit Frequency" | translate }} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" |translate}}</strong>
|
||||
{{"labels.inputs.Deposit Frequency" | translate }} {{ "labels.commons.is" | translate }} <strong>{{ "labels.commons.required" | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
@@ -89,7 +89,7 @@
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
<mat-error>
|
||||
{{"labels.inputs.Deposit Frequency Type" | translate }} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" |translate}}</strong>
|
||||
{{"labels.inputs.Deposit Frequency Type" | translate }} {{ "labels.commons.is" | translate }} <strong>{{ "labels.commons.required" | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
</ng-container>
|
||||
@@ -103,7 +103,7 @@
|
||||
<mat-label>{{"labels.inputs.Frequency" | translate }}</mat-label>
|
||||
<input type="number" matInput formControlName="minDepositTerm" required>
|
||||
<mat-error>
|
||||
{{"labels.inputs.Minimum Deposit Term Frequency" | translate }} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" |translate}}</strong>
|
||||
{{"labels.inputs.Minimum Deposit Term Frequency" | translate }} {{ "labels.commons.is" | translate }} <strong>{{ "labels.commons.required" | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
@@ -115,7 +115,7 @@
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
<mat-error>
|
||||
{{"labels.inputs.Minimum Deposit Term Frequency Type" | translate }} {{ "labels.commons.is" |translate}} <strong>{{ "labels.commons.required" |translate}}</strong>
|
||||
{{"labels.inputs.Minimum Deposit Term Frequency Type" | translate }} {{ "labels.commons.is" | translate }} <strong>{{ "labels.commons.required" | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
|
||||
+2
@@ -61,6 +61,8 @@ export class RecurringDepositsAccountSettingsStepComponent implements OnInit, On
|
||||
'preClosurePenalInterest': this.recurringDepositsAccountProductTemplate.preClosurePenalInterest,
|
||||
'preClosurePenalInterestOnTypeId': this.recurringDepositsAccountProductTemplate.preClosurePenalInterestOnType ? this.recurringDepositsAccountProductTemplate.preClosurePenalInterestOnType.id : '',
|
||||
'minBalanceForInterestCalculation': this.recurringDepositsAccountProductTemplate.minBalanceForInterestCalculation,
|
||||
'depositPeriod': this.recurringDepositsAccountProductTemplate.minDepositTerm,
|
||||
'depositPeriodFrequencyId': this.recurringDepositsAccountProductTemplate.minDepositTermType.id
|
||||
});
|
||||
if (this.recurringDepositsAccountProductTemplate.withHoldTax) {
|
||||
this.recurringDepositAccountSettingsForm.addControl('withHoldTax', new UntypedFormControl(false));
|
||||
|
||||
+9
-1
@@ -48,7 +48,7 @@ export class RecurringDepositsAccountTermsStepComponent implements OnInit, OnCha
|
||||
|
||||
ngOnInit() {
|
||||
this.maxDate = this.settingsService.businessDate;
|
||||
if (this.recurringDepositsAccountTemplate.interestCompoundingPeriodType) {
|
||||
if (this.recurringDepositsAccountTemplate.id) {
|
||||
this.recurringDepositAccountTermsForm.patchValue({
|
||||
'interestCompoundingPeriodType': this.recurringDepositsAccountTemplate.interestCompoundingPeriodType.id,
|
||||
'interestPostingPeriodType': this.recurringDepositsAccountTemplate.interestPostingPeriodType.id,
|
||||
@@ -78,6 +78,14 @@ export class RecurringDepositsAccountTermsStepComponent implements OnInit, OnCha
|
||||
this.interestPostingPeriodTypeData = this.recurringDepositsAccountProductTemplate.interestPostingPeriodTypeOptions;
|
||||
this.interestCalculationTypeData = this.recurringDepositsAccountProductTemplate.interestCalculationTypeOptions;
|
||||
this.interestCalculationDaysInYearTypeData = this.recurringDepositsAccountProductTemplate.interestCalculationDaysInYearTypeOptions;
|
||||
if (!this.recurringDepositsAccountTemplate.id) {
|
||||
this.recurringDepositAccountTermsForm.patchValue({
|
||||
'interestCompoundingPeriodType': this.recurringDepositsAccountProductTemplate.interestCompoundingPeriodType.id,
|
||||
'interestPostingPeriodType': this.recurringDepositsAccountProductTemplate.interestPostingPeriodType.id,
|
||||
'interestCalculationType': this.recurringDepositsAccountProductTemplate.interestCalculationType.id,
|
||||
'interestCalculationDaysInYearType': this.recurringDepositsAccountProductTemplate.interestCalculationDaysInYearType.id,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+29
-2
@@ -3,9 +3,18 @@
|
||||
|
||||
<div fxFlex="49%"
|
||||
*ngIf="!recurringDepositsAccountData.status.rejected && !recurringDepositsAccountData.status.submittedAndPendingApproval">
|
||||
<h4 class="table-headers">{{"labels.heading.Account Details" | translate }}</h4>
|
||||
<h4 class="table-headers">{{"labels.inputs.Account Details" | translate }}</h4>
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.External Id" | translate }}</td>
|
||||
<td>
|
||||
<span *ngIf="recurringDepositsAccountData.externalId">
|
||||
<mifosx-external-identifier externalId="{{recurringDepositsAccountData.externalId}}" completed="true"></mifosx-external-identifier>
|
||||
</span>
|
||||
<span *ngIf="!recurringDepositsAccountData.externalId"> {{"labels.inputs.Not Available" | translate}} </span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.Field Officer" | translate }}</td>
|
||||
<td>{{recurringDepositsAccountData.fieldOfficerName}}<span
|
||||
@@ -49,6 +58,15 @@
|
||||
<h4 class="table-headers">{{"labels.heading.Performance History" | translate }}</h4>
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.External Id" | translate }}</td>
|
||||
<td>
|
||||
<span *ngIf="recurringDepositsAccountData.externalId">
|
||||
<mifosx-external-identifier externalId="{{recurringDepositsAccountData.externalId}}" completed="true"></mifosx-external-identifier>
|
||||
</span>
|
||||
<span *ngIf="!recurringDepositsAccountData.externalId"> {{"labels.inputs.Not Available" | translate}} </span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.Principal Amount" | translate }}</td>
|
||||
<td class="r-amount">
|
||||
@@ -98,6 +116,15 @@
|
||||
*ngIf="recurringDepositsAccountData.status.rejected || recurringDepositsAccountData.status.submittedAndPendingApproval">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.External Id" | translate }}</td>
|
||||
<td>
|
||||
<span *ngIf="recurringDepositsAccountData.externalId">
|
||||
<mifosx-external-identifier externalId="{{recurringDepositsAccountData.externalId}}" completed="true"></mifosx-external-identifier>
|
||||
</span>
|
||||
<span *ngIf="!recurringDepositsAccountData.externalId"> {{"labels.inputs.Not Available" | translate}} </span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{"labels.inputs.Date of Deposit" | translate }}</td>
|
||||
<td>
|
||||
@@ -128,7 +155,7 @@
|
||||
</tr>
|
||||
<tr >
|
||||
<td> {{"labels.inputs.Actual Available Balance" | translate }}</td>
|
||||
<td>{{ recurringDepositsAccountData.currency.displaySymbol }} {{ recurringDepositsAccountData.summary.accountBalance }}</td>
|
||||
<td class="r-amount">{{ recurringDepositsAccountData.summary.accountBalance | currency:currency.code:'symbol-narrow':'1.2-2'}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> {{"labels.inputs.Recurring Deposit Amount" | translate }}</td>
|
||||
|
||||
@@ -17,7 +17,6 @@ import { DatatableTabsComponent } from './recurring-deposits-account-view/datata
|
||||
import { CreateRecurringDepositsAccountComponent } from './create-recurring-deposits-account/create-recurring-deposits-account.component';
|
||||
import { RecurringDepositsAccountDetailsStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-details-step/recurring-deposits-account-details-step.component';
|
||||
import { RecurringDepositsAccountTermsStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-terms-step/recurring-deposits-account-terms-step.component';
|
||||
import { RecurringDepositsAccountCurrencyStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-currency-step/recurring-deposits-account-currency-step.component';
|
||||
import { RecurringDepositsAccountSettingsStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-settings-step/recurring-deposits-account-settings-step.component';
|
||||
import { RecurringDepositsAccountInterestRateChartStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-interest-rate-chart-step/recurring-deposits-account-interest-rate-chart-step.component';
|
||||
import { RecurringDepositsAccountChargesStepComponent } from './recurring-deposits-account-stepper/recurring-deposits-account-charges-step/recurring-deposits-account-charges-step.component';
|
||||
@@ -62,7 +61,6 @@ import { GeneralTabComponent } from './recurring-deposits-account-view/general-t
|
||||
CreateRecurringDepositsAccountComponent,
|
||||
RecurringDepositsAccountDetailsStepComponent,
|
||||
RecurringDepositsAccountTermsStepComponent,
|
||||
RecurringDepositsAccountCurrencyStepComponent,
|
||||
RecurringDepositsAccountSettingsStepComponent,
|
||||
RecurringDepositsAccountInterestRateChartStepComponent,
|
||||
RecurringDepositsAccountChargesStepComponent,
|
||||
|
||||
+1
-1
@@ -24,7 +24,7 @@
|
||||
|
||||
<mat-form-field fxFlex="48%">
|
||||
<mat-label>Currency in multiples of</mat-label>
|
||||
<input type="number" matInput formControlName="inMultiplesOf" matTooltip = "You can enter multiples of currency value. For example, if you put multiples of 100, the currency value will be rounded off to 200, 300, 400, etc." required>
|
||||
<input type="number" matInput formControlName="inMultiplesOf" matTooltip = "You can enter multiples of currency value. For example, if you put multiples of 100, the currency value will be rounded off to 200, 300, 400, etc.">
|
||||
<mat-error>
|
||||
Currency in multiples of is <strong>required</strong>
|
||||
</mat-error>
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ export class RecurringDepositProductCurrencyStepComponent implements OnInit {
|
||||
this.recurringDepositProductCurrencyForm = this.formBuilder.group({
|
||||
'currencyCode': ['', Validators.required],
|
||||
'digitsAfterDecimal': ['', Validators.required],
|
||||
'inMultiplesOf': ['', Validators.required]
|
||||
'inMultiplesOf': ['']
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -47,7 +47,7 @@
|
||||
|
||||
<mat-form-field fxFlex="65%">
|
||||
<mat-label >Description</mat-label>
|
||||
<textarea matInput formControlName="description" matTooltip="The description is used to provide additional information regarding the purpose and characteristics of the chart." required></textarea>
|
||||
<textarea matInput formControlName="description" matTooltip="The description is used to provide additional information regarding the purpose and characteristics of the chart."></textarea>
|
||||
</mat-form-field>
|
||||
|
||||
<div fxFlex="31%" fxLayout="row" fxLayoutAlign="space-between center">
|
||||
|
||||
Reference in New Issue
Block a user