Display the input for Installment amount when It can be defined (#1612)

Co-authored-by: Jose Alberto Hernandez <alberto@MacBook-Pro.local>
This commit is contained in:
José Alberto Hernández
2023-01-01 23:26:38 -06:00
committed by GitHub
co-authored by Jose Alberto Hernandez
parent 5275657752
commit 68a0c0d6a1
@@ -112,13 +112,13 @@
</mat-form-field> </mat-form-field>
<mat-checkbox fxFlex="48%" formControlName="isEqualAmortization" <mat-checkbox fxFlex="48%" formControlName="isEqualAmortization"
[checked]="loansAccountTemplate?.isEqualAmortization"> [checked]="loansAccountTermsData?.isEqualAmortization">
<p>Is Equal Amortization</p> <p>Is Equal Amortization</p>
</mat-checkbox> </mat-checkbox>
</ng-container> </ng-container>
<ng-container *ngIf="loansAccountTemplate?.isLoanProductLinkedToFloatingRate"> <ng-container *ngIf="loansAccountTermsData?.isLoanProductLinkedToFloatingRate">
<div fxFlex="48%" fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column"> <div fxFlex="48%" fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column">
@@ -206,12 +206,12 @@
<input type="number" matInput formControlName="graceOnArrearsAgeing"> <input type="number" matInput formControlName="graceOnArrearsAgeing">
</mat-form-field> </mat-form-field>
<mat-form-field fxFlex="48%" *ngIf="loansAccountTemplate?.canDefineInstallmentAmount"> <mat-form-field fxFlex="48%" *ngIf="loansAccountTermsData?.canDefineInstallmentAmount">
<mat-label>Installment Amount</mat-label> <mat-label>Installment Amount</mat-label>
<input type="number" matInput formControlName="fixedEmiAmount"> <input type="number" matInput formControlName="fixedEmiAmount">
</mat-form-field> </mat-form-field>
<ng-container *ngIf="loansAccountTemplate?.canUseForTopup"> <ng-container *ngIf="loansAccountTermsData?.canUseForTopup">
<mat-checkbox fxFlex="48%" formControlName="isTopup"> <mat-checkbox fxFlex="48%" formControlName="isTopup">
<p>Is Topup Loan?</p> <p>Is Topup Loan?</p>
@@ -232,60 +232,60 @@
<div fxFlexFill> <div fxFlexFill>
<span fxFlex="40%">Recalculate Interest</span> <span fxFlex="40%">Recalculate Interest</span>
<span fxFlex="60%">{{ loansAccountTemplate?.isInterestRecalculationEnabled? 'Yes' : 'No' }}</span> <span fxFlex="60%">{{ loansAccountTermsData?.isInterestRecalculationEnabled? 'Yes' : 'No' }}</span>
</div> </div>
<div fxFlexFill *ngIf="loansAccountTemplate?.isInterestRecalculationEnabled"> <div fxFlexFill *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled">
<span fxFlex="40%">Days in year</span> <span fxFlex="40%">Days in year</span>
<span fxFlex="60%">{{ loansAccountTemplate?.daysInYearType.value}}</span> <span fxFlex="60%">{{ loansAccountTermsData.daysInYearType.value}}</span>
</div> </div>
<ng-container *ngIf="loansAccountTemplate?.isInterestRecalculationEnabled"> <ng-container *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled">
<div fxFlexFill *ngIf="loansAccountTemplate?.isInterestRecalculationEnabled"> <div fxFlexFill *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled">
<span fxFlex="40%">Advance payments adjustment type</span> <span fxFlex="40%">Advance payments adjustment type</span>
<span fxFlex="60%">{{ loansAccountTemplate?.interestRecalculationData.rescheduleStrategyType.value }}</span> <span fxFlex="60%">{{ loansAccountTermsData.interestRecalculationData.rescheduleStrategyType.value }}</span>
</div> </div>
<div fxFlexFill *ngIf="loansAccountTemplate?.isInterestRecalculationEnabled"> <div fxFlexFill *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled">
<span fxFlex="40%">Days in month</span> <span fxFlex="40%">Days in month</span>
<span fxFlex="60%">{{ loansAccountTemplate?.daysInMonthType.value }}</span> <span fxFlex="60%">{{ loansAccountTermsData.daysInMonthType.value }}</span>
</div> </div>
</ng-container> </ng-container>
<ng-container *ngIf="loansAccountTemplate?.isInterestRecalculationEnabled"> <ng-container *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled">
<div fxFlexFill> <div fxFlexFill>
<span fxFlex="40%">Interest recalculation compounding on</span> <span fxFlex="40%">Interest recalculation compounding on</span>
<span fxFlex="60%">{{ loansAccountTemplate?.interestRecalculationData.interestRecalculationCompoundingType.value <span fxFlex="60%">{{ loansAccountTermsData.interestRecalculationData.interestRecalculationCompoundingType.value
}}</span> }}</span>
</div> </div>
<div fxFlexFill> <div fxFlexFill>
<span fxFlex="40%">Frequency Interval for recalculation</span> <span fxFlex="40%">Frequency Interval for recalculation</span>
<span fxFlex="60%"> <span fxFlex="60%">
<span>{{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyType.value}}</span> <span>{{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyType.value}}</span>
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyType.id == 3 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyType.id == 3 &&
loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyWeekday != null"> loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyWeekday != null">
on {{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyWeekday.value}}</span> on {{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyWeekday.value}}</span>
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyType.id == 4 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyType.id == 4 &&
loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyOnDay != null">on day loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyOnDay != null">on day
{{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyOnDay}}</span> {{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyOnDay}}</span>
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyType.id == 4 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyType.id == 4 &&
loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyOnDay == null && loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyOnDay == null &&
loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyNthDay != null">on loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyNthDay != null">on
{{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyNthDay.value}} {{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyNthDay.value}}
{{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyWeekday.value}}</span> {{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyWeekday.value}}</span>
</span> </span>
</div> </div>
</ng-container> </ng-container>
<div fxFlexFill <div fxFlexFill
*ngIf="loansAccountTemplate?.isInterestRecalculationEnabled && loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyType.id != 1"> *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled && loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyType.id != 1">
<span fxFlex="40%">Frequency Interval for recalculation</span> <span fxFlex="40%">Frequency Interval for recalculation</span>
<span fxFlex="60%">{{ loansAccountTemplate?.interestRecalculationData.recalculationRestFrequencyInterval}}</span> <span fxFlex="60%">{{ loansAccountTermsData.interestRecalculationData.recalculationRestFrequencyInterval}}</span>
</div> </div>
<ng-container *ngIf="multiDisburseLoan"> <ng-container *ngIf="multiDisburseLoan">
@@ -338,35 +338,35 @@
</ng-container> </ng-container>
<ng-container <ng-container
*ngIf="loansAccountTemplate?.isInterestRecalculationEnabled && loansAccountTemplate?.interestRecalculationData.interestRecalculationCompoundingType.id != 0"> *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled && loansAccountTermsData.interestRecalculationData.interestRecalculationCompoundingType.id != 0">
<div fxFlexFill> <div fxFlexFill>
<span fxFlex="40%">Frequency for compounding</span> <span fxFlex="40%">Frequency for compounding</span>
<span fxFlex="60%">{{ <span fxFlex="60%">{{
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyType.value}} loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyType.value}}
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyType.id == 3 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyType.id == 3 &&
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyWeekday != null"> loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyWeekday != null">
on {{ loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyWeekday.value}} on {{ loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyWeekday.value}}
</span> </span>
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyType.id == 4 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyType.id == 4 &&
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyOnDay != null">on day loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyOnDay != null">on day
{{ loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyOnDay}} {{ loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyOnDay}}
</span> </span>
<span *ngIf="loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyType.id == 4 && <span *ngIf="loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyType.id == 4 &&
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyOnDay == null && loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyOnDay == null &&
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyNthDay != null">on loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyNthDay != null">on
{{ loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyNthDay.value}} {{ loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyNthDay.value}}
{{ loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyWeekday.value}} {{ loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyWeekday.value}}
</span> </span>
</span> </span>
</div> </div>
</ng-container> </ng-container>
<div fxFlexFill <div fxFlexFill
*ngIf="loansAccountTemplate?.isInterestRecalculationEnabled && loansAccountTemplate?.interestRecalculationData.interestRecalculationCompoundingType.id != 0 && loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyType.id != 1"> *ngIf="loansAccountTermsData?.isInterestRecalculationEnabled && loansAccountTermsData.interestRecalculationData.interestRecalculationCompoundingType.id != 0 && loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyType.id != 1">
<span fxFlex="40%">Frequency Interval for compounding</span> <span fxFlex="40%">Frequency Interval for compounding</span>
<span fxFlex="60%">{{ <span fxFlex="60%">{{
loansAccountTemplate?.interestRecalculationData.recalculationCompoundingFrequencyInterval}}</span> loansAccountTermsData.interestRecalculationData.recalculationCompoundingFrequencyInterval}}</span>
</div> </div>
<mat-divider fxFlex="98%"></mat-divider> <mat-divider fxFlex="98%"></mat-divider>