loan details live issue fix
This commit is contained in:
parent
20ec4ef299
commit
6934631256
@ -548,9 +548,12 @@ export class LoanDetailsComponent implements OnInit {
|
||||
event.forEach(option => {
|
||||
// let othersData = this.m_endUseofLoad.filter(sub=>sub.subproduct_id==option)[0];
|
||||
let othersData = this.m_endUseForLoan.filter(sub => sub.enduse_of_loan_id == option)[0];
|
||||
|
||||
OthersAvaliable = othersData.enduse_of_loan.substr(0, 6).toLowerCase();
|
||||
|
||||
console.log('other data',othersData);
|
||||
if(othersData != undefined){
|
||||
OthersAvaliable = othersData.enduse_of_loan.substr(0, 6).toLowerCase();
|
||||
}
|
||||
|
||||
|
||||
this.endUserList.push({ end_use: option });
|
||||
});
|
||||
|
||||
@ -690,20 +693,23 @@ export class LoanDetailsComponent implements OnInit {
|
||||
mortage_type(mortage_value)
|
||||
{
|
||||
let mortagetypes = this.m_mortageTypeProperty.filter(mor => mor.mortage_property_id == mortage_value)[0];
|
||||
let property_name = mortagetypes.property_name.replace(/\s/g, "").toLowerCase();
|
||||
if(property_name=='others')
|
||||
{
|
||||
this.mortageAccess = true;
|
||||
this.loanDetailsForm.controls['property_type_others'].setValidators([Validators.required]);
|
||||
this.loanDetailsForm.controls['property_type_others'].updateValueAndValidity();
|
||||
}else
|
||||
{
|
||||
this.mortageAccess = false;
|
||||
this.loanDetailsForm.controls['property_type_others'].setValue('');
|
||||
this.loanDetailsForm.controls['property_type_others'].clearValidators();
|
||||
this.loanDetailsForm.controls['property_type_others'].updateValueAndValidity();
|
||||
}
|
||||
|
||||
console.log('mortagettypes',mortagetypes);
|
||||
if(mortagetypes != undefined){
|
||||
let property_name = mortagetypes.property_name.replace(/\s/g, "").toLowerCase();
|
||||
if(property_name=='others')
|
||||
{
|
||||
this.mortageAccess = true;
|
||||
this.loanDetailsForm.controls['property_type_others'].setValidators([Validators.required]);
|
||||
this.loanDetailsForm.controls['property_type_others'].updateValueAndValidity();
|
||||
}else
|
||||
{
|
||||
this.mortageAccess = false;
|
||||
this.loanDetailsForm.controls['property_type_others'].setValue('');
|
||||
this.loanDetailsForm.controls['property_type_others'].clearValidators();
|
||||
this.loanDetailsForm.controls['property_type_others'].updateValueAndValidity();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user