Clients search enhancement (#1605)
Co-authored-by: Jose Alberto Hernandez <alberto@MacBook-Pro.local>
This commit is contained in:
co-authored by
Jose Alberto Hernandez
parent
475059a974
commit
d0dc2aabb2
@@ -26,7 +26,7 @@
|
||||
<ng-template matStepLabel>DETAILS</ng-template>
|
||||
|
||||
<mifosx-loans-account-details-step [loansAccountTemplate]="loansAccountTemplate"
|
||||
(loansAccountProductTemplate)="setTemplate($event)">
|
||||
(loansAccountProductTemplate)="setTemplate($event)" #loansAccountDetailsForm>
|
||||
</mifosx-loans-account-details-step>
|
||||
|
||||
</mat-step>
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
<ng-template matStepLabel>TERMS</ng-template>
|
||||
|
||||
<mifosx-loans-account-terms-step [loansAccountProductTemplate]="loansAccountProductTemplate"
|
||||
<mifosx-loans-account-terms-step #loanAccountTerms [loansAccountProductTemplate]="loansAccountProductTemplate"
|
||||
[loansAccountTemplate] = "loansAccountTemplate" [collateralOptions]="collateralOptions"
|
||||
[loansAccountFormValid]="loansAccountFormValid" [loanPrincipal]="loanPrincipal">
|
||||
</mifosx-loans-account-terms-step>
|
||||
@@ -46,7 +46,7 @@
|
||||
|
||||
<ng-template matStepLabel>CHARGES</ng-template>
|
||||
|
||||
<mifosx-loans-account-charges-step [loansAccountProductTemplate]="loansAccountProductTemplate"
|
||||
<mifosx-loans-account-charges-step #loanAccountCharges [loansAccountProductTemplate]="loansAccountProductTemplate"
|
||||
[loansAccountTemplate]="loansAccountTemplate"
|
||||
[loansAccountFormValid]="loansAccountFormValid">
|
||||
</mifosx-loans-account-charges-step>
|
||||
@@ -57,7 +57,7 @@
|
||||
|
||||
<ng-template matStepLabel>REPAYMENT SCHEDULE</ng-template>
|
||||
|
||||
<mifosx-loans-account-schedule-step [loansAccountTemplate]="loansAccountTemplate"
|
||||
<mifosx-loans-account-schedule-step #loanAccountSchedule [loansAccountTemplate]="loansAccountTemplate"
|
||||
[loansAccountProductTemplate]="loansAccountProductTemplate" [loansAccount]="loansAccount">
|
||||
</mifosx-loans-account-schedule-step>
|
||||
|
||||
|
||||
+2
-2
@@ -56,10 +56,10 @@ export class LoansAccountDetailsStepComponent implements OnInit {
|
||||
private route: ActivatedRoute,
|
||||
private settingsService: SettingsService) {
|
||||
this.loanId = this.route.snapshot.params['loanId'];
|
||||
this.createLoansAccountDetailsForm();
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.createLoansAccountDetailsForm();
|
||||
this.maxDate = this.settingsService.maxFutureDate;
|
||||
this.buildDependencies();
|
||||
if (this.loansAccountTemplate) {
|
||||
@@ -87,7 +87,7 @@ export class LoansAccountDetailsStepComponent implements OnInit {
|
||||
'loanOfficerId': [''],
|
||||
'loanPurposeId': [''],
|
||||
'fundId': [''],
|
||||
'submittedOnDate': [new Date(), Validators.required],
|
||||
'submittedOnDate': [this.settingsService.businessDate, Validators.required],
|
||||
'expectedDisbursementDate': ['', Validators.required],
|
||||
'externalId': [''],
|
||||
'linkAccountId': [''],
|
||||
|
||||
+34
@@ -19,6 +19,40 @@
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<div fxLayout="row wrap" class="content">
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Principal' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.principalPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Interest' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.interestPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Fees' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.feeChargesPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Penalties' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.penaltyChargesPortion | number }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Transaction Amount</mat-label>
|
||||
<input type="number" matInput required formControlName="transactionAmount">
|
||||
|
||||
+34
-13
@@ -19,6 +19,40 @@
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<div fxLayout="row wrap" class="content">
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Principal' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.principalPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Interest' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.interestPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Fees' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.feeChargesPortion | number }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="mat-body-strong">
|
||||
{{ 'Penalties' | translate }}
|
||||
</div>
|
||||
|
||||
<div fxFlex="50%" class="r-amount">
|
||||
{{ dataObject.penaltyChargesPortion | number }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Transaction Amount</mat-label>
|
||||
<input type="number" matInput required formControlName="transactionAmount">
|
||||
@@ -27,19 +61,6 @@
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Principal</mat-label>
|
||||
<input matInput formControlName="principal">
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Interest Amount</mat-label>
|
||||
<input matInput required formControlName="interestAmount">
|
||||
<mat-error *ngIf="prepayLoanForm.controls.interestAmount.hasError('required')">
|
||||
Interest Amount <strong>is required</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>External Id</mat-label>
|
||||
<input matInput formControlName="externalId">
|
||||
|
||||
@@ -70,8 +70,6 @@ export class PrepayLoanComponent implements OnInit {
|
||||
this.prepayLoanForm = this.formBuilder.group({
|
||||
'transactionDate': [new Date(), Validators.required],
|
||||
'transactionAmount': ['', Validators.required],
|
||||
'principal': [{value: '', disabled: true}],
|
||||
'interestAmount': [{value: '', disabled: true}, Validators.required],
|
||||
'externalId': [''],
|
||||
'paymentTypeId': [''],
|
||||
'note': ['']
|
||||
@@ -84,9 +82,7 @@ export class PrepayLoanComponent implements OnInit {
|
||||
setPrepayLoanDetails() {
|
||||
this.paymentTypes = this.dataObject.paymentTypeOptions;
|
||||
this.prepayLoanForm.patchValue({
|
||||
transactionAmount: this.dataObject.amount,
|
||||
principal: this.dataObject.principalPortion,
|
||||
interestAmount: this.dataObject.interestPortion,
|
||||
transactionAmount: this.dataObject.amount
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -50,6 +50,8 @@
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<span fxFlex="auto"></span>
|
||||
|
||||
<div fxFlex="4%">
|
||||
<button mat-icon-button [matMenuTriggerFor]="accountMenu" aria-label="Loan account actions"
|
||||
yPosition="below">
|
||||
|
||||
@@ -23,7 +23,7 @@ export class RepaymentScheduleTabComponent implements OnInit {
|
||||
*/
|
||||
constructor(private route: ActivatedRoute) {
|
||||
this.route.parent.data.subscribe((data: { loanDetailsData: any }) => {
|
||||
this.loanDetailsDataRepaymentSchedule = data.loanDetailsData.repaymentSchedule;
|
||||
this.loanDetailsDataRepaymentSchedule = data.loanDetailsData ? data.loanDetailsData.repaymentSchedule : [];
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user