Merge branch 'master' of https://bitbucket.org/sriramv18/sparqsineedge
This commit is contained in:
commit
e82469ad06
@ -102,6 +102,11 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
|||||||
console.log(selectLender);
|
console.log(selectLender);
|
||||||
this.selectedLender(selectLender)
|
this.selectedLender(selectLender)
|
||||||
|
|
||||||
|
this._PDtriggerForm.controls['fk_product_id'].setValue(res['records'].default_product);
|
||||||
|
this._PDtriggerForm.controls['fk_customer_segment'].setValue(res['records'].default_customer_segment);
|
||||||
|
this._PDtriggerForm.controls['fk_pd_type'].setValue(res['records'].default_pd_type);
|
||||||
|
this.getSubproductList(res['records'].default_product)
|
||||||
|
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
this.notifier.notify("success","Something went wrong Reopen the window and Try again");
|
this.notifier.notify("success","Something went wrong Reopen the window and Try again");
|
||||||
@ -185,12 +190,20 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
|||||||
this._PDtriggerForm.controls['fk_customer_segment'].setValue('');
|
this._PDtriggerForm.controls['fk_customer_segment'].setValue('');
|
||||||
this._PDtriggerForm.controls['loan_amount'].setValue('');
|
this._PDtriggerForm.controls['loan_amount'].setValue('');
|
||||||
|
|
||||||
if(this.lenderShortName == "IIB"){ //FOR INDUSLAND BANK
|
// if(this.lenderShortName == "IIB"){ //FOR INDUSLAND BANK
|
||||||
// console.log("entered");
|
// // console.log("entered");
|
||||||
this._PDtriggerForm.controls['fk_product_id'].setValue("3")
|
// this._PDtriggerForm.controls['fk_product_id'].setValue("3")
|
||||||
this._PDtriggerForm.controls['fk_pd_type'].setValue("1");
|
// this._PDtriggerForm.controls['fk_pd_type'].setValue("1");
|
||||||
this.getSubproductList("3")
|
// this.getSubproductList("3")
|
||||||
}
|
// }
|
||||||
|
// else if(this.lenderShortName == 'HHFL'){
|
||||||
|
// this.getSubproductList("1")
|
||||||
|
// this._PDtriggerForm.controls['fk_product_id'].setValue('1');
|
||||||
|
// this._PDtriggerForm.controls['fk_subproduct_id'].setValue('1');
|
||||||
|
// this._PDtriggerForm.controls['fk_customer_segment'].setValue('5');
|
||||||
|
// this._PDtriggerForm.controls['fk_pd_type'].setValue('1');
|
||||||
|
// this._PDtriggerForm.controls['loan_amount'].setValue(0);
|
||||||
|
// }
|
||||||
// console.log("len",lender)
|
// console.log("len",lender)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -252,8 +265,9 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
|||||||
// console.log(productID)
|
// console.log(productID)
|
||||||
let productabbr : any;
|
let productabbr : any;
|
||||||
// console.log('productID',productID);
|
// console.log('productID',productID);
|
||||||
if(productID !== undefined && productID !== null && productID !== '') {
|
if(productID !== undefined && productID !== null && productID !== '' && this.productList.length > 0) {
|
||||||
this.subProductList = this.productList.filter(item => item.product_id == productID);
|
this.subProductList = this.productList.filter(item => item.product_id == productID);
|
||||||
|
console.log('sub products',this.subProductList,this.productList,productID)
|
||||||
this.subProductList = this.subProductList[0].subproducts;
|
this.subProductList = this.subProductList[0].subproducts;
|
||||||
this.subProductList = this.subProductList.filter(item => item.is_others == 0);
|
this.subProductList = this.subProductList.filter(item => item.is_others == 0);
|
||||||
productabbr = this.productAllList.filter(item => item.product_id == productID)[0].product_abbr;
|
productabbr = this.productAllList.filter(item => item.product_id == productID)[0].product_abbr;
|
||||||
@ -289,11 +303,11 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.lenderShortName == 'CLIX' && productabbr != ''){
|
// if(this.lenderShortName == 'CLIX' && productabbr != ''){
|
||||||
this._PDtriggerForm.controls['fk_pd_type'].setValue('1');
|
// this._PDtriggerForm.controls['fk_pd_type'].setValue('1');
|
||||||
this._PDtriggerForm.controls['fk_customer_segment'].setValue('5');
|
// this._PDtriggerForm.controls['fk_customer_segment'].setValue('5');
|
||||||
this._PDtriggerForm.controls['loan_amount'].setValue(0);
|
// this._PDtriggerForm.controls['loan_amount'].setValue(0);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -73,6 +73,7 @@ export class AddressComponent implements OnInit {
|
|||||||
pincodeDataList: any = [];
|
pincodeDataList: any = [];
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
split_customer_abbr: any;
|
split_customer_abbr: any;
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
/**Constructor of the class */
|
/**Constructor of the class */
|
||||||
constructor(private el: ElementRef, notifier: NotifierService,
|
constructor(private el: ElementRef, notifier: NotifierService,
|
||||||
@ -95,7 +96,8 @@ export class AddressComponent implements OnInit {
|
|||||||
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
||||||
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
console.log(this.product_abbr);
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
|
console.log('prod catagory',this.prod_catagory);
|
||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.split_customer_abbr = this.customer_segment_abbr.split('-')
|
this.split_customer_abbr = this.customer_segment_abbr.split('-')
|
||||||
if(this.split_customer_abbr.length > 0){
|
if(this.split_customer_abbr.length > 0){
|
||||||
@ -194,7 +196,7 @@ export class AddressComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.lender_short_name != 'CLIX' && this.product_abbr != 'BL') {
|
if(this.lender_short_name != 'CLIX' && this.prod_catagory != 'BL') {
|
||||||
this.addressForm.controls.estimated_area.setValue(datas.estimated_area ? datas.estimated_area : '')
|
this.addressForm.controls.estimated_area.setValue(datas.estimated_area ? datas.estimated_area : '')
|
||||||
|
|
||||||
this.addressForm.controls.uom.setValue(datas.uom);
|
this.addressForm.controls.uom.setValue(datas.uom);
|
||||||
@ -237,7 +239,7 @@ export class AddressComponent implements OnInit {
|
|||||||
// was_the_company_name_board_sighted:['', Validators.compose([Validators.required])],
|
// was_the_company_name_board_sighted:['', Validators.compose([Validators.required])],
|
||||||
address_form_remark: ['']
|
address_form_remark: ['']
|
||||||
});
|
});
|
||||||
if(this.lender_short_name == 'CLIX' || this.product_abbr == 'BL'){
|
if(this.lender_short_name == 'CLIX' || this.prod_catagory == 'BL'){
|
||||||
this.addressForm.removeControl('estimated_area');
|
this.addressForm.removeControl('estimated_area');
|
||||||
this.addressForm.removeControl('uom');
|
this.addressForm.removeControl('uom');
|
||||||
}
|
}
|
||||||
@ -552,7 +554,7 @@ export class AddressComponent implements OnInit {
|
|||||||
records.addresses[0].locality_mixuse = this.addressForm.controls.locality_mixuse.value;
|
records.addresses[0].locality_mixuse = this.addressForm.controls.locality_mixuse.value;
|
||||||
records.addresses[0].pd_location = this.addressForm.controls.pd_location.value;
|
records.addresses[0].pd_location = this.addressForm.controls.pd_location.value;
|
||||||
records.addresses[0].comment_locality = this.addressForm.controls.comment_locality.value;
|
records.addresses[0].comment_locality = this.addressForm.controls.comment_locality.value;
|
||||||
if(this.lender_short_name != 'CLIX' && this.product_abbr != 'BL') {
|
if(this.lender_short_name != 'CLIX' && this.prod_catagory != 'BL') {
|
||||||
records.addresses[0].estimated_area = this.addressForm.controls.estimated_area.value
|
records.addresses[0].estimated_area = this.addressForm.controls.estimated_area.value
|
||||||
records.addresses[0].uom = this.addressForm.controls.uom.value;
|
records.addresses[0].uom = this.addressForm.controls.uom.value;
|
||||||
if (this.addressForm.controls.uom.value == 1) {
|
if (this.addressForm.controls.uom.value == 1) {
|
||||||
@ -577,7 +579,7 @@ export class AddressComponent implements OnInit {
|
|||||||
records.alternative_addresses[0].locality_mixuse = this.addressForm.controls.locality_mixuse.value;
|
records.alternative_addresses[0].locality_mixuse = this.addressForm.controls.locality_mixuse.value;
|
||||||
records.alternative_addresses[0].pd_location = this.addressForm.controls.pd_location.value;
|
records.alternative_addresses[0].pd_location = this.addressForm.controls.pd_location.value;
|
||||||
records.alternative_addresses[0].comment_locality = this.addressForm.controls.comment_locality.value;
|
records.alternative_addresses[0].comment_locality = this.addressForm.controls.comment_locality.value;
|
||||||
if(this.lender_short_name != 'CLIX' && this.product_abbr != 'BL') {
|
if(this.lender_short_name != 'CLIX' && this.prod_catagory != 'BL') {
|
||||||
records.alternative_addresses[0].estimated_area = this.addressForm.controls.estimated_area.value
|
records.alternative_addresses[0].estimated_area = this.addressForm.controls.estimated_area.value
|
||||||
records.alternative_addresses[0].uom = this.addressForm.controls.uom.value;
|
records.alternative_addresses[0].uom = this.addressForm.controls.uom.value;
|
||||||
if (this.addressForm.controls.uom.value == 1) {
|
if (this.addressForm.controls.uom.value == 1) {
|
||||||
@ -758,7 +760,7 @@ export class AddressComponent implements OnInit {
|
|||||||
this.addressForm.controls.locality_others.setValue(datas.locality_others);
|
this.addressForm.controls.locality_others.setValue(datas.locality_others);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.lender_short_name != 'CLIX' && this.product_abbr != 'BL'){
|
if(this.lender_short_name != 'CLIX' && this.prod_catagory != 'BL'){
|
||||||
this.addressForm.controls.estimated_area.setValue(datas.estimated_area ? datas.estimated_area : '')
|
this.addressForm.controls.estimated_area.setValue(datas.estimated_area ? datas.estimated_area : '')
|
||||||
this.addressForm.controls.uom.setValue(datas.uom)
|
this.addressForm.controls.uom.setValue(datas.uom)
|
||||||
this.setOthers(datas.uom, '', 5);
|
this.setOthers(datas.uom, '', 5);
|
||||||
@ -831,7 +833,7 @@ export class AddressComponent implements OnInit {
|
|||||||
this.addressForm.controls.locality_others.setValue(datas.locality_others);
|
this.addressForm.controls.locality_others.setValue(datas.locality_others);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.lender_short_name != 'CLIX' && this.product_abbr != 'BL'){
|
if(this.lender_short_name != 'CLIX' && this.prod_catagory != 'BL'){
|
||||||
this.addressForm.controls.estimated_area.setValue(datas.estimated_area);
|
this.addressForm.controls.estimated_area.setValue(datas.estimated_area);
|
||||||
this.addressForm.controls.uom.setValue(datas.uom);
|
this.addressForm.controls.uom.setValue(datas.uom);
|
||||||
this.setOthers(datas.uom, '', 5);
|
this.setOthers(datas.uom, '', 5);
|
||||||
|
|||||||
@ -80,7 +80,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div fxLayout="row nowrap" fxLayoutGap="2px" fxLayoutAlign="start none" *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div fxLayout="row nowrap" fxLayoutGap="2px" fxLayoutAlign="start none" *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:45%">
|
<mat-form-field style="width:45%">
|
||||||
<input matInput placeholder="Area Covered" formControlName="area_covered_by_this_property" OnlyNumber type="text"
|
<input matInput placeholder="Area Covered" formControlName="area_covered_by_this_property" OnlyNumber type="text"
|
||||||
autocomplete="off">
|
autocomplete="off">
|
||||||
@ -358,7 +358,7 @@
|
|||||||
</mat-form-field> -->
|
</mat-form-field> -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<span *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? product_abbr != 'BL' ? true : false : true) && (sup.get('assets_mode').value == 2 || sup.get('assets_mode').value == 3 || sup.get('assets_mode').value == 1)">
|
<span *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? prod_catagory != 'BL' ? true : false : true) && (sup.get('assets_mode').value == 2 || sup.get('assets_mode').value == 3 || sup.get('assets_mode').value == 1)">
|
||||||
<mat-form-field style="width:45%">
|
<mat-form-field style="width:45%">
|
||||||
<mat-label>Age of Asset in Years</mat-label>
|
<mat-label>Age of Asset in Years</mat-label>
|
||||||
<input matInput autocomplete="off" placeholder="eg.99" formControlName="vintage_personal"
|
<input matInput autocomplete="off" placeholder="eg.99" formControlName="vintage_personal"
|
||||||
@ -384,7 +384,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none" *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none" *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
|
|
||||||
<mat-form-field *ngIf="sup.get('assets_mode').value != ''" style="width:95%">
|
<mat-form-field *ngIf="sup.get('assets_mode').value != ''" style="width:95%">
|
||||||
<mat-select placeholder="Is There a Loan Existing Against This Asset?"
|
<mat-select placeholder="Is There a Loan Existing Against This Asset?"
|
||||||
|
|||||||
@ -74,6 +74,7 @@ export class AssetsInfoComponent implements OnInit {
|
|||||||
image_doc_params: { pdid: string; form_id: any; company_id: string; };
|
image_doc_params: { pdid: string; form_id: any; company_id: string; };
|
||||||
form_id: string;
|
form_id: string;
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
|
prod_catagory: any;
|
||||||
constructor(
|
constructor(
|
||||||
notifier: NotifierService,
|
notifier: NotifierService,
|
||||||
private _formBuilder: FormBuilder,
|
private _formBuilder: FormBuilder,
|
||||||
@ -93,6 +94,7 @@ export class AssetsInfoComponent implements OnInit {
|
|||||||
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
||||||
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -155,8 +155,8 @@
|
|||||||
*ngIf="itemrow.controls['business_name_of_the_other_owner'].hasError('required')">Asset
|
*ngIf="itemrow.controls['business_name_of_the_other_owner'].hasError('required')">Asset
|
||||||
Owned by Required</mat-error>
|
Owned by Required</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<!-- {{(lender_short_name == 'MWISE' ? product_abbr != 'BL' ? true : false : true)}} -->
|
<!-- {{(lender_short_name == 'MWISE' ? prod_catagory != 'BL' ? true : false : true)}} -->
|
||||||
<div *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? product_abbr != 'BL' ? true : false : true)">
|
<div *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? prod_catagory != 'BL' ? true : false : true)">
|
||||||
<mat-form-field style="width:45%">
|
<mat-form-field style="width:45%">
|
||||||
<mat-label>Age of Asset in Years</mat-label>
|
<mat-label>Age of Asset in Years</mat-label>
|
||||||
<input matInput autocomplete="off" placeholder="eg.99" formControlName="business_vintage"
|
<input matInput autocomplete="off" placeholder="eg.99" formControlName="business_vintage"
|
||||||
@ -184,7 +184,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<span *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr === 'LFMP'">
|
<span *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory === 'LFMP'">
|
||||||
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
|
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
|
||||||
<mat-form-field style="width:95%"
|
<mat-form-field style="width:95%"
|
||||||
*ngIf="(itemrow.get('business_ownership_type').value == 'owned')">
|
*ngIf="(itemrow.get('business_ownership_type').value == 'owned')">
|
||||||
@ -417,7 +417,7 @@
|
|||||||
*ngIf="sup.controls['business_name_of_the_other_owner'].hasError('required')">Asset
|
*ngIf="sup.controls['business_name_of_the_other_owner'].hasError('required')">Asset
|
||||||
Owned by is Required</mat-error>
|
Owned by is Required</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<div *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? product_abbr != 'BL' ? true : false : true)">
|
<div *ngIf="(lender_short_name != 'CLIX') && (lender_short_name == 'MWISE' ? prod_catagory != 'BL' ? true : false : true)">
|
||||||
<mat-form-field style="width:45%">
|
<mat-form-field style="width:45%">
|
||||||
<mat-label>Age of Asset in Years</mat-label>
|
<mat-label>Age of Asset in Years</mat-label>
|
||||||
<input matInput autocomplete="off" placeholder="eg.99"
|
<input matInput autocomplete="off" placeholder="eg.99"
|
||||||
@ -444,7 +444,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<span
|
<span
|
||||||
*ngIf="(sup.get('business_assets_mode').value != '') && sup.get('business_ownership_type').value == 'owned' && (lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr === 'LFMP')">
|
*ngIf="(sup.get('business_assets_mode').value != '') && sup.get('business_ownership_type').value == 'owned' && (lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory === 'LFMP')">
|
||||||
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
|
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
|
||||||
<mat-form-field style="width:95%">
|
<mat-form-field style="width:95%">
|
||||||
<mat-select placeholder="Is There a Loan Existing Against This Asset?"
|
<mat-select placeholder="Is There a Loan Existing Against This Asset?"
|
||||||
|
|||||||
@ -71,6 +71,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
|||||||
image_doc_params: { pdid: string; form_id: any; company_id: any; };
|
image_doc_params: { pdid: string; form_id: any; company_id: any; };
|
||||||
form_id: string;
|
form_id: string;
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
|
prod_catagory: any;
|
||||||
/**Constructor of the class */
|
/**Constructor of the class */
|
||||||
constructor(
|
constructor(
|
||||||
notifier: NotifierService,
|
notifier: NotifierService,
|
||||||
@ -84,6 +85,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
|||||||
this.form_id='22'
|
this.form_id='22'
|
||||||
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
|
|
||||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||||
this.applicants = this.applicants.filter(appt => appt.applicant_type != 2)
|
this.applicants = this.applicants.filter(appt => appt.applicant_type != 2)
|
||||||
|
|||||||
@ -33,6 +33,7 @@ export class BusinessInfoGroupComponent implements OnInit {
|
|||||||
waitLoading:boolean;
|
waitLoading:boolean;
|
||||||
lender_short_name :any;
|
lender_short_name :any;
|
||||||
product_abbr :any;
|
product_abbr :any;
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(notifier: NotifierService,
|
constructor(notifier: NotifierService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
@ -50,6 +51,7 @@ export class BusinessInfoGroupComponent implements OnInit {
|
|||||||
console.log(this.lender_short_name);
|
console.log(this.lender_short_name);
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
console.log(this.product_abbr);
|
console.log(this.product_abbr);
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1810,7 +1810,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div fxLayout="row" *ngIf="product_abbr == 'LAEP'" >
|
<div fxLayout="row" *ngIf="prod_catagory == 'LAEP'" >
|
||||||
<mat-form-field>
|
<mat-form-field>
|
||||||
<mat-select placeholder="Fire NOC" formControlName="fire_noc" (selectionChange)="radioChange($event,8)" required>
|
<mat-select placeholder="Fire NOC" formControlName="fire_noc" (selectionChange)="radioChange($event,8)" required>
|
||||||
<mat-option value="yes">Yes</mat-option>
|
<mat-option value="yes">Yes</mat-option>
|
||||||
|
|||||||
@ -103,6 +103,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
temp_additiondetailofposmachine: any = [];
|
temp_additiondetailofposmachine: any = [];
|
||||||
image_doc_params: { pdid: number; form_id: number; company_id: String; };
|
image_doc_params: { pdid: number; form_id: number; company_id: String; };
|
||||||
@ViewChild('business_activity_type') business_activity_type_scroll : ElementRef
|
@ViewChild('business_activity_type') business_activity_type_scroll : ElementRef
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
|
|
||||||
constructor(notifier: NotifierService,
|
constructor(notifier: NotifierService,
|
||||||
@ -133,6 +134,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
console.log(this.lender_short_name);
|
console.log(this.lender_short_name);
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
console.log(this.product_abbr);
|
console.log(this.product_abbr);
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
console.log("com",this.company_id)
|
console.log("com",this.company_id)
|
||||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||||
this.getActivity();
|
this.getActivity();
|
||||||
@ -396,15 +398,15 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
});
|
});
|
||||||
if (selectedRetail.length > 0) {
|
if (selectedRetail.length > 0) {
|
||||||
selectedRetail.length > 0 ? this.businessForm.addControl('export_import_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('export_import_cert');
|
selectedRetail.length > 0 ? this.businessForm.addControl('export_import_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('export_import_cert');
|
||||||
if( !(this.lender_short_name == 'CLIX' && this.product_abbr == 'BL') && !(this.lender_short_name == 'MWISE' && this.product_abbr == 'BL')){
|
if( !(this.lender_short_name == 'CLIX' && this.prod_catagory == 'BL') && !(this.lender_short_name == 'MWISE' && this.prod_catagory == 'BL')){
|
||||||
console.log('###PAY');console.log(this.lender_short_name,this.product_abbr)
|
console.log('###PAY');console.log(this.lender_short_name,this.prod_catagory)
|
||||||
selectedRetail.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
selectedRetail.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
||||||
selectedRetail.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
selectedRetail.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
||||||
selectedRetail.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
selectedRetail.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
||||||
selectedRetail.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('pos_machines_details', this.fb.array([])) : this.businessForm.removeControl('pos_machines_details');
|
selectedRetail.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('pos_machines_details', this.fb.array([])) : this.businessForm.removeControl('pos_machines_details');
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
console.log('###ELSE');console.log(this.lender_short_name,this.product_abbr)
|
console.log('###ELSE');console.log(this.lender_short_name,this.prod_catagory)
|
||||||
}
|
}
|
||||||
|
|
||||||
selectedRetail.forEach((element, index) => {
|
selectedRetail.forEach((element, index) => {
|
||||||
@ -467,7 +469,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
});
|
});
|
||||||
if (selectedWholesale.length > 0) {
|
if (selectedWholesale.length > 0) {
|
||||||
selectedWholesale.length > 0 ? this.businessForm.addControl('export_import_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('export_import_cert');
|
selectedWholesale.length > 0 ? this.businessForm.addControl('export_import_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('export_import_cert');
|
||||||
if(!(this.lender_short_name == 'CLIX' && this.product_abbr == 'BL') && !(this.lender_short_name == 'MWISE' && this.product_abbr == 'BL')){
|
if(!(this.lender_short_name == 'CLIX' && this.prod_catagory == 'BL') && !(this.lender_short_name == 'MWISE' && this.prod_catagory == 'BL')){
|
||||||
selectedWholesale.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
selectedWholesale.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
||||||
selectedWholesale.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
selectedWholesale.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
||||||
selectedWholesale.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
selectedWholesale.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
||||||
@ -536,7 +538,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
});
|
});
|
||||||
if (selectedService.length > 0) {
|
if (selectedService.length > 0) {
|
||||||
selectedService.length > 0 ? this.businessForm.addControl('practice_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('practice_cert');
|
selectedService.length > 0 ? this.businessForm.addControl('practice_cert', new FormControl('', Validators.required)) : this.businessForm.removeControl('practice_cert');
|
||||||
if(!(this.lender_short_name == 'CLIX' && this.product_abbr == 'BL') && !(this.lender_short_name == 'MWISE' && this.product_abbr == 'BL')){
|
if(!(this.lender_short_name == 'CLIX' && this.prod_catagory == 'BL') && !(this.lender_short_name == 'MWISE' && this.prod_catagory == 'BL')){
|
||||||
selectedService.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
selectedService.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl('')) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
||||||
selectedService.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
selectedService.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl('')) : this.businessForm.removeControl('applicant_use_pos_machines');
|
||||||
selectedService.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
selectedService.length > 0 && businessVal.applicant_use_pos_machines == 'yes' ? this.businessForm.addControl('no_of_pos_machines', new FormControl('')) : this.businessForm.removeControl('no_of_pos_machines');
|
||||||
@ -627,7 +629,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// this.businessForm.setValue(businessVal);
|
// this.businessForm.setValue(businessVal);
|
||||||
// this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP' ? this.businessForm.addControl('fire_noc', new FormControl('', Validators.required)) : this.businessForm.removeControl('fire_noc');
|
// this.lender_short_name == 'CLIX' || this.prod_catagory == 'LAEP' ? this.businessForm.addControl('fire_noc', new FormControl('', Validators.required)) : this.businessForm.removeControl('fire_noc');
|
||||||
if(data.records.gst_Regn_cert =='yes'){ this.businessForm.addControl('gst_Regn_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('gst_Regn_cert_pic');}
|
if(data.records.gst_Regn_cert =='yes'){ this.businessForm.addControl('gst_Regn_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('gst_Regn_cert_pic');}
|
||||||
if(data.records.factory_cert =='yes'){ this.businessForm.addControl('factory_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('factory_cert_pic');}
|
if(data.records.factory_cert =='yes'){ this.businessForm.addControl('factory_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('factory_cert_pic');}
|
||||||
if(data.records.practice_cert =='yes'){ this.businessForm.addControl('practice_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('practice_cert_pic');}
|
if(data.records.practice_cert =='yes'){ this.businessForm.addControl('practice_cert_pic', new FormControl('')); }else{ this.businessForm.removeControl('practice_cert_pic');}
|
||||||
@ -661,7 +663,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
// load exist company list from master
|
// load exist company list from master
|
||||||
// this.existCompanyList = this.pd_all_details.pdapplicants_detials.filter(item=>item.company_name!=null).map(mapItem=>mapItem.company_name);
|
// this.existCompanyList = this.pd_all_details.pdapplicants_detials.filter(item=>item.company_name!=null).map(mapItem=>mapItem.company_name);
|
||||||
|
|
||||||
this.product_abbr == 'LAEP' ? this.businessForm.addControl('fire_noc', new FormControl('', Validators.required)) : this.businessForm.removeControl('fire_noc');
|
this.prod_catagory == 'LAEP' ? this.businessForm.addControl('fire_noc', new FormControl('', Validators.required)) : this.businessForm.removeControl('fire_noc');
|
||||||
|
|
||||||
if(this.lender_short_name != 'CLIX'){
|
if(this.lender_short_name != 'CLIX'){
|
||||||
// change relation with businees update dat sorce table
|
// change relation with businees update dat sorce table
|
||||||
@ -806,11 +808,11 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
this.businessForm.value.service_provider_activity_details.length > 0 ? this.businessForm.addControl('practice_cert', new FormControl(this.businessForm.value.practice_cert, Validators.required)) : this.businessForm.removeControl('practice_cert');
|
this.businessForm.value.service_provider_activity_details.length > 0 ? this.businessForm.addControl('practice_cert', new FormControl(this.businessForm.value.practice_cert, Validators.required)) : this.businessForm.removeControl('practice_cert');
|
||||||
// check activity for extra question make dynamic
|
// check activity for extra question make dynamic
|
||||||
|
|
||||||
if(!(this.lender_short_name == 'CLIX' && this.product_abbr == 'BL') && !(this.lender_short_name == 'MWISE' && this.product_abbr == 'BL')){
|
if(!(this.lender_short_name == 'CLIX' && this.prod_catagory == 'BL') && !(this.lender_short_name == 'MWISE' && this.prod_catagory == 'BL')){
|
||||||
this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl(this.businessForm.value.applicant_use_mobile_wallets)) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0 ? this.businessForm.addControl('applicant_use_mobile_wallets', new FormControl(this.businessForm.value.applicant_use_mobile_wallets)) : this.businessForm.removeControl('applicant_use_mobile_wallets');
|
||||||
this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl(this.businessForm.value.applicant_use_pos_machines)) : this.businessForm.removeControl('applicant_use_pos_machines');
|
this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0 ? this.businessForm.addControl('applicant_use_pos_machines', new FormControl(this.businessForm.value.applicant_use_pos_machines)) : this.businessForm.removeControl('applicant_use_pos_machines');
|
||||||
if (this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0) {
|
if (this.businessForm.value.service_provider_activity_details.length > 0 || this.businessForm.value.retail_trading_activity_details.length > 0 || this.businessForm.value.wholesale_trading_activity_details.length > 0) {
|
||||||
if(this.businessForm.controls['applicant_use_pos_machines'] && this.product_abbr == 'LAEP'){
|
if(this.businessForm.controls['applicant_use_pos_machines'] && this.prod_catagory == 'LAEP'){
|
||||||
this.businessForm.controls['applicant_use_pos_machines'].setValue('yes');
|
this.businessForm.controls['applicant_use_pos_machines'].setValue('yes');
|
||||||
}
|
}
|
||||||
this.changePOSMachinesAvailablity(this.businessForm.value.applicant_use_pos_machines, 2);
|
this.changePOSMachinesAvailablity(this.businessForm.value.applicant_use_pos_machines, 2);
|
||||||
|
|||||||
@ -35,7 +35,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>
|
||||||
<mat-form-field style="width:60% !important;" *ngIf="currentLoanForm.controls.existing_loan.value == 'Yes' && (product_abbr == 'LAEP' || product_abbr == 'BL' )">
|
<mat-form-field style="width:60% !important;" *ngIf="currentLoanForm.controls.existing_loan.value == 'Yes' && (prod_catagory == 'LAEP' || prod_catagory == 'BL' )">
|
||||||
<mat-select (selectionChange)="selectedLoanChanges($event.value)" placeholder="Details of all loan info available"
|
<mat-select (selectionChange)="selectedLoanChanges($event.value)" placeholder="Details of all loan info available"
|
||||||
formControlName="loan_info_available">
|
formControlName="loan_info_available">
|
||||||
<mat-option>Select</mat-option>
|
<mat-option>Select</mat-option>
|
||||||
|
|||||||
@ -46,6 +46,7 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
isOtherLoanTakenBy:any = [];
|
isOtherLoanTakenBy:any = [];
|
||||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||||
private router: Router,
|
private router: Router,
|
||||||
@ -64,7 +65,8 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||||
this.product_abbr=this.pd_all_details.pdmaster_details.product_abbr
|
this.product_abbr=this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
}
|
}
|
||||||
pdf(fileURL){
|
pdf(fileURL){
|
||||||
window.open(fileURL);
|
window.open(fileURL);
|
||||||
@ -430,7 +432,7 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
public initCurrentloanForm(): void {
|
public initCurrentloanForm(): void {
|
||||||
this.currentLoanForm = this.fb.group({
|
this.currentLoanForm = this.fb.group({
|
||||||
existing_loan: [''],
|
existing_loan: [''],
|
||||||
loan_info_available:[this.product_abbr == 'BL' || this.product_abbr == 'LAEP' ? '' : 'Yes'],
|
loan_info_available:[this.prod_catagory == 'BL' || this.prod_catagory == 'LAEP' ? '' : 'Yes'],
|
||||||
currentloan_remarks: [''],
|
currentloan_remarks: [''],
|
||||||
loan_details: this.fb.array([]),
|
loan_details: this.fb.array([]),
|
||||||
});
|
});
|
||||||
|
|||||||
@ -139,7 +139,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div> -->
|
</div> -->
|
||||||
|
|
||||||
<div *ngIf="lender_short_name !== 'CLIX' && lender_short_name !== 'MWISE' || product_abbr === 'LFMP'">
|
<div *ngIf="lender_short_name !== 'CLIX' && lender_short_name !== 'MWISE' || prod_catagory === 'LFMP'">
|
||||||
<div formArrayName="family_members_details">
|
<div formArrayName="family_members_details">
|
||||||
<div *ngFor="let item of sup.controls.family_members_details['controls']; let i=index; let last=last "
|
<div *ngFor="let item of sup.controls.family_members_details['controls']; let i=index; let last=last "
|
||||||
[formGroupName]="i">
|
[formGroupName]="i">
|
||||||
@ -278,7 +278,7 @@
|
|||||||
</mat-card-actions>
|
</mat-card-actions>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div *ngIf="lender_short_name === 'CLIX' || lender_short_name === 'MWISE' && product_abbr != 'LFMP'">
|
<div *ngIf="lender_short_name === 'CLIX' || lender_short_name === 'MWISE' && prod_catagory != 'LFMP'">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header>
|
<mat-card-header>
|
||||||
<mat-card-title>
|
<mat-card-title>
|
||||||
|
|||||||
@ -69,6 +69,7 @@ export class FamilyDetailsComponent implements OnInit {
|
|||||||
pincodeDataList: any = [];
|
pincodeDataList: any = [];
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
addressList: any = [];
|
addressList: any = [];
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
/** constructor Of the class */
|
/** constructor Of the class */
|
||||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||||
@ -84,6 +85,7 @@ export class FamilyDetailsComponent implements OnInit {
|
|||||||
this.parent_pdid = this.pd_all_details.pdmaster_details.parent_pd_id;
|
this.parent_pdid = this.pd_all_details.pdmaster_details.parent_pd_id;
|
||||||
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name;
|
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||||
this.main_applicant = this.pd_all_details.pdmaster_details.main_applicant;
|
this.main_applicant = this.pd_all_details.pdmaster_details.main_applicant;
|
||||||
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
||||||
|
|||||||
@ -156,11 +156,11 @@
|
|||||||
<mat-error *ngIf="_finalRemarkForm.controls['mode_of_transport_during_visit'].hasError('required')">Specify the Mode of Transport Used to Visit the PD address Required</mat-error>
|
<mat-error *ngIf="_finalRemarkForm.controls['mode_of_transport_during_visit'].hasError('required')">Specify the Mode of Transport Used to Visit the PD address Required</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-card *ngIf="lender_short_name == 'CLIX' || lender_short_name == 'MWISE' || product_abbr == 'LAEP'">
|
<mat-card *ngIf="lender_short_name == 'CLIX' || lender_short_name == 'MWISE' || prod_catagory == 'LAEP'">
|
||||||
<mat-card-content>
|
<mat-card-content>
|
||||||
<mat-card-subtitle *ngIf="lender_short_name == 'CLIX'">CLIX</mat-card-subtitle>
|
<mat-card-subtitle *ngIf="lender_short_name == 'CLIX'">CLIX</mat-card-subtitle>
|
||||||
<mat-card-subtitle *ngIf="lender_short_name == 'MWISE'">MWISE</mat-card-subtitle>
|
<mat-card-subtitle *ngIf="lender_short_name == 'MWISE'">MWISE</mat-card-subtitle>
|
||||||
<mat-form-field style="width:94%;" *ngIf="_finalRemarkForm.controls['outlet_location'] && product_abbr == 'LAEP'">
|
<mat-form-field style="width:94%;" *ngIf="_finalRemarkForm.controls['outlet_location'] && prod_catagory == 'LAEP'">
|
||||||
<mat-select placeholder="Comment on Footfall in the market where the B2C outlet is located…" formControlName="outlet_location"
|
<mat-select placeholder="Comment on Footfall in the market where the B2C outlet is located…" formControlName="outlet_location"
|
||||||
required>
|
required>
|
||||||
<mat-option>Select</mat-option>
|
<mat-option>Select</mat-option>
|
||||||
|
|||||||
@ -56,6 +56,7 @@ export class FinalRemarksComponent implements OnInit {
|
|||||||
public documentsAndFilesList = [];
|
public documentsAndFilesList = [];
|
||||||
private notifier: NotifierService;
|
private notifier: NotifierService;
|
||||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
notifier: NotifierService,
|
notifier: NotifierService,
|
||||||
@ -75,6 +76,7 @@ export class FinalRemarksComponent implements OnInit {
|
|||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
|
|
||||||
this._finalRemarkForm = this._formBuilder.group({
|
this._finalRemarkForm = this._formBuilder.group({
|
||||||
parent_pdid: [this.parent_pdid],
|
parent_pdid: [this.parent_pdid],
|
||||||
@ -104,8 +106,8 @@ export class FinalRemarksComponent implements OnInit {
|
|||||||
final_form_remarks: ['']
|
final_form_remarks: ['']
|
||||||
});
|
});
|
||||||
|
|
||||||
if(this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.product_abbr == 'LAEP'){
|
if(this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.prod_catagory == 'LAEP'){
|
||||||
this.product_abbr == 'LAEP' ? this._finalRemarkForm.addControl('outlet_location', new FormControl('', Validators.required)) : this._finalRemarkForm.removeControl('outlet_location');
|
this.prod_catagory == 'LAEP' ? this._finalRemarkForm.addControl('outlet_location', new FormControl('', Validators.required)) : this._finalRemarkForm.removeControl('outlet_location');
|
||||||
this._finalRemarkForm.addControl('is_competition', new FormControl(''));
|
this._finalRemarkForm.addControl('is_competition', new FormControl(''));
|
||||||
this._finalRemarkForm.addControl('sealing_activity', new FormControl(''));
|
this._finalRemarkForm.addControl('sealing_activity', new FormControl(''));
|
||||||
this._finalRemarkForm.addControl('demolition_activity', new FormControl(''));
|
this._finalRemarkForm.addControl('demolition_activity', new FormControl(''));
|
||||||
@ -116,7 +118,7 @@ export class FinalRemarksComponent implements OnInit {
|
|||||||
this._finalRemarkForm.removeControl('sealing_activity');
|
this._finalRemarkForm.removeControl('sealing_activity');
|
||||||
this._finalRemarkForm.removeControl('demolition_activity');
|
this._finalRemarkForm.removeControl('demolition_activity');
|
||||||
}
|
}
|
||||||
// if(this.product_abbr != 'LAEP'){
|
// if(this.prod_catagory != 'LAEP'){
|
||||||
// this._finalRemarkForm.controls['final_form_remarks'].setValidators(Validators.compose([Validators.required]))
|
// this._finalRemarkForm.controls['final_form_remarks'].setValidators(Validators.compose([Validators.required]))
|
||||||
// }
|
// }
|
||||||
// else{
|
// else{
|
||||||
@ -244,9 +246,9 @@ export class FinalRemarksComponent implements OnInit {
|
|||||||
this._finalRemarkForm.controls.market_intelligence.setValue(data.records.market_intelligence || '');
|
this._finalRemarkForm.controls.market_intelligence.setValue(data.records.market_intelligence || '');
|
||||||
|
|
||||||
|
|
||||||
if(this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.product_abbr == 'LAEP'){
|
if(this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.prod_catagory == 'LAEP'){
|
||||||
|
|
||||||
if(this.product_abbr == 'LAEP') {this._finalRemarkForm.controls.outlet_location.setValue(this.product_abbr == 'LAEP' ? data.records.outlet_location : ''); }
|
if(this.prod_catagory == 'LAEP') {this._finalRemarkForm.controls.outlet_location.setValue(this.prod_catagory == 'LAEP' ? data.records.outlet_location : ''); }
|
||||||
this._finalRemarkForm.controls.is_competition.setValue(data.records.is_competition);
|
this._finalRemarkForm.controls.is_competition.setValue(data.records.is_competition);
|
||||||
this._finalRemarkForm.controls.sealing_activity.setValue(data.records.sealing_activity);
|
this._finalRemarkForm.controls.sealing_activity.setValue(data.records.sealing_activity);
|
||||||
this._finalRemarkForm.controls.demolition_activity.setValue(data.records.demolition_activity);
|
this._finalRemarkForm.controls.demolition_activity.setValue(data.records.demolition_activity);
|
||||||
|
|||||||
@ -477,7 +477,7 @@
|
|||||||
formControlName="estimate_reason_for_loss">
|
formControlName="estimate_reason_for_loss">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
<mat-form-field style="width:54%" *ngIf="lender_short_name == 'CLIX' && product_abbr =='LAEP'">
|
<mat-form-field style="width:54%" *ngIf="lender_short_name == 'CLIX' && prod_catagory =='LAEP'">
|
||||||
<input matInput placeholder="Annual Sales through Credit Card / POS machines"
|
<input matInput placeholder="Annual Sales through Credit Card / POS machines"
|
||||||
formControlName="estimate_posmachine_or_cc_annual_sales">
|
formControlName="estimate_posmachine_or_cc_annual_sales">
|
||||||
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_posmachine_or_cc_annual_sales').value != ''">{{"₹"}}
|
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_posmachine_or_cc_annual_sales').value != ''">{{"₹"}}
|
||||||
|
|||||||
@ -84,6 +84,7 @@ export class FinancialInfoComponent implements OnInit {
|
|||||||
// values = [0, 1, 2, 3];
|
// values = [0, 1, 2, 3];
|
||||||
documentsAndFilesList: any = [];
|
documentsAndFilesList: any = [];
|
||||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(notifier: NotifierService,
|
constructor(notifier: NotifierService,
|
||||||
private fb: FormBuilder,
|
private fb: FormBuilder,
|
||||||
@ -103,6 +104,7 @@ export class FinancialInfoComponent implements OnInit {
|
|||||||
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
this.lender_applicant_id = this.pd_all_details.pdmaster_details.lender_applicant_id;
|
||||||
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
this.subproduct_abbr = this.pd_all_details.pdmaster_details.subproduct_abbr;
|
||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
let x = this.customer_segment_abbr.split("-");
|
let x = this.customer_segment_abbr.split("-");
|
||||||
|
|||||||
@ -54,6 +54,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
|||||||
public documentsAndFilesList = [];
|
public documentsAndFilesList = [];
|
||||||
private notifier: NotifierService;
|
private notifier: NotifierService;
|
||||||
image_doc_params: { pdid: string; form_id: number; company_id: any; };
|
image_doc_params: { pdid: string; form_id: number; company_id: any; };
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
notifier: NotifierService,
|
notifier: NotifierService,
|
||||||
@ -75,6 +76,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
|||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
this.lender_short_name = this.pd_all_details.pdmaster_details.lender_short_name;
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
|
|
||||||
this._futurePlansForm = this._formBuilder.group({
|
this._futurePlansForm = this._formBuilder.group({
|
||||||
parent_pdid: [this.parent_pdid],
|
parent_pdid: [this.parent_pdid],
|
||||||
@ -89,7 +91,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
|||||||
remarks: ['']
|
remarks: ['']
|
||||||
});
|
});
|
||||||
|
|
||||||
if(this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP'){ }
|
if(this.lender_short_name == 'CLIX' || this.prod_catagory == 'LAEP'){ }
|
||||||
else{ }
|
else{ }
|
||||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -58,7 +58,7 @@
|
|||||||
<mat-error *ngIf="loanDetailsForm.controls['end_use_other'].hasError('required')">End Use Required</mat-error>
|
<mat-error *ngIf="loanDetailsForm.controls['end_use_other'].hasError('required')">End Use Required</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-form-field style="width: 28%" *ngIf="lenderShortName == 'CLIX' || lenderShortName == 'MWISE' && productAbbr != 'LFMP'">
|
<mat-form-field style="width: 28%" *ngIf="lenderShortName == 'CLIX' || lenderShortName == 'MWISE' && prod_catagory != 'LFMP'">
|
||||||
<mat-select placeholder="Total fund requirement"
|
<mat-select placeholder="Total fund requirement"
|
||||||
formControlName="is_there_total_fund">
|
formControlName="is_there_total_fund">
|
||||||
<mat-option>Select</mat-option>
|
<mat-option>Select</mat-option>
|
||||||
@ -76,7 +76,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div *ngIf="lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || productAbbr == 'LFMP'">
|
<div *ngIf="lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width: 64%">
|
<mat-form-field style="width: 64%">
|
||||||
<mat-select placeholder="Is there a balance transfer ? " (selectionChange)="selectedBalancesTransferChanges($event.value)"
|
<mat-select placeholder="Is there a balance transfer ? " (selectionChange)="selectedBalancesTransferChanges($event.value)"
|
||||||
formControlName="is_transfer">
|
formControlName="is_transfer">
|
||||||
@ -119,7 +119,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
|
|
||||||
<mat-form-field style="width:64%" *ngIf="loanDetailsForm.controls['topup_amount'].value > 0 && (lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || productAbbr == 'LFMP')">
|
<mat-form-field style="width:64%" *ngIf="loanDetailsForm.controls['topup_amount'].value > 0 && (lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || prod_catagory == 'LFMP')">
|
||||||
<mat-select placeholder="What is the End Use of the Top Up?"
|
<mat-select placeholder="What is the End Use of the Top Up?"
|
||||||
formControlName="end_use_topup">
|
formControlName="end_use_topup">
|
||||||
<mat-option>Select</mat-option>
|
<mat-option>Select</mat-option>
|
||||||
@ -166,7 +166,7 @@
|
|||||||
</span>
|
</span>
|
||||||
|
|
||||||
|
|
||||||
<mat-form-field style="width: 64%" *ngIf="lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || productAbbr == 'LFMP'">
|
<mat-form-field style="width: 64%" *ngIf="lenderShortName != 'CLIX' && lenderShortName != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<input matInput placeholder="EMI Amount Comfortable Paying" formControlName="emi_level"
|
<input matInput placeholder="EMI Amount Comfortable Paying" formControlName="emi_level"
|
||||||
OnlyNumber type="text" autocomplete="off">
|
OnlyNumber type="text" autocomplete="off">
|
||||||
<mat-hint align="start" style="font-size:90%" *ngIf="loanDetailsForm.controls['emi_level'].value != ''">{{"₹"}} {{ loanDetailsForm.controls['emi_level'].value | numberToWords }} Only</mat-hint>
|
<mat-hint align="start" style="font-size:90%" *ngIf="loanDetailsForm.controls['emi_level'].value != ''">{{"₹"}} {{ loanDetailsForm.controls['emi_level'].value | numberToWords }} Only</mat-hint>
|
||||||
@ -175,7 +175,7 @@
|
|||||||
|
|
||||||
</mat-card-content>
|
</mat-card-content>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
<!-- <div *ngIf="productAbbr === 'HL' || productAbbr === 'LL' || productAbbr === 'LAP' "> -->
|
<!-- <div *ngIf="prod_catagory === 'HL' || prod_catagory === 'LL' || prod_catagory === 'LAP' "> -->
|
||||||
<mat-card *ngIf="mortageCardAccess">
|
<mat-card *ngIf="mortageCardAccess">
|
||||||
<mat-card-header>
|
<mat-card-header>
|
||||||
<p>Details of Property being Mortgaged</p>
|
<p>Details of Property being Mortgaged</p>
|
||||||
@ -246,7 +246,7 @@
|
|||||||
<mat-hint align="start" style="font-size:90%" *ngIf="loanDetailsForm.controls['emv_per_customer'].value != ''">{{"₹"}} {{ loanDetailsForm.controls['emv_per_customer'].value | numberToWords }} Only</mat-hint>
|
<mat-hint align="start" style="font-size:90%" *ngIf="loanDetailsForm.controls['emv_per_customer'].value != ''">{{"₹"}} {{ loanDetailsForm.controls['emv_per_customer'].value | numberToWords }} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-form-field *ngIf="productAbbr !== 'LAP' && productAbbr !== 'LFMP'" style="width:96%;">
|
<mat-form-field *ngIf="prod_catagory !== 'LAP' && prod_catagory !== 'LFMP'" style="width:96%;">
|
||||||
<input matInput placeholder="Name of current owner(s)/ Seller(s) of the property" formControlName="property_seller"
|
<input matInput placeholder="Name of current owner(s)/ Seller(s) of the property" formControlName="property_seller"
|
||||||
autocomplete="off">
|
autocomplete="off">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|||||||
@ -94,6 +94,7 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
address_placeholder: string;
|
address_placeholder: string;
|
||||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||||
addressList: any = [];
|
addressList: any = [];
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -112,6 +113,7 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
this.applicants = this.applicants.filter(appt => appt.applicant_type != 2)
|
this.applicants = this.applicants.filter(appt => appt.applicant_type != 2)
|
||||||
// this.companies = this.pd_all_details.pdapplicants_detials.filter(appt=>appt.applicant_type == 2 )
|
// this.companies = this.pd_all_details.pdapplicants_detials.filter(appt=>appt.applicant_type == 2 )
|
||||||
this.productAbbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.productAbbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
this.productID = this.pd_all_details.pdmaster_details.fk_product_id;
|
this.productID = this.pd_all_details.pdmaster_details.fk_product_id;
|
||||||
this.subProductName = this.pd_all_details.pdmaster_details.subproduct_name;
|
this.subProductName = this.pd_all_details.pdmaster_details.subproduct_name;
|
||||||
this.exist_loan_amt = this.pd_all_details.pdmaster_details.loan_amount != '' ? this.pd_all_details.pdmaster_details.loan_amount : '';
|
this.exist_loan_amt = this.pd_all_details.pdmaster_details.loan_amount != '' ? this.pd_all_details.pdmaster_details.loan_amount : '';
|
||||||
@ -126,10 +128,10 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||||
this.lenderShortName = this.pd_all_details.pdmaster_details.lender_short_name;
|
this.lenderShortName = this.pd_all_details.pdmaster_details.lender_short_name;
|
||||||
|
|
||||||
if (this.productAbbr == 'PL' || this.productAbbr == 'BL' || this.productAbbr == 'LAP' || this.productAbbr == 'LFMP') {
|
if (this.prod_catagory == 'PL' || this.prod_catagory == 'BL' || this.prod_catagory == 'LAP' || this.prod_catagory == 'LFMP') {
|
||||||
this.isContribution = true;
|
this.isContribution = true;
|
||||||
}
|
}
|
||||||
if(this.productAbbr == 'HL' || this.productAbbr == 'NRPL' || this.productAbbr == 'LL'){
|
if(this.prod_catagory == 'HL' || this.prod_catagory == 'NRPL' || this.prod_catagory == 'LL'){
|
||||||
this.Owner_placeholder="Name of the proposed owner"
|
this.Owner_placeholder="Name of the proposed owner"
|
||||||
this.address_placeholder="Address of the proposed property"
|
this.address_placeholder="Address of the proposed property"
|
||||||
}
|
}
|
||||||
@ -183,7 +185,7 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
|
|
||||||
// this.listOfLanguagues.splice(this.listOfLanguagues.indexOf(languague), 1);
|
// this.listOfLanguagues.splice(this.listOfLanguagues.indexOf(languague), 1);
|
||||||
}
|
}
|
||||||
if (this.productAbbr != 'LAP') {
|
if (this.prod_catagory != 'LAP') {
|
||||||
this.mergeCompanyApplicant.push({ groupName: 'OTHERS', groupValues: [{ id: 0, name: 'Not Yet Finalised', group_id: 2 }] })
|
this.mergeCompanyApplicant.push({ groupName: 'OTHERS', groupValues: [{ id: 0, name: 'Not Yet Finalised', group_id: 2 }] })
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -198,7 +200,7 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
params.pd_id = this.pdid;
|
params.pd_id = this.pdid;
|
||||||
params.pd_form_id = this.form_id;
|
params.pd_form_id = this.form_id;
|
||||||
this._pd.retriveForm(params).subscribe(value => {
|
this._pd.retriveForm(params).subscribe(value => {
|
||||||
// *ngIf="productAbbr === 'HL' || productAbbr === 'LL' || productAbbr === 'LAP' "
|
// *ngIf="prod_catagory === 'HL' || prod_catagory === 'LL' || prod_catagory === 'LAP' "
|
||||||
if (value.status == 200) {
|
if (value.status == 200) {
|
||||||
let result = Object.keys(value.records.end_use_group).map(function (key) {
|
let result = Object.keys(value.records.end_use_group).map(function (key) {
|
||||||
return value.records.end_use_group[key];
|
return value.records.end_use_group[key];
|
||||||
@ -319,10 +321,10 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
this.loanDetailsForm.controls['emv_per_customer'].setValue(value.records.emv_per_customer);
|
this.loanDetailsForm.controls['emv_per_customer'].setValue(value.records.emv_per_customer);
|
||||||
// this.emvAmtInWords = this._pd.convertNumberToWords(value.records.emv_per_customer);
|
// this.emvAmtInWords = this._pd.convertNumberToWords(value.records.emv_per_customer);
|
||||||
}
|
}
|
||||||
console.log("product abbr",this.productAbbr);
|
console.log("product abbr",this.prod_catagory);
|
||||||
console.log("value",value)
|
console.log("value",value)
|
||||||
|
|
||||||
this.loanDetailsForm.controls['property_seller'].setValue(this.productAbbr != 'LAP' ? value.records.property_seller || null : '');
|
this.loanDetailsForm.controls['property_seller'].setValue(this.prod_catagory != 'LAP' ? value.records.property_seller || null : '');
|
||||||
this.loanDetailsForm.controls['address'].setValue(value.records.address || null);
|
this.loanDetailsForm.controls['address'].setValue(value.records.address || null);
|
||||||
this.loanDetailsForm.controls['state'].setValue(value.records.state || null );
|
this.loanDetailsForm.controls['state'].setValue(value.records.state || null );
|
||||||
if(value.records.state != ''){this.getCityAndPincodeDetails(value.records.state);}
|
if(value.records.state != ''){this.getCityAndPincodeDetails(value.records.state);}
|
||||||
@ -346,7 +348,7 @@ export class LoanDetailsComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
if (this.productAbbr == 'BL' || this.productAbbr == 'PL' || this.productAbbr == 'LAEP') {
|
if (this.prod_catagory == 'BL' || this.prod_catagory == 'PL' || this.prod_catagory == 'LAEP') {
|
||||||
this.mortageCardAccess = false;
|
this.mortageCardAccess = false;
|
||||||
this.loanDetailsForm.controls['owner_name'].setValue('');
|
this.loanDetailsForm.controls['owner_name'].setValue('');
|
||||||
this.loanDetailsForm.controls['owner_name'].clearValidators();
|
this.loanDetailsForm.controls['owner_name'].clearValidators();
|
||||||
|
|||||||
@ -46,7 +46,7 @@
|
|||||||
<mat-error *ngIf="mrm.controls['stock_observed'].hasError('required')">Stock Required</mat-error>
|
<mat-error *ngIf="mrm.controls['stock_observed'].hasError('required')">Stock Required</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<span *ngIf="mrm.get('stock_observed').value == 'yes'">
|
<span *ngIf="mrm.get('stock_observed').value == 'yes'">
|
||||||
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:30%">
|
<mat-form-field style="width:30%">
|
||||||
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
||||||
formControlName="raw_quantity" OnlyNumber type="text">
|
formControlName="raw_quantity" OnlyNumber type="text">
|
||||||
@ -141,7 +141,7 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<span *ngIf="mfg.get('goods_observed').value == 'yes'">
|
<span *ngIf="mfg.get('goods_observed').value == 'yes'">
|
||||||
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:30%">
|
<mat-form-field style="width:30%">
|
||||||
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
||||||
formControlName="goods_quantity" OnlyNumber
|
formControlName="goods_quantity" OnlyNumber
|
||||||
@ -227,7 +227,7 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<span *ngIf="item.get('traded_goods_observed').value == 'yes'">
|
<span *ngIf="item.get('traded_goods_observed').value == 'yes'">
|
||||||
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:30%">
|
<mat-form-field style="width:30%">
|
||||||
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
||||||
formControlName="traded_goods_quantity"
|
formControlName="traded_goods_quantity"
|
||||||
@ -316,7 +316,7 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<span *ngIf="tradetg.get('traded_goods_observed').value == 'yes'">
|
<span *ngIf="tradetg.get('traded_goods_observed').value == 'yes'">
|
||||||
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:30%">
|
<mat-form-field style="width:30%">
|
||||||
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
||||||
formControlName="traded_goods_quantity"
|
formControlName="traded_goods_quantity"
|
||||||
@ -430,7 +430,7 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<span *ngIf="sp.get('service_provider_observed').value == 'yes'">
|
<span *ngIf="sp.get('service_provider_observed').value == 'yes'">
|
||||||
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || product_abbr == 'LFMP'">
|
<div *ngIf="lender_short_name != 'CLIX' && lender_short_name != 'MWISE' || prod_catagory == 'LFMP'">
|
||||||
<mat-form-field style="width:30%">
|
<mat-form-field style="width:30%">
|
||||||
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
<input matInput autocomplete="off" placeholder="Estimated Quantity"
|
||||||
formControlName="service_provider_quantity"
|
formControlName="service_provider_quantity"
|
||||||
|
|||||||
@ -60,6 +60,7 @@ export class StockComponent implements OnInit {
|
|||||||
lender_short_name: any;
|
lender_short_name: any;
|
||||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||||
product_abbr: any;
|
product_abbr: any;
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
/** Constructor */
|
/** Constructor */
|
||||||
constructor(notifier: NotifierService,
|
constructor(notifier: NotifierService,
|
||||||
@ -75,6 +76,7 @@ export class StockComponent implements OnInit {
|
|||||||
this.parent_pdid = this.pd_all_details.pdmaster_details.parent_pd_id
|
this.parent_pdid = this.pd_all_details.pdmaster_details.parent_pd_id
|
||||||
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
||||||
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
this.product_abbr = this.pd_all_details.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = this.pd_all_details.pdmaster_details.prod_catagory;
|
||||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||||
this.form_id = 11;
|
this.form_id = 11;
|
||||||
this.company_id = this.pd_all_details.company_id;
|
this.company_id = this.pd_all_details.company_id;
|
||||||
|
|||||||
@ -68,6 +68,7 @@ export class QcStartComponent implements OnInit, OnDestroy {
|
|||||||
actualQuestions: number;
|
actualQuestions: number;
|
||||||
answeredQuestions: number;
|
answeredQuestions: number;
|
||||||
private notifier: NotifierService;
|
private notifier: NotifierService;
|
||||||
|
prod_catagory: any;
|
||||||
|
|
||||||
constructor(notifier: NotifierService, private dialog: MatDialog, private fb: FormBuilder, private route: ActivatedRoute,
|
constructor(notifier: NotifierService, private dialog: MatDialog, private fb: FormBuilder, private route: ActivatedRoute,
|
||||||
private router: Router,
|
private router: Router,
|
||||||
@ -119,6 +120,7 @@ export class QcStartComponent implements OnInit, OnDestroy {
|
|||||||
this.categoryFormButtons = Object.keys(data.records.template_forms).map((item)=>data.records.template_forms[item]).filter(item=>item.isAnswerable===true);
|
this.categoryFormButtons = Object.keys(data.records.template_forms).map((item)=>data.records.template_forms[item]).filter(item=>item.isAnswerable===true);
|
||||||
this.lender_short_name = data.records.pdmaster_details.lender_short_name;
|
this.lender_short_name = data.records.pdmaster_details.lender_short_name;
|
||||||
this.product_abbr = data.records.pdmaster_details.product_abbr;
|
this.product_abbr = data.records.pdmaster_details.product_abbr;
|
||||||
|
this.prod_catagory = data.records.pdmaster_details.prod_catagory;
|
||||||
// this.categoryFormButtons = this.categoryFormButtons.filter(item=>item.isAnswerable===true);
|
// this.categoryFormButtons = this.categoryFormButtons.filter(item=>item.isAnswerable===true);
|
||||||
this.actualQuestions = this.categoryFormButtons.length;
|
this.actualQuestions = this.categoryFormButtons.length;
|
||||||
let getAnsweredFormsCount = this.categoryFormButtons.filter(item=>item.isAnswered===true);
|
let getAnsweredFormsCount = this.categoryFormButtons.filter(item=>item.isAnswered===true);
|
||||||
@ -445,21 +447,22 @@ export class QcStartComponent implements OnInit, OnDestroy {
|
|||||||
.subscribe(dataresult => {
|
.subscribe(dataresult => {
|
||||||
this.loadTemplates(this.startPD,2,this.randomString);
|
this.loadTemplates(this.startPD,2,this.randomString);
|
||||||
});
|
});
|
||||||
}else
|
|
||||||
if((this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP') && this.selectedFormsCategory.form_id==23){
|
|
||||||
const dialogRef = this.dialog.open(FuturePlansAndBusinessEnvironmentComponent, {
|
|
||||||
data: this.pdFullDetails,
|
|
||||||
maxWidth: '100vw',
|
|
||||||
maxHeight: '100vh',
|
|
||||||
height: '100%',
|
|
||||||
width: '100%',
|
|
||||||
disableClose: true
|
|
||||||
});
|
|
||||||
dialogRef.afterClosed()
|
|
||||||
.subscribe(dataresult => {
|
|
||||||
this.loadTemplates(this.startPD,2,this.randomString);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
// else
|
||||||
|
// if((this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP') && this.selectedFormsCategory.form_id==23){
|
||||||
|
// const dialogRef = this.dialog.open(FuturePlansAndBusinessEnvironmentComponent, {
|
||||||
|
// data: this.pdFullDetails,
|
||||||
|
// maxWidth: '100vw',
|
||||||
|
// maxHeight: '100vh',
|
||||||
|
// height: '100%',
|
||||||
|
// width: '100%',
|
||||||
|
// disableClose: true
|
||||||
|
// });
|
||||||
|
// dialogRef.afterClosed()
|
||||||
|
// .subscribe(dataresult => {
|
||||||
|
// this.loadTemplates(this.startPD,2,this.randomString);
|
||||||
|
// });
|
||||||
|
// }
|
||||||
else
|
else
|
||||||
if(this.selectedFormsCategory.form_id==24){
|
if(this.selectedFormsCategory.form_id==24){
|
||||||
const dialogRef = this.dialog.open(QueriesDocsComponent, {
|
const dialogRef = this.dialog.open(QueriesDocsComponent, {
|
||||||
|
|||||||
@ -1,26 +1,45 @@
|
|||||||
<form [formGroup]="_otherPreferenceForm">
|
<form [formGroup]="_otherPreferenceForm">
|
||||||
<div fxLayout="row wrap" fxLayout.xs="column" fxLayoutGap="2%" fxLayoutAlign="center center" style="margin-top:8px;">
|
<div fxLayout="row wrap" fxLayout.xs="column" fxLayoutGap="2%" fxLayoutAlign="center center" style="margin-top:8px;">
|
||||||
<mat-form-field fxFlex="40%" appearance="outline">
|
<mat-form-field fxFlex="60%" appearance="outline">
|
||||||
<mat-label>Products</mat-label>
|
<mat-label>Products</mat-label>
|
||||||
<mat-select formControlName="products" multiple>
|
<mat-select formControlName="products" multiple>
|
||||||
<mat-option (click)="selectAll('products')" [value]="0">Select All</mat-option>
|
<mat-option (click)="selectAll('products')" [value]="0">Select All <span style="float: right;">Default</span></mat-option>
|
||||||
<mat-option *ngFor="let option of productList" [value]="option.product_id">{{option.product_name}}</mat-option>
|
<span *ngFor="let option of productList; let p_i=index">
|
||||||
|
<mat-option [value]="option.product_id">{{option.product_name}}
|
||||||
|
</mat-option>
|
||||||
|
<ng-container formArrayName="products_default">
|
||||||
|
<!-- <span *ngFor="let prod_toggle of _otherPreferenceForm.controls.products_default['controls']; let i=index" > -->
|
||||||
|
<mat-slide-toggle [disabled]="checkDisableToggle(_otherPreferenceForm.getRawValue().products,option.product_id)" [formControlName]="p_i" (change)="default_toggle($event,option.product_id,p_i,1)" style="float: right;margin-top: -40px;margin-right: 18px;"></mat-slide-toggle>
|
||||||
|
<!-- </span> -->
|
||||||
|
</ng-container>
|
||||||
|
</span>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
<!-- {{_otherPreferenceForm.value.products}} -->
|
||||||
<mat-form-field fxFlex="40%" appearance="outline">
|
<mat-form-field fxFlex="40%" appearance="outline">
|
||||||
<mat-label>Customer Segments</mat-label>
|
<mat-label>Customer Segments</mat-label>
|
||||||
<mat-select formControlName="customer_segments" multiple>
|
<mat-select formControlName="customer_segments" multiple>
|
||||||
<mat-option (click)="selectAll('customer_segments')" [value]="0">Select All</mat-option>
|
<mat-option (click)="selectAll('customer_segments')" [value]="0">Select All</mat-option>
|
||||||
<mat-option *ngFor="let option of customerSegmentList" [value]="option.customer_segment_id">{{option.customer_segment}}</mat-option>
|
<span *ngFor="let option of customerSegmentList; let p_i=index">
|
||||||
|
<mat-option [value]="option.customer_segment_id">{{option.customer_segment}}</mat-option>
|
||||||
|
<ng-container formArrayName="customer_segments_default">
|
||||||
|
<mat-slide-toggle [disabled]="checkDisableToggle(_otherPreferenceForm.value.customer_segments,option.customer_segment_id)" [formControlName]="p_i" (change)="default_toggle($event,option.customer_segment_id,p_i,2)" style="float: right;margin-top: -40px;margin-right: 18px;"></mat-slide-toggle>
|
||||||
|
</ng-container>
|
||||||
|
</span>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field fxFlex="30%" appearance="outline">
|
<mat-form-field fxFlex="40%" appearance="outline">
|
||||||
<mat-label>PD Types</mat-label>
|
<mat-label>PD Types</mat-label>
|
||||||
<mat-select formControlName="pd_types" multiple>
|
<mat-select formControlName="pd_types" multiple>
|
||||||
<mat-option (click)="selectAll('pd_types')" [value]="0">Select All</mat-option>
|
<mat-option (click)="selectAll('pd_types')" [value]="0">Select All</mat-option>
|
||||||
<mat-option *ngFor="let option of pdTypeList" [value]="option.pd_type_id">{{option.type_name}}</mat-option>
|
<span *ngFor="let option of pdTypeList; let p_i=index">
|
||||||
|
<mat-option [value]="option.pd_type_id">{{option.type_name}}</mat-option>
|
||||||
|
<ng-container formArrayName="pd_types_default">
|
||||||
|
<mat-slide-toggle [disabled]="checkDisableToggle(_otherPreferenceForm.value.pd_types,option.pd_type_id)" [formControlName]="p_i" (change)="default_toggle($event,option.pd_type_id,p_i,3)" style="float: right;margin-top: -40px;margin-right: 18px;"></mat-slide-toggle>
|
||||||
|
</ng-container>
|
||||||
|
</span>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
<!-- <mat-error *ngIf="getForm.product.hasError('required')" class="mat-text-warn">Product is Required.!</mat-error> -->
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|||||||
@ -1,8 +1,9 @@
|
|||||||
import { Component, OnInit, Input } from '@angular/core';
|
import { Component, OnInit, Input } from '@angular/core';
|
||||||
import { FormGroup, FormBuilder } from '@angular/forms';
|
import { FormGroup, FormBuilder, FormArray, FormControl } from '@angular/forms';
|
||||||
import { EntityService } from 'app/settings/service/entity/entity.service';
|
import { EntityService } from 'app/settings/service/entity/entity.service';
|
||||||
import { NotifierService } from 'angular-notifier';
|
import { NotifierService } from 'angular-notifier';
|
||||||
import { AwsService } from 'app/AwsService/aws.service';
|
import { AwsService } from 'app/AwsService/aws.service';
|
||||||
|
import { MatSlideToggleChange } from '@angular/material';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-entity-other-preference',
|
selector: 'app-entity-other-preference',
|
||||||
@ -21,24 +22,56 @@ export class EntityOtherPreferenceComponent implements OnInit {
|
|||||||
constructor(private entityService:EntityService,private _fb:FormBuilder,notifier:NotifierService,private awsService:AwsService) {
|
constructor(private entityService:EntityService,private _fb:FormBuilder,notifier:NotifierService,private awsService:AwsService) {
|
||||||
this.notifier=notifier
|
this.notifier=notifier
|
||||||
this.users=this.awsService.getlocale()
|
this.users=this.awsService.getlocale()
|
||||||
|
this.getDropdownValues()
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.getDropdownValues()
|
|
||||||
this._otherPreferenceForm=this._fb.group({
|
this._otherPreferenceForm=this._fb.group({
|
||||||
products:[''],
|
products:[''],
|
||||||
customer_segments:[''],
|
customer_segments:[''],
|
||||||
pd_types:[''],
|
pd_types:[''],
|
||||||
fk_entity_id:[this.entityId],
|
fk_entity_id:[this.entityId],
|
||||||
fk_createdby:[this.users],
|
fk_createdby:[this.users],
|
||||||
fk_updatedby:[this.users]
|
fk_updatedby:[this.users],
|
||||||
|
products_default:this._fb.array([]),
|
||||||
|
customer_segments_default:this._fb.array([]),
|
||||||
|
pd_types_default:this._fb.array([])
|
||||||
})
|
})
|
||||||
|
setTimeout(() => {
|
||||||
this.getvalueFromApi()
|
this.getvalueFromApi()
|
||||||
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
getvalueFromApi(){
|
getvalueFromApi(){
|
||||||
this.entityService.getEntityOtherPreferences(this.entityId).subscribe(res=>{
|
this.entityService.getEntityOtherPreferences(this.entityId).subscribe(res=>{
|
||||||
if(res['dataStatus']){
|
if(res['dataStatus']){
|
||||||
|
this.productList.forEach((element,index) => {
|
||||||
|
if(element.product_id == res['records'].products_default){
|
||||||
|
let event={checked:true}
|
||||||
|
this.default_toggle(event,element.product_id,index,1)
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.customerSegmentList.forEach((element,index) => {
|
||||||
|
if(element.customer_segment_id == res['records'].customer_segments_default){
|
||||||
|
let event={checked:true}
|
||||||
|
this.default_toggle(event,element.customer_segment_id,index,2)
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.pdTypeList.forEach((element,index) => {
|
||||||
|
if(element.pd_type_id == res['records'].pd_types_default){
|
||||||
|
let event={checked:true}
|
||||||
|
this.default_toggle(event,element.pd_type_id,index,3)
|
||||||
|
}
|
||||||
|
});
|
||||||
|
delete res['records'].products_default
|
||||||
|
delete res['records'].customer_segments_default
|
||||||
|
delete res['records'].pd_types_default
|
||||||
|
console.log(this._otherPreferenceForm.value);
|
||||||
|
setTimeout(() => {
|
||||||
this._otherPreferenceForm.patchValue(res['records'])
|
this._otherPreferenceForm.patchValue(res['records'])
|
||||||
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -46,16 +79,22 @@ export class EntityOtherPreferenceComponent implements OnInit {
|
|||||||
this.entityService.getListOfProducts().subscribe(res=>{
|
this.entityService.getListOfProducts().subscribe(res=>{
|
||||||
if(res['dataStatus']){
|
if(res['dataStatus']){
|
||||||
this.productList=res['records']
|
this.productList=res['records']
|
||||||
|
this.initslidetoggle(1)
|
||||||
|
console.log(this._otherPreferenceForm.value);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.entityService.getListOfCustomerSegments().subscribe(res=>{
|
this.entityService.getListOfCustomerSegments().subscribe(res=>{
|
||||||
if(res['dataStatus']){
|
if(res['dataStatus']){
|
||||||
this.customerSegmentList=res['records']
|
this.customerSegmentList=res['records']
|
||||||
|
this.initslidetoggle(2)
|
||||||
|
console.log(this._otherPreferenceForm.value);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.entityService.getListOfPDAllocationTypes().subscribe(res=>{
|
this.entityService.getListOfPDAllocationTypes().subscribe(res=>{
|
||||||
if(res['dataStatus']){
|
if(res['dataStatus']){
|
||||||
this.pdTypeList=res['records'].pd_type
|
this.pdTypeList=res['records'].pd_type
|
||||||
|
this.initslidetoggle(3)
|
||||||
|
console.log(this._otherPreferenceForm.value);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -77,6 +116,8 @@ export class EntityOtherPreferenceComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
|
let array_name = option+'_default'
|
||||||
|
this.changeToogletoFalse(array_name)
|
||||||
this._otherPreferenceForm.controls[option].patchValue('')
|
this._otherPreferenceForm.controls[option].patchValue('')
|
||||||
this.selectedAll[option]=false
|
this.selectedAll[option]=false
|
||||||
}
|
}
|
||||||
@ -87,6 +128,25 @@ export class EntityOtherPreferenceComponent implements OnInit {
|
|||||||
console.log(this._otherPreferenceForm.value)
|
console.log(this._otherPreferenceForm.value)
|
||||||
let records=this._otherPreferenceForm.value
|
let records=this._otherPreferenceForm.value
|
||||||
records.fk_updatedby=this.users
|
records.fk_updatedby=this.users
|
||||||
|
records.products_default = records.products_default.filter(prod_filter =>prod_filter != false)
|
||||||
|
if(records.products_default.length > 0){
|
||||||
|
records.products_default=records.products_default[0]
|
||||||
|
}else{
|
||||||
|
records.products_default= null
|
||||||
|
}
|
||||||
|
records.customer_segments_default = records.customer_segments_default.filter(prod_filter =>prod_filter != false)
|
||||||
|
if(records.customer_segments_default.length > 0){
|
||||||
|
records.customer_segments_default=records.customer_segments_default[0]
|
||||||
|
}else{
|
||||||
|
records.customer_segments_default= null
|
||||||
|
}
|
||||||
|
records.pd_types_default = records.pd_types_default.filter(prod_filter =>prod_filter != false)
|
||||||
|
if(records.pd_types_default.length > 0){
|
||||||
|
records.pd_types_default=records.pd_types_default[0]
|
||||||
|
}else{
|
||||||
|
records.pd_types_default= null
|
||||||
|
}
|
||||||
|
console.log('records',records);
|
||||||
this.entityService.saveEntityOtherPreferences(records).subscribe(res=>{
|
this.entityService.saveEntityOtherPreferences(records).subscribe(res=>{
|
||||||
if(res['dataStatus']){
|
if(res['dataStatus']){
|
||||||
this.notifier.notify("success","Saved Successfully..!");
|
this.notifier.notify("success","Saved Successfully..!");
|
||||||
@ -97,5 +157,65 @@ export class EntityOtherPreferenceComponent implements OnInit {
|
|||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
default_toggle(event,prod_id,index,flag){
|
||||||
|
console.log(event.checked,prod_id,this._otherPreferenceForm.value.products_default,index)
|
||||||
|
if(flag == 1){
|
||||||
|
if(event.checked){
|
||||||
|
this.changeToogletoFalse('products_default')
|
||||||
|
const control=this._otherPreferenceForm.controls['products_default']['controls'][index]
|
||||||
|
control.setValue(prod_id)
|
||||||
|
console.log("set true",this._otherPreferenceForm.value.products_default)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(flag == 2){
|
||||||
|
if(event.checked){
|
||||||
|
this.changeToogletoFalse('customer_segments_default')
|
||||||
|
const control=this._otherPreferenceForm.controls['customer_segments_default']['controls'][index]
|
||||||
|
control.setValue(prod_id)
|
||||||
|
console.log("set true",this._otherPreferenceForm.value.customer_segments_default)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(flag == 3){
|
||||||
|
if(event.checked){
|
||||||
|
this.changeToogletoFalse('pd_types_default')
|
||||||
|
const control=this._otherPreferenceForm.controls['pd_types_default']['controls'][index]
|
||||||
|
control.setValue(prod_id)
|
||||||
|
console.log("set true",this._otherPreferenceForm.value.pd_types_default)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
changeToogletoFalse(array_name){
|
||||||
|
const control=this._otherPreferenceForm.controls[array_name]['controls']
|
||||||
|
console.log(control)
|
||||||
|
control.forEach((val,index)=>{
|
||||||
|
control[index].setValue(false)
|
||||||
|
})
|
||||||
|
console.log("set False",this._otherPreferenceForm.value[array_name])
|
||||||
|
}
|
||||||
|
initslidetoggle(flag){
|
||||||
|
if(flag == 1){
|
||||||
|
const formArray = this._otherPreferenceForm.get('products_default') as FormArray;
|
||||||
|
this.productList.forEach(x => formArray.push(new FormControl(false)));
|
||||||
|
}
|
||||||
|
if(flag == 2){
|
||||||
|
const formArray = this._otherPreferenceForm.get('customer_segments_default') as FormArray;
|
||||||
|
this.customerSegmentList.forEach(x => formArray.push(new FormControl(false)));
|
||||||
|
}
|
||||||
|
if(flag == 3){
|
||||||
|
const formArray = this._otherPreferenceForm.get('pd_types_default') as FormArray;
|
||||||
|
this.pdTypeList.forEach(x => formArray.push(new FormControl(false)));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
checkDisableToggle(select_value, curr_id){
|
||||||
|
// console.log("bvvvv",select_value,select_value.length > 0)
|
||||||
|
if(select_value.length > 0){
|
||||||
|
return select_value.filter(val=>val == curr_id).length == 0
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user