diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html index feb18d92e..08dd1d9fc 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html @@ -34,7 +34,7 @@ - + @@ -75,7 +75,7 @@ - + Select @@ -85,7 +85,7 @@ - + diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts index c49bb1a04..e31e4ffe5 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts @@ -50,6 +50,7 @@ export class AddPdComponent implements OnInit, OnDestroy { dynamicCoApplicant = []; disableAfterSubmit: boolean; pincodeflag : any = []; + isSubproductShown: boolean = true; constructor(notifier: NotifierService, private _fb: FormBuilder, private route: ActivatedRoute, private router: Router, private _pd: PdTrigerService, private _aws: AwsService, private ListPdComponent: ListPdComponent, private titleCase : TitleCasePipe) { @@ -117,7 +118,7 @@ export class AddPdComponent implements OnInit, OnDestroy { this.lenderShortName = lender['short_name']; this._PDtriggerForm.controls.pd_branch_id.setValue(null); - if(this.lenderShortName = 'CLIX'){ + if(this.lenderShortName == 'CLIX'){ let getProductAbbr = this.productAllList.map(dval => dval.product_abbr); let ClixProductAbbr = ['BL','LAEP']; @@ -127,7 +128,6 @@ export class AddPdComponent implements OnInit, OnDestroy { return this.productAllList[findIndex]; }); this.productList = FilteredAbbr.length > 0 ? FilteredAbbr : this.productAllList; - } else{ this.productList = this.productAllList; @@ -138,7 +138,7 @@ export class AddPdComponent implements OnInit, OnDestroy { console.log(this.productList); - console.log('this.productList',this.productList); + console.log('this.productList',this.productList); this._PDtriggerForm.controls['fk_product_id'].setValue(''); this._PDtriggerForm.controls['fk_subproduct_id'].setValue(''); this._PDtriggerForm.controls['fk_pd_type'].setValue(''); @@ -201,29 +201,51 @@ export class AddPdComponent implements OnInit, OnDestroy { //get sub product list based on prokduct id getSubproductList(productID: string) { - // console.log('productID',productID); - this.subProductList = this.productList.filter(item => item.product_id == productID); - this.subProductList = this.subProductList[0].subproducts; - this.subProductList = this.subProductList.filter(item => item.is_others == 0); - let productabbr : any = this.productAllList.filter(item => item.product_id == productID)[0].abbr; - console.log('productabbr',productabbr); - if(this.lenderShortName == 'CLIX'){ - let tempdata = this.subProductList.filter(item => item.subproduct_name == 'Not Applicable'); - this._PDtriggerForm.controls['fk_subproduct_id'].setValue(tempdata[0].subproduct_id); + let productabbr : any; + if(productID !== undefined && productID !== null && productID !== '') { + this.subProductList = this.productList.filter(item => item.product_id == productID); + this.subProductList = this.subProductList[0].subproducts; + this.subProductList = this.subProductList.filter(item => item.is_others == 0); + productabbr = this.productAllList.filter(item => item.product_id == productID)[0].abbr; + + } + else{ + productabbr = '' + this.subProductList = []; + this._PDtriggerForm.controls['fk_subproduct_id'].setValue(''); + this._PDtriggerForm.controls['fk_pd_type'].setValue(''); + this._PDtriggerForm.controls['fk_customer_segment'].setValue(''); + this._PDtriggerForm.controls['loan_amount'].setValue(''); + } + + /**customer segment */ + switch(productabbr){ + case 'BL' : + console.log(1); + this.customerSegmentList = this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); + this._PDtriggerForm.controls['fk_subproduct_id'].setValue(null); + this.isSubproductShown = false; + break; + case 'LAEP': + console.log(2); + this.customerSegmentList = this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); + this._PDtriggerForm.controls['fk_subproduct_id'].setValue(null); + this.isSubproductShown = false; + break; + default: + console.log(3); + this.customerSegmentList = this.customerSegmentAllList; + this.isSubproductShown = true; + break; + } + + if(this.lenderShortName == 'CLIX' && productabbr != ''){ this._PDtriggerForm.controls['fk_pd_type'].setValue('1'); - // this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')) - // console.log('this.customerSegmentAllList',this.customerSegmentAllList); this._PDtriggerForm.controls['fk_customer_segment'].setValue('5'); this._PDtriggerForm.controls['loan_amount'].setValue(0); } - else{ - - if(productabbr != 'BL'){this._PDtriggerForm.controls['fk_subproduct_id'].setValue(null)} - } - - this.customerSegmentList = (productabbr != 'BL' && productabbr != 'LAEP' )?this.customerSegmentAllList:this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); - } + //get city list details based on state id diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html index dd12716fe..01a01b3ed 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html @@ -75,7 +75,7 @@ + (selectionChange)="getSubproductList(pdMain.fk_product_id.value,2)"> Select @@ -87,7 +87,7 @@ - + Select diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts index 6514dd4f7..f526b8790 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts @@ -54,6 +54,8 @@ export class EditPdMasterComponent implements OnInit { "QC_COMPLETED" :'QC_COMPLETED', }; lenderShortName: any; + isSubproductShown: boolean = true; + productShortName : any; constructor(private _fb: FormBuilder, private _pd: PdTrigerService, notifier: NotifierService,private dialogRef: MatDialogRef, @Inject(MAT_DIALOG_DATA) public data: any,private titleCase : TitleCasePipe) { @@ -149,7 +151,7 @@ export class EditPdMasterComponent implements OnInit { // this.productList=data.records this.productAllList = data.records if(this.data.records.fk_product_id){ - this.getSubproductList(this.data.records.fk_product_id); + this.getSubproductList(this.data.records.fk_product_id,1); } } }, error => this.errorMessage = error); @@ -267,28 +269,45 @@ export class EditPdMasterComponent implements OnInit { get pdMain() { return this._EditPDtriggerForm.controls; } //get sub product list based on prokduct id - getSubproductList(productID:string){ + getSubproductList(productID:string,flag:number){ + console.log('productID',productID); this.customerSegmentList=this.customerSegmentAllList; - let productabbr : any = this.productAllList.filter(item => item.product_id == productID)[0].abbr; - if(this.lenderShortName == 'CLIX'){ - this.customerSegmentList = (productabbr != 'BL' && productabbr != 'LAEP' )?this.customerSegmentAllList:this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); - let tempdata = this.subProductList.filter(item => item.subproduct_name == 'Not Applicable'); - // this._EditPDtriggerForm.controls['fk_subproduct_id'].setValue(tempdata[0].subproduct_id); - // this._EditPDtriggerForm.controls['fk_pd_type'].setValue('1'); - // this._EditPDtriggerForm.controls['fk_customer_segment'].setValue('5'); - // this._EditPDtriggerForm.controls['loan_amount'].setValue(0); - }else{ - // if(productID != '4'){ - if(productabbr == 'BL'){ - this.subProductList= this.productList.filter(item => item.product_id == productID); + + + if (productID !== undefined && productID !== null && productID !== '') { + this.productShortName = this.productAllList.filter(item => item.product_id == productID)[0].product_abbr; + this.subProductList=this.productAllList.filter(item => item.product_id == productID); this.subProductList=this.subProductList[0].subproducts; } - // if(productID == '4'){ - if(productabbr == 'BL'){ - let filtered = this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); - this.customerSegmentList = filtered; - } - } + else { + this.productShortName = ''; + this.subProductList=[]; + } + // console.log('this.productAbbr',this.productShortName); + switch (this.productShortName) { + case 'BL': + console.log(1); + this.customerSegmentList = this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); + if(this.lenderShortName == 'CLIX' && flag==2 ){ this._EditPDtriggerForm.controls['fk_customer_segment'].setValue('5'); } + this._EditPDtriggerForm.controls['fk_subproduct_id'].setValue(null); + this.subProductList=[]; + this.isSubproductShown = false; + break; + case 'LAEP': + console.log(2); + this.customerSegmentList = this.customerSegmentAllList.filter(s => (s.customer_segment).includes('Self')); + this._EditPDtriggerForm.controls['fk_subproduct_id'].setValue(null); + if(this.lenderShortName == 'CLIX' && flag==2 ){ this._EditPDtriggerForm.controls['fk_customer_segment'].setValue('5'); } + this.subProductList=[]; + this.isSubproductShown = false; + break; + default: + console.log(3); + this.customerSegmentList = this.customerSegmentAllList; + console.log('productID', productID); + this.isSubproductShown = true; + break; + } } // //get city list details based on state id // getCityList(stateID:string){ @@ -420,7 +439,7 @@ export class EditPdMasterComponent implements OnInit { // this is for clear custom validator required fields clearCustomValidatorFields(){ - console.log('functionclicked 2'); + this._EditPDtriggerForm.controls['fk_lender_id'].clearValidators(); this._EditPDtriggerForm.controls['fk_lender_id'].updateValueAndValidity(); @@ -455,7 +474,6 @@ export class EditPdMasterComponent implements OnInit { } submitPdDetails(formValue: any, status:any) { - console.log('functionclicked 3'); // let updateStatus = this.currentPDStatus == this.pdStatusCheck.DRAFT ? status : this.currentPDStatus == this.pdStatusCheck.TRIGGERED ? status : this.currentPDStatus; let updateStatus = this.currentPDStatus; @@ -466,9 +484,34 @@ export class EditPdMasterComponent implements OnInit { return; } } - + + if(this.lenderShortName == 'CLIX'){ + const control = this._EditPDtriggerForm.controls['addresses']; + let CtrlLength = control.controls.length; + if (CtrlLength > 0) { + let cnt = 0; + while (cnt < CtrlLength) { + + let ChildCtrl: any = control.controls[cnt] + ChildCtrl.controls['addressline1'].setValidators([Validators.required]); + ChildCtrl.controls['addressline1'].updateValueAndValidity(); + cnt++; + } + + this._EditPDtriggerForm.controls['fk_product_id'].setValidators([Validators.required]); + this._EditPDtriggerForm.controls['fk_product_id'].updateValueAndValidity(); + + this._EditPDtriggerForm.controls['pd_branch_id'].setValidators([Validators.required]); + this._EditPDtriggerForm.controls['pd_branch_id'].updateValueAndValidity(); + + this._EditPDtriggerForm.controls['pd_contact_person'].setValidators([Validators.required]); + this._EditPDtriggerForm.controls['pd_contact_person'].updateValueAndValidity(); + + this._EditPDtriggerForm.controls['pd_contact_mobileno'].setValidators([Validators.required]); + this._EditPDtriggerForm.controls['pd_contact_mobileno'].updateValueAndValidity(); + this._EditPDtriggerForm.controls['fk_pd_type'].clearValidators(); this._EditPDtriggerForm.controls['fk_pd_type'].updateValueAndValidity(); @@ -478,7 +521,14 @@ export class EditPdMasterComponent implements OnInit { this._EditPDtriggerForm.controls['loan_amount'].clearValidators(); this._EditPDtriggerForm.controls['loan_amount'].updateValueAndValidity(); + if(this._EditPDtriggerForm.invalid) { + this.validateAllFormFields(this._EditPDtriggerForm); + this.notifier.notify('warning', 'Please Fill All Mandatory Fields.!'); + return; + } + } } + return; let my_array = this._EditPDtriggerForm.value; let concat_landline if(my_array.lender_stdcode != null && my_array.lender_landline != null){ diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.html index c1f933928..2c725c133 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.html @@ -98,7 +98,7 @@ - @@ -109,7 +109,7 @@ - Applicant Name Required diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-banking-details/business-banking-details.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-banking-details/business-banking-details.component.html index 5d5034884..9f4a99856 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-banking-details/business-banking-details.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-banking-details/business-banking-details.component.html @@ -31,7 +31,7 @@ --> - @@ -42,7 +42,7 @@ - Applicant Name Required diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info-group/business-info-group.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info-group/business-info-group.component.ts index 474acd71e..a8f8836d3 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info-group/business-info-group.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info-group/business-info-group.component.ts @@ -13,6 +13,7 @@ import { BusinessAssetsInfoComponent } from './../../forms/business-assets-info/ import { BusinessBankingDetailsComponent } from './../../forms/business-banking-details/business-banking-details.component'; import { GetAnswerableFormsPipe } from './../../../../../pd-pipes/get-answerable-forms.pipe'; import {AssessedIncomeComponent} from './../assessed-income/assessed-income.component'; +import { FuturePlansAndBusinessEnvironmentComponent } from './../../forms/future-plans-and-business-environment/future-plans-and-business-environment.component'; @Component({ selector: 'app-business-info-group', @@ -30,6 +31,9 @@ export class BusinessInfoGroupComponent implements OnInit { pdid: number; form_id: number; waitLoading:boolean; + lender_short_name :any; + product_abbr :any; + constructor(notifier: NotifierService, private route: ActivatedRoute, private router: Router, @@ -42,6 +46,9 @@ export class BusinessInfoGroupComponent implements OnInit { 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.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.product_abbr = this.pd_all_details.pdmaster_details.product_abbr; + } ngOnInit() { @@ -189,6 +196,20 @@ export class BusinessInfoGroupComponent implements OnInit { .subscribe(dataresult => { this.getCompanyListForBusiness(); }); + }else + if((this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP') && details.form_id==23){ + const dialogRef = this.dialog.open(FuturePlansAndBusinessEnvironmentComponent, { + data: this.pd_all_details, + maxWidth: '100vw', + maxHeight: '100vh', + height: '100%', + width: '100%', + disableClose: true + }); + dialogRef.afterClosed() + .subscribe(dataresult => { + this.getCompanyListForBusiness(); + }); } } diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/future-plans-and-business-environment/future-plans-and-business-environment.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/future-plans-and-business-environment/future-plans-and-business-environment.component.ts index 322c6bc2d..6554c1978 100644 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/future-plans-and-business-environment/future-plans-and-business-environment.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/future-plans-and-business-environment/future-plans-and-business-environment.component.ts @@ -44,7 +44,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit { parent_pdid: string; pdid: string; form_id: number; - + company_id: any; public _futurePlansForm: FormGroup; public submitted = false; @@ -63,6 +63,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit { this.parent_pdid = this.pd_all_details.pdmaster_details.parent_pd_id; this.pdid = this.pd_all_details.pdmaster_details.pd_id; this.form_id = 23; + this.company_id =this.pd_all_details.company_id; this.notifier = notifier; this.main_applicant = this.pd_all_details.pdmaster_details.main_applicant; @@ -118,6 +119,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit { params.parent_pdid=this.parent_pdid; params.pd_id = this.pdid; params.pd_form_id = '23'; + params.company_id = this.company_id; this.pdTrigerService.getPDFormDetailsWithID(params).subscribe(data => { if (data.dataStatus) { this._futurePlansForm.controls.usp_of_the_business.setValue(data.records.usp_of_the_business); @@ -137,8 +139,8 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit { }) - this.pdTrigerService.retriveFile(this.pdid,params.pd_form_id,null).subscribe(data => { - if (data.status == 230) { + this.pdTrigerService.retriveFile(this.pdid,params.pd_form_id,this.company_id).subscribe(data => { + if (data.status == 200) { if(data.records.length>0){ data.records.forEach((val, index) => { let splitted = val.pd_document_name.split("."); diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/general-info/general-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/general-info/general-info.component.ts index 6772213da..64d8fa5a6 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/general-info/general-info.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/general-info/general-info.component.ts @@ -228,9 +228,9 @@ export class GeneralInfoComponent implements OnInit { return data.records.persons_with_relationships[key]; }); if (exist_personsWithRelationships.length > 0) { - exist_personsWithRelationships.forEach(element => { + exist_personsWithRelationships.forEach((element, index) => { //individualsControl.push(this.createIndividulas(element)) - personsWithRelationshipsControl.push(this.createPersonsWithRelationships(element)); + personsWithRelationshipsControl.push(this.createPersonsWithRelationships(element,index)); }); } if (this.customer_segment_abbr != 'SE-RI') { @@ -315,7 +315,7 @@ export class GeneralInfoComponent implements OnInit { element.qualification = '', element.course_name = '', individualsControl.push(this.createIndividulas(element)); - personsWithRelationshipsControl.push(this.createPersonsWithRelationships(element)); + personsWithRelationshipsControl.push(this.createPersonsWithRelationships(element,key)); //let relationControl = this._generalForm.controls['applicant_relation']; // let applicant_details: any= {'pd_co_applicant_id':element.pd_co_applicant_id,'applicant_name':element.applicant_name, 'individula_order_id':relationControl.controls.length+1}; @@ -365,11 +365,11 @@ export class GeneralInfoComponent implements OnInit { }); } - createPersonsWithRelationships(elementValue: any) { + createPersonsWithRelationships(elementValue: any,indexVal:number) { return this._fb.group({ pd_co_applicant_id: [elementValue.pd_co_applicant_id], applicant_name: [this.titleCase.transform(elementValue.applicant_name)], - relationship: [elementValue.relationship], + relationship: [indexVal === 0 ? '0' : elementValue.relationship], relation_to: [elementValue.relation_to], individuals_order_id: [elementValue.individuals_order_id], is_active: [elementValue.is_active] @@ -543,8 +543,7 @@ export class GeneralInfoComponent implements OnInit { individualsControl.push(this.createIndividulas(element)); let relationControl = this._generalForm.controls['persons_with_relationships']; let applicant_details: any = { 'pd_co_applicant_id': element.pd_co_applicant_id, 'applicant_name': this.titleCase.transform(element.applicant_name), 'relationship': '', 'relation_to': '', 'individuals_order_id': element.individuals_order_id, 'is_active': element.is_active }; - relationControl.push(this.createPersonsWithRelationships(applicant_details)); - + relationControl.push(this.createPersonsWithRelationships(applicant_details,individualsControl.controls.length-1)); }); } @@ -613,7 +612,6 @@ export class GeneralInfoComponent implements OnInit { updatePersonalRelation(indexVal) { let control: any = this._generalForm.controls['persons_with_relationships']; control.controls[indexVal].value.relationship == 0 ? control.controls[indexVal].controls['relation_to'].setValue('') : control.controls[indexVal].controls['relation_to'].setValue(control.controls[indexVal].value.relation_to); - } // update company relation updateCompanyRelation(indexVal) { diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html index f6e28f0e3..76e39fa81 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html @@ -63,7 +63,7 @@ formControlName="is_there_total_fund"> Select Yes, Disclosed - No,not Disclosed + No, Not Disclosed diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts index c07f2b9e1..508b8626a 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts @@ -29,7 +29,6 @@ import {BusinessInfoGroupComponent } from './forms/business-info-group/business- import {BusinessAssetsInfoComponent } from './forms/business-assets-info/business-assets-info.component'; import {PdStatusChangeDialogueComponent } from './../pd-status-change-dialogue/pd-status-change-dialogue.component'; import {RentalVerificationComponent} from './forms/rental-verification/rental-verification.component'; -import {FuturePlansAndBusinessEnvironmentComponent} from './forms/future-plans-and-business-environment/future-plans-and-business-environment.component'; @Component({ selector: 'app-start-pd', @@ -45,8 +44,7 @@ export class StartPdComponent implements OnInit, OnDestroy { categoryList: any = []; pdMasterList: any = []; pdFullDetails:any=[]; - lender_short_name :any; - product_abbr :any; + // category static form buttons categoryFormButtons: any; formsCategoryEnable: boolean = false; @@ -108,8 +106,6 @@ export class StartPdComponent implements OnInit, OnDestroy { data => { if (data.status == 200) { this.pdMasterList=data.records.pdmaster_details; - this.lender_short_name = data.records.pdmaster_details.lender_short_name; - this.product_abbr = data.records.pdmaster_details.product_abbr; // this.categoryList=data.records.question_answers; let filterApplicantName= data.records.pdapplicants_detials.filter(item => item.applicant_type == 1); this.mainApplicantName = filterApplicantName.length > 0 ? filterApplicantName[0].applicant_name : ''; @@ -483,23 +479,7 @@ export class StartPdComponent implements OnInit, OnDestroy { // this.notifier.notify('success', 'Successfully allocated.!'); this.loadTemplates(this.startPD,2); }); - }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); - }); } - - } ngOnDestroy(): void {