assets , loan details changes : kdk
This commit is contained in:
parent
f528afd0a8
commit
43cc2b6f94
@ -64,7 +64,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--jwell details -->
|
<!--jwell details -->
|
||||||
<!--<div *ngIf="sup.get('assets_mode').value == 4">
|
<!--<div *ngIf="sup.get('assets_mode').value == 4">
|
||||||
<div fxLayout="row" fxLayoutGap="2px" fxLayoutAlign="start none">
|
<div fxLayout="row" fxLayoutGap="2px" fxLayoutAlign="start none">
|
||||||
<div *ngFor="let detail of sup['controls'].details['controls']; let s = index">
|
<div *ngFor="let detail of sup['controls'].details['controls']; let s = index">
|
||||||
<div [formGroupName]="s">
|
<div [formGroupName]="s">
|
||||||
@ -214,7 +214,7 @@
|
|||||||
<mat-option value="no">No</mat-option>
|
<mat-option value="no">No</mat-option>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="sup.get('emi').value === 'yes'" fxFlex="33">
|
<div *ngIf="sup.get('emi').value === 'yes'" fxFlex="33">
|
||||||
<mat-form-field class="ml-xs example-full-width">
|
<mat-form-field class="ml-xs example-full-width">
|
||||||
<input matInput placeholder="EMI Paid" formControlName="emi_paid">
|
<input matInput placeholder="EMI Paid" formControlName="emi_paid">
|
||||||
@ -245,14 +245,14 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--<div fxLayout="row">
|
<div fxLayout="row">
|
||||||
<div fxFlex="60" class="pb-0 text-sm-left">
|
<div fxFlex="60" class="pb-0 text-sm-left">
|
||||||
<mat-form-field appearance="outline" style="width: 100%">
|
<mat-form-field appearance="outline" style="width: 100%">
|
||||||
<mat-label>Remarks</mat-label>
|
<mat-label>Remarks</mat-label>
|
||||||
<textarea matInput placeholder="Remarks" formControlName="assets_form_remark"></textarea>
|
<textarea matInput placeholder="Remarks" formControlName="assets_form_remark"></textarea>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>-->
|
|
||||||
<div class="row" style="text-align:right;">
|
<div class="row" style="text-align:right;">
|
||||||
<button mat-raised-button mat-icon-button mat-button color="primary" matTooltip="Add More Asset Details" matTooltipPosition="above"
|
<button mat-raised-button mat-icon-button mat-button color="primary" matTooltip="Add More Asset Details" matTooltipPosition="above"
|
||||||
class="mr-1 mb-1 hover-icon" (click)="addSupplierDetails($event); false"><mat-icon>add</mat-icon></button>
|
class="mr-1 mb-1 hover-icon" (click)="addSupplierDetails($event); false"><mat-icon>add</mat-icon></button>
|
||||||
|
|||||||
@ -269,7 +269,7 @@ public m_investmentType = [];
|
|||||||
assets_details: this._formBuilder.array([
|
assets_details: this._formBuilder.array([
|
||||||
// this.initDetails(),
|
// this.initDetails(),
|
||||||
]),
|
]),
|
||||||
// assets_form_remark:[value.assets_form_remark || 'check']
|
assets_form_remark:[value.assets_form_remark || 'check']
|
||||||
});
|
});
|
||||||
this.addAssetsDetailsWithData(value.assets_details);
|
this.addAssetsDetailsWithData(value.assets_details);
|
||||||
} else {
|
} else {
|
||||||
@ -279,7 +279,7 @@ public m_investmentType = [];
|
|||||||
assets_details: this._formBuilder.array([
|
assets_details: this._formBuilder.array([
|
||||||
this.initDetails(),
|
this.initDetails(),
|
||||||
]),
|
]),
|
||||||
// assets_form_remark:['']
|
assets_form_remark:['']
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
this.loadDetails = true;
|
this.loadDetails = true;
|
||||||
|
|||||||
@ -196,10 +196,10 @@ getM_sourceofamount() {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
ownerNameChange(event) {
|
ownerNameChange(event) {
|
||||||
this.ownerNames = [];
|
// this.ownerNames = [];
|
||||||
event.value.forEach(option => {
|
// event.value.forEach(option => {
|
||||||
this.ownerNames.push({owner_name: option});
|
// this.ownerNames.push({owner_name: option});
|
||||||
});
|
// });
|
||||||
}
|
}
|
||||||
submitLoanDetails() {
|
submitLoanDetails() {
|
||||||
console.log('formData', this.loanDetailsForm.value);
|
console.log('formData', this.loanDetailsForm.value);
|
||||||
@ -211,7 +211,14 @@ getM_sourceofamount() {
|
|||||||
records.formid = this.form_id;
|
records.formid = this.form_id;
|
||||||
records.fk_createdby = this.pdid;
|
records.fk_createdby = this.pdid;
|
||||||
records.loan_amount = this.loanDetailsForm.controls['loan_amount'].value;
|
records.loan_amount = this.loanDetailsForm.controls['loan_amount'].value;
|
||||||
records.end_use_group = this.endUserList;
|
|
||||||
|
// get end user final group data
|
||||||
|
let dataEnd_user_data = [];
|
||||||
|
this.loanDetailsForm.controls['end_use'].value.forEach(element => {
|
||||||
|
dataEnd_user_data.push({end_use: element})
|
||||||
|
});
|
||||||
|
records.end_use_group = dataEnd_user_data;
|
||||||
|
|
||||||
if (this.isOtherPurpose) {
|
if (this.isOtherPurpose) {
|
||||||
records.end_use_other = this.loanDetailsForm.controls['end_use_other'].value;
|
records.end_use_other = this.loanDetailsForm.controls['end_use_other'].value;
|
||||||
}
|
}
|
||||||
@ -233,7 +240,13 @@ getM_sourceofamount() {
|
|||||||
}
|
}
|
||||||
records.emi_level = this.loanDetailsForm.controls['emi_level'].value;
|
records.emi_level = this.loanDetailsForm.controls['emi_level'].value;
|
||||||
records.property_type = this.loanDetailsForm.controls['property_type'].value;
|
records.property_type = this.loanDetailsForm.controls['property_type'].value;
|
||||||
records.owner_name_group = this.ownerNames;
|
// records.owner_name_group = this.ownerNames;
|
||||||
|
// console.log(this.loanDetailsForm.controls['owner_name'].value);
|
||||||
|
let dataOwner_name = [];
|
||||||
|
this.loanDetailsForm.controls['owner_name'].value.forEach(element => {
|
||||||
|
dataOwner_name.push({owner_name: element})
|
||||||
|
});
|
||||||
|
records.owner_name_group = dataOwner_name;
|
||||||
records.construction_status = this.loanDetailsForm.controls['construction_status'].value;
|
records.construction_status = this.loanDetailsForm.controls['construction_status'].value;
|
||||||
records.emv_per_customer = this.loanDetailsForm.controls['emv_per_customer'].value;
|
records.emv_per_customer = this.loanDetailsForm.controls['emv_per_customer'].value;
|
||||||
records.value_per_agreement = this.loanDetailsForm.controls['value_per_agreement'].value;
|
records.value_per_agreement = this.loanDetailsForm.controls['value_per_agreement'].value;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user