Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FINERACT-1971: Multiples of currency and installment amount is not mandatory #1868

Merged
merged 1 commit into from
Sep 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,12 @@

<mat-form-field fxFlex="48%">
<mat-label>Currency in multiples of</mat-label>
<input type="number" matInput 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." formControlName="inMultiplesOf" required>
<mat-error>
Currency in multiples of is <strong>required</strong>
</mat-error>
<input type="number" matInput 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." formControlName="inMultiplesOf">
</mat-form-field>

<mat-form-field fxFlex="48%">
<mat-label>Installment in multiples of</mat-label>
<input type="number" matInput formControlName="installmentAmountInMultiplesOf" required>
<mat-error>
Installment in multiples of is <strong>required</strong>
</mat-error>
<input type="number" matInput formControlName="installmentAmountInMultiplesOf">
</mat-form-field>

</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,15 @@ export class LoanProductCurrencyStepComponent implements OnInit {
this.loanProductCurrencyForm.patchValue({
'currencyCode': this.loanProductsTemplate.currency.code || this.currencyData[0].code,
'digitsAfterDecimal': this.loanProductsTemplate.currency.decimalPlaces ? this.loanProductsTemplate.currency.decimalPlaces : 2,
'inMultiplesOf': this.loanProductsTemplate.currency.inMultiplesOf ? this.loanProductsTemplate.currency.inMultiplesOf : 1,
'installmentAmountInMultiplesOf': this.loanProductsTemplate.installmentAmountInMultiplesOf ? this.loanProductsTemplate.installmentAmountInMultiplesOf : 1
'inMultiplesOf': this.loanProductsTemplate.currency.inMultiplesOf,
'installmentAmountInMultiplesOf': this.loanProductsTemplate.installmentAmountInMultiplesOf
});
}

createLoanProductCurrencyForm() {
this.loanProductCurrencyForm = this.formBuilder.group({
'currencyCode': ['', Validators.required],
'digitsAfterDecimal': [2, Validators.required],
'inMultiplesOf': [1, Validators.required],
'installmentAmountInMultiplesOf': [1, Validators.required]
'digitsAfterDecimal': [2, Validators.required]
});
}

Expand Down