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 0b2e76ff2..28da9fe0a 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 @@ -6,6 +6,8 @@ import { NotifierService } from 'angular-notifier'; import { PdTrigerService } from '../../../pd-service/pd-triger.service'; import { ListPdComponent } from '../list-pd.component'; import { AwsService } from '../../../../AwsService/aws.service'; +/**sweet alert */ +import Swal from 'sweetalert2'; @Component({ selector: 'app-add-pd', templateUrl: './add-pd.component.html', @@ -486,11 +488,14 @@ export class AddPdComponent implements OnInit, OnDestroy { } } loadPdListCompoent(from:boolean) { + //alert(from); if(from){ + // alert('if'+from); this.router.navigate([ '../../' ], { relativeTo: this.route }); this.ListPdComponent.pdListLoad(true); } else{ + // alert(from); this.router.navigate([ '../../' ], { relativeTo: this.route }); this.ListPdComponent.showListView(true); } 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 544a5fbe7..1a890ce6e 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 @@ -17,30 +17,30 @@ PD Details --> - - - - Select - - - {{LL.full_name}} - - - - - + + + + Select + + + {{LL.full_name}} + + + - - - + + + + + - - + + Enter Valid Mobile Number. - + Enter Valid STD Code. @@ -49,7 +49,7 @@ Enter Valid Landline Number. - + Select @@ -61,7 +61,7 @@ - + Select @@ -74,7 +74,7 @@ - + Select @@ -83,7 +83,7 @@ - + Select @@ -94,7 +94,7 @@ - + {{"₹"}} {{loanAmtInWords}} Only @@ -106,7 +106,7 @@ - + Select @@ -118,7 +118,7 @@ - + Select diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.html index a9edd7186..429099f1f 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.html @@ -89,7 +89,7 @@ -
+
@@ -147,11 +147,11 @@
- + Yes No - +
@@ -196,22 +196,22 @@ - + - - - - - - {{"₹"}} {{premisesRentAmtInwords[i]}} Only - + diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.ts index e20af726d..aedb2ec08 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/address/address.component.ts @@ -37,7 +37,7 @@ export class AddressComponent implements OnInit { pdid : number; form_id: number; pdAddress: string; - + CustSegAbbr: any; loadDataStatus: boolean=true; PremisesOtherFlag:boolean; @@ -57,8 +57,8 @@ export class AddressComponent implements OnInit { formPremisesCityArray: any = []; additional_premises: any=[]; bussiness_address_type: any=[]; - premisesRentAmtInwords:any=[]; - rentAmtInwords:any; + // premisesRentAmtInwords:any=[]; + // rentAmtInwords:any; tempArr: any[]; placeholderName : any = 'Was any business activity seen at the Address Type during PD visit?'; //neighbourStatusData:any=["Yes","No"]; @@ -73,10 +73,10 @@ export class AddressComponent implements OnInit { public pdLocation: AbstractControl; public commentlocality: AbstractControl; public other_comment_locality: AbstractControl; - public customerBehaviour: AbstractControl; - public ownership: AbstractControl; - public other_ownership: AbstractControl; - public rent_amt : AbstractControl; + // public customerBehaviour: AbstractControl; + // public ownership: AbstractControl; + // public other_ownership: AbstractControl; + // public rent_amt : AbstractControl; public other_premises_bussiness_activity : AbstractControl; public bussiness_activity_remark: AbstractControl; public bussinessActivity: AbstractControl; @@ -88,10 +88,18 @@ export class AddressComponent implements OnInit { private route: ActivatedRoute, private router: Router, private _pd: PdTrigerService, + private dialogRef: MatDialogRef, @Inject(MAT_DIALOG_DATA) public pd_all_details: any) { + console.log(this.pd_all_details); this.pdid = this.pd_all_details.pdmaster_details.pd_id; this.form_id = 5; + // console.log(this.pd_all_details.template_forms.form_id); + // console.log(this.pd_all_details.pdmaster_details.customer_segment_abbr); + + let CSAbbrSearch = this.pd_all_details.pdmaster_details.customer_segment_abbr.search("-"); + this.CustSegAbbr = this.pd_all_details.pdmaster_details.customer_segment_abbr.substr(0,CSAbbrSearch); + this.notifier = notifier; this.pdAddress = this.pd_all_details.pdmaster_details.addressline1; } @@ -142,12 +150,12 @@ export class AddressComponent implements OnInit { this.addressForm.controls.locality_others.setValue(data.records.locality_others); } this.addressForm.controls.address_form_remark.setValue(data.records.address_form_remark); - this.addressForm.controls.address_ownership.setValue(data.records.address_ownership); - this.addressForm.controls.other_ownership.setValue(data.records.other_ownership); - this.addressForm.controls.rent_amt.setValue(data.records.rent_amt); - if(data.records.address_ownership == 3){ - this.rentAmtInwords = this._pd.convertNumberToWords(data.records.rent_amt); - } + // this.addressForm.controls.address_ownership.setValue(data.records.address_ownership); + // this.addressForm.controls.other_ownership.setValue(data.records.other_ownership); + // this.addressForm.controls.rent_amt.setValue(data.records.rent_amt); + // if(data.records.address_ownership == 3){ + // this.rentAmtInwords = this._pd.convertNumberToWords(data.records.rent_amt); + // } this.addressForm.controls.other_premises_bussiness_activity.setValue(data.records.other_premises_bussiness_activity); if(data.records.other_premises_bussiness_activity != '' && data.records.other_premises_bussiness_activity !=null) { this.addressForm.controls.bussiness_activity_remark.setValue(data.records.other_premises_bussiness_activity); @@ -172,7 +180,7 @@ export class AddressComponent implements OnInit { control.push(this.createUnits()); } else { resultOfUnits.forEach((datas,index) => { - this.premisesRentAmtInwords[index] = this._pd.convertNumberToWords(datas.premises_rent_amt); + // this.premisesRentAmtInwords[index] = this._pd.convertNumberToWords(datas.premises_rent_amt); control.push(this.createUnits()); }); this.addressForm.controls.additional_address_units.setValue(resultOfUnits); @@ -204,9 +212,9 @@ export class AddressComponent implements OnInit { //neighbourhood: this.fb.array([]), additional_address_units: this.fb.array([]), address_form_remark:[''], - address_ownership:[''], - other_ownership:[''], - rent_amt:[''], + // address_ownership:[''], + // other_ownership:[''], + // rent_amt:[''], other_premises_bussiness_activity : [''], bussiness_activity_remark:[''], bussiness_activity:[''], @@ -223,9 +231,9 @@ export class AddressComponent implements OnInit { this.commentlocality = this.addressForm.controls['comment_locality']; this.other_comment_locality = this.addressForm.controls['other_comment_locality']; //this.customerBehaviour = this.addressForm.controls['customer_behaviour']; - this.ownership = this.addressForm.controls['address_ownership']; - this.other_ownership = this.addressForm.controls['other_ownership']; - this.rent_amt = this.addressForm.controls['rent_amt']; + // this.ownership = this.addressForm.controls['address_ownership']; + // this.other_ownership = this.addressForm.controls['other_ownership']; + // this.rent_amt = this.addressForm.controls['rent_amt']; this.other_premises_bussiness_activity = this.addressForm.controls['other_premises_bussiness_activity'], this.bussiness_activity_remark = this.addressForm.controls['bussiness_activity_remark'], this.bussinessActivity = this.addressForm.controls['bussiness_activity']; @@ -248,9 +256,9 @@ export class AddressComponent implements OnInit { premises_type: [''], premises_type_others: [''], premises_city: [''], - premises_ownership: [''], - premises_ownership_others: [''], - premises_rent_amt:[''], + // premises_ownership: [''], + // premises_ownership_others: [''], + // premises_rent_amt:[''], premises_remarks: [''], }); } @@ -280,6 +288,9 @@ export class AddressComponent implements OnInit { this.localityData.push(val); } else if(type==5 && val.isactive == 1){ + if(this.CustSegAbbr == 'SENP' || this.CustSegAbbr == 'SEP'){ + val.filter(at => at.address_type != 'Residence' && at.address_type != 'Residence cum Office'); + } this.addressData.push(val); } else if(type==6 && val.isactive == 1){ @@ -335,10 +346,15 @@ export class AddressComponent implements OnInit { onSubmit() { if (!this.addressForm.valid) { - - return; + this.notifier.notify('warning', 'Please Fill All Mandatory Fields.!'); + return; } - + if(this.address.value.other_premises_bussiness_activity != ''){ + if(this.address.value.bussiness_activity_remark != ''){ + this.notifier.notify('warning', 'Fill Remark!'); + return; + }} + let records: any = {}; records.address = this.address.value; records.address_type = this.addressType.value; @@ -356,9 +372,9 @@ export class AddressComponent implements OnInit { //records.neighbourhood = this.addressForm.controls.neighbourhood.value; records.address_form_remark = this.addressForm.controls.address_form_remark.value; - records.address_ownership = this.ownership.value; - records.other_ownership = this.other_ownership.value; - records.rent_amt = this.rent_amt.value; + // records.address_ownership = this.ownership.value; + // records.other_ownership = this.other_ownership.value; + // records.rent_amt = this.rent_amt.value; records.other_premises_bussiness_activity = this.other_premises_bussiness_activity.value; records.bussiness_activity_remark = this.bussiness_activity_remark.value; records.bussiness_activity = this.bussinessActivity.value; @@ -376,9 +392,14 @@ export class AddressComponent implements OnInit { // console.log(JSON.stringify(records)); this._pd.saveForm(records).subscribe(data => { - - this.notifier.notify('success', 'Saved Successfully.'); - }, error => { + if(data.status == 200) { + this.notifier.notify('success', 'Saved Successfully.'); + this.dialogRef.close(); + } + else { + this.notifier.notify('warning', 'Something Wents Wrong Try Again.!'); + } + }, error => { this.notifier.notify('warning', 'Something Wents Wrong Try Again.!'); }); } @@ -420,11 +441,11 @@ export class AddressComponent implements OnInit { } } - inWords(e,i){ - this.premisesRentAmtInwords[i] = this._pd.convertNumberToWords(e.target.value); - } + // inWords(e,i){ + // this.premisesRentAmtInwords[i] = this._pd.convertNumberToWords(e.target.value); + // } - inWordsForRent(e){ - this.rentAmtInwords = this._pd.convertNumberToWords(e.target.value); - } + // inWordsForRent(e){ + // this.rentAmtInwords = this._pd.convertNumberToWords(e.target.value); + // } } \ No newline at end of file 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 4eb5a0372..712135efb 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 @@ -164,10 +164,10 @@ - + - {{"₹"}} {{amtInwords[i]}} Only + {{"₹"}} {{amtInwords[i]}} Only
- + - {{"₹"}} {{amtInwords[i]}} Only + {{"₹"}} {{amtInwords[i]}} Only - + {{freq.name}} @@ -50,10 +50,10 @@ - + - {{"₹"}} {{emiAmtInwords[i]}} Only + {{"₹"}} {{emiAmtInwords[i]}} Only @@ -103,14 +103,15 @@ - + + diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.scss b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.scss index 758b41c0c..720a1c506 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.scss +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.scss @@ -17,7 +17,9 @@ // background: #62B013; // color: white; // } - +.mat-form-field-appearance-legacy .mat-hint{ + color:rgba(0, 0, 0, 0.8) !important; +} .paragraph_change { color: #fff !important; background-color: #e00201 !important; diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts index 7a8abf7f9..832bc7286 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts @@ -88,7 +88,7 @@ export class CurrentLoanComponent implements OnInit { this.initCurrentloanForm(); this._pd.getCompaniesListsForBusiness(this.pdid).subscribe(data=>{ if(data.dataStatus){ - this.existCompanyList = data.records.filter(val =>val.is_active); + this.existCompanyList = data.records.filter(val =>val.is_active===true && val.is_company_applicant===true); } let modifyCompanyList : any=[]; diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.html index 07da3fb2a..57709ad99 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.html @@ -26,7 +26,7 @@ - + @@ -37,9 +37,21 @@
- - - + + + +
+
+ + + + + + + +
+
+ Yes @@ -91,7 +103,7 @@ - + diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.ts index 20d8ddad3..2e827388d 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/neighbour-hood/neighbour-hood.component.ts @@ -17,7 +17,7 @@ export class NeighbourHoodComponent implements OnInit { private notifier: NotifierService; check_type:any=[{'id':0,'type_name':'Neighbourhood'},{'id':1,'type_name':'Reference Check'}] default_reference_details: any= {'reference_name':'','mobile':'','landline':'-','location':'','relationship_with':'','year_relation_applicant':'','months_relation_applicant':'','business_volume_amount':'','business_volume_unit':'','reference_final_remarks':'','positive_remark':'','negative_remark':'','insufficient_info_remark':''}; - default_neighbourhood_details: any= {'neighbourhood_name':'','do_know':'','how_long_do_know':'','is_applicant_owner':''}; + default_neighbourhood_details: any= {'neighbourhood_name':'','do_know':'','how_long_do_know_in_year':'','how_long_do_know_in_month':'','is_applicant_owner':''}; busineesRelationshipList:any=[]; volumeunitList:any=[]; @@ -175,7 +175,8 @@ export class NeighbourHoodComponent implements OnInit { return this._fb.group({ neighbourhood_name: [elementValue.neighbourhood_name], do_know: [elementValue.do_know], - how_long_do_know: [elementValue.how_long_do_know], + how_long_do_know_in_year: [elementValue.how_long_do_know_in_year], + how_long_do_know_in_month: [elementValue.how_long_do_know_in_month], is_applicant_owner: [elementValue.is_applicant_owner], }); } @@ -219,7 +220,8 @@ export class NeighbourHoodComponent implements OnInit { neighbourhood_list.push({ "neighbourhood_name":element.neighbourhood_name, "do_know":element.do_know, - "how_long_do_know":element.how_long_do_know, + "how_long_do_know_in_year":element.how_long_do_know_in_year, + "how_long_do_know_month":element.how_long_do_know_month, "is_applicant_owner":element.is_applicant_owner, }) }); @@ -288,17 +290,23 @@ validateAllFormFields(formGroup: any) { } /** To Convert Month into Year */ - ConvertMonthintoYear(itemrow,e){ - // console.log(itemrow); - // console.log(e); - let year = itemrow.controls.year_relation_applicant.value; - - let converted_month : number = e%12; - let converted_year : number = e/12; + ConvertMonthintoYear(itemrow,e,flag){ + if(flag == 2){ - itemrow.controls.year_relation_applicant.setValue(+year + +Math.floor(converted_year)); - itemrow.controls.months_relation_applicant.setValue(Math.floor(converted_month)); - + let year = itemrow.controls.year_relation_applicant.value; + let converted_month : number = e%12; + let converted_year : number = e/12; + itemrow.controls.year_relation_applicant.setValue(+year + +Math.floor(converted_year)); + itemrow.controls.months_relation_applicant.setValue(Math.floor(converted_month)); + } + else if(flag == 1){ + + let year = itemrow.controls.how_long_do_know_in_year.value; + let converted_month : number = e%12; + let converted_year : number = e/12; + itemrow.controls.how_long_do_know_in_year.setValue(+year + +Math.floor(converted_year)); + itemrow.controls.how_long_do_know_in_month.setValue(Math.floor(converted_month)); + } } /** Amount InWords */ diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.html index 90b38fce9..e5c6df008 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.html @@ -20,7 +20,7 @@ - + Yes @@ -33,10 +33,10 @@

Income Details

-
- + {{src.name}} @@ -48,17 +48,17 @@ - + - + - {{"₹"}} {{amtInwords[i]}} Only + {{"₹"}} {{amtInwords[i]}} Only - + {{frq.name}} @@ -66,20 +66,18 @@ - + - - - +
@@ -234,7 +232,7 @@

Other Income Details

- + Yes diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.scss b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.scss index ddaefcfc8..5e2912012 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.scss +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/other-income/other-income.component.scss @@ -19,6 +19,9 @@ ::ng-deep .cdk-global-overlay-wrapper{ justify-content: center !important; } +.mat-form-field-appearance-legacy .mat-hint{ + color:rgba(0, 0, 0, 0.8) !important; +} .paragraph_change { color: #fff !important; background-color: #e00201 !important; diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html index 462acb1b9..579ec64a2 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html @@ -1,275 +1,289 @@ - - -
-
- - -
-

{{master.lender_short_name}}

- {{master.branch_name}} -
- {{master.lender_applicant_id}}
- {{master.pd_date_of_initiation}}
+ + +
+
+ + +
+

{{master.lender_short_name}}

+ {{master.branch_name}} +
+ {{master.lender_applicant_id}}
+ {{master.pd_date_of_initiation}}
+
+    +
-    - -
- {{master.pd_allocated_to | titlecase}} - {{master.executive_name | titlecase}}/{{master.centralofficer | titlecase}} - {{master.centralofficer | titlecase}}
- - {{master.scheduled_on}} + {{master.pd_allocated_to | titlecase}} + {{master.executive_name | titlecase}}/{{master.centralofficer | titlecase}} + {{master.centralofficer | titlecase}}
-
-
-
- -
-
-
- - -
-
- - - - - - - -
-
-
-
- -
-
-
-
-
-
- -
-
- {{master.product_name}} / {{master.subproduct_name}} -
-
-
-
-
-
- -
-
- {{master.loan_amount}} -
-
-
-
-
-
- -
-
- {{master.pd_type_name}} -
-
-
-
-
-
- -
-
- {{master.addressline1}},
{{master.city_name}},
{{master.state_name}}-{{master.pincode}}
-
-
-
- -
-
-
-

Lender Contact Details

- -
-
-   {{master.pd_contact_person}} -
-
-
-
-   {{master.pd_contact_mobileno}} -
-
-
-
-
-
-

Remarks

- - {{master.remarks}} -
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -

PD Details

- - - Applicants -
- -
- - Applicants - - - - - -

- -  {{applicant.applicant_name}} -     - - -  {{applicant.mobile_no}} -     - - -  {{applicant.landline}} - - ( Main Applicant ) - {{applicant.relation_name}} -

-
-
-
- - -

No Applicant

-
-
-
- - Additional Requirements -
- -
- - Additional Requirements - - - - -

{{requirement.add_requirement}}

-
-
-
- - -

No Additional Requirements

-
-
-
- - Documents -
- - - - {{documents.pd_document_title}} - - - + {{master.scheduled_on}} +
- - -

No Document

-
-
-
- - QC Notes -
-
QC Notes
-
-

- {{ pdMasterData[0]?.qc_remarks}}

- -
- - QC Remarks -
-
-
QC Remarks
-
-
-
-
- {{ pdMasterData[0]?.qc_rating}} -
-
- -
-
-
-
-
- {{ pdMasterData[0]?.qc_feedback}} -
-
-
- - PD History -
- - - {{master.time}}  - {{master.user}}
{{master.log}}
- -
- -
+
+
+ +
+
+
+ + +
+
+ + + + + + + +
+
+
+
+ +
+
+
+
+
+
+ +
+
+ {{master.product_name}} / {{master.subproduct_name}} +
+
+
+
+
+
+ +
+
+ {{master.loan_amount}} +
+
+
+
+
+
+ +
+
+ {{master.pd_type_name}} +
+
+
+
+
+
+ +
+
+ {{master.addressline1}},
{{master.city_name}},
{{master.state_name}}-{{master.pincode}}
+
+
+
+
- - -

No History

-
-
- - - - - +
+
+

Lender Contact Details

+ +
+
+   {{master.pd_contact_person}} +
+
+
+
+   {{master.pd_contact_mobileno}} +
+
+
+
+
+
+

Remarks

+ + {{master.remarks}} +
+
+
+
+ +
+
+
+
+
+
+
+
+
+
+ +

PD Details

+ + + Applicants + + +
+ Applicants +
+
+ +
+
+ + + +

+ +  {{applicant.applicant_name}} +     + + +  {{applicant.mobile_no}} +     + + +  {{applicant.landline}} + + ( Main Applicant ) + {{applicant.relation_name}} +

+
+
+
+ + +

No Applicant

+
+
+
+ + Additional Requirements + + + +
+ Additional Requirements +
+
+ +
+
+ + + +

{{requirement.add_requirement}}

+
+
+
+ + +

No Additional Requirements

+
+
+
+ + Documents + + + +

No Document

+
+
+
+ + QC Notes +
+
QC Notes
+
+

+ {{ pdMasterData[0]?.qc_remarks}}

+ +
+ + QC Remarks +
+
+
QC Remarks
+
+
+
+
+ {{ pdMasterData[0]?.qc_rating}} +
+
+ +
+
+
+
+
+ {{ pdMasterData[0]?.qc_feedback}} +
+
+
+ + PD History +
+ + + {{master.time}}  + {{master.user}}
{{master.log}}
+
+ +
+
+ + +

No History

+
+
+
+
+
+ + \ No newline at end of file diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.ts index a5182125c..ce1e56fd8 100755 --- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.ts +++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.ts @@ -30,6 +30,59 @@ export class ViewPdComponent implements OnInit, OnDestroy { masterPdLogsData: any=[]; applicantPDLogsData: any=[]; pdAdditionalReqData: any=[]; + FilteredFieldNames : any=[]; + localcount :any; + localstring : any; + localMandatoryFields: any= + [ {'backEnd_FieldName':"fk_lender_id",'frontEnd_FieldName':"Lender Name"}, + {'backEnd_FieldName':"lender_applicant_id",'frontEnd_FieldName':"Loan Applicant ID"}, + {'backEnd_FieldName':"fk_product_id",'frontEnd_FieldName':"Product Name"}, + {'backEnd_FieldName':"fk_subproduct_id",'frontEnd_FieldName':"Sub Product Name"}, + {'backEnd_FieldName':"fk_pd_type",'frontEnd_FieldName':"PD Type"}, + {'backEnd_FieldName':"fk_customer_segment",'frontEnd_FieldName':"Customer Segment"}, + {'backEnd_FieldName':"loan_amount",'frontEnd_FieldName':"Loan Amount"}, + {'backEnd_FieldName':"addressline1",'frontEnd_FieldName':"Address at which PD is to be done"}, + {'backEnd_FieldName':"fk_city",'frontEnd_FieldName':"City"}, + {'backEnd_FieldName':"fk_state",'frontEnd_FieldName':"State"}, + {'backEnd_FieldName':"pincode",'frontEnd_FieldName':"Pincode"}, + {'backEnd_FieldName':"pd_contact_person",'frontEnd_FieldName':"Lender Contact Person"}, + {'backEnd_FieldName':"pd_contact_mobileno",'frontEnd_FieldName':"Lender's Mobile Number"}, + {'backEnd_FieldName':"pd_branch_id",'frontEnd_FieldName':"Branch"}, + {'backEnd_FieldName':"pd_contact_landline",'frontEnd_FieldName':"Lender's Landline Number"}]; + // localMandatoryFields: any= + // ['fk_lender_id', + // 'lender_applicant_id', + // 'fk_product_id', + // 'fk_subproduct_id', + // 'fk_pd_type', + // 'fk_customer_segment', + // 'loan_amount', + // 'addressline1', + // 'fk_city', + // 'fk_state', + // 'pincode', + // 'pd_contact_person', + // 'pd_contact_mobileno', + // 'pd_branch_id', + // 'pd_contact_landline']; + + // localMandatoryFields2: any= + // [ "Lender Name", + // "Loan Applicant ID", + // "Product Name", + // "Sub Product Name", + // "PD Type", + // "Customer Segment", + // "Loan Amount", + // "Address at which PD is to be done", + // "City", + // "State", + // "Pincode", + // "Lender Contact Person", + // "Lender's Mobile Number", + // "Branch", + // "Lender's Landline Number"]; + viewID:string; viewParams:any; destroyType:number=1; @@ -119,9 +172,18 @@ export class ViewPdComponent implements OnInit, OnDestroy { width: '80%', disableClose: true }); - dialogPDMaster.afterClosed() - .subscribe(dataresult => { - // this.notifier.notify('success', 'Successfully allocated.!'); + dialogPDMaster.afterOpen() + .subscribe(dataresult => { + if(this.localcount == 1){ + let ffd : any = []; + this.FilteredFieldNames.forEach(field => { + ffd.push(field.frontEnd_FieldName); + }); + this.notifier.notify('info', 'Please Fill ' + ffd.join(',') + ' are Fields.!'); + } + }); + dialogPDMaster.afterClosed().subscribe(dataresult => { + this.viewPdDetails(this.viewID) }); } @@ -233,9 +295,26 @@ export class ViewPdComponent implements OnInit, OnDestroy { } // direct trigger the pd - directTriggerPD(data: any,pdid:string){ + directTriggerPD(data: any,masterdetail : any){ +/** */ +let pdid = masterdetail.pd_id; +let getValues = data.filter(val =>val).map(Val => Val); +this.FilteredFieldNames = getValues.map(x => { + let findIndex = this.localMandatoryFields.map(val => val.backEnd_FieldName).indexOf(x); + return this.localMandatoryFields[findIndex]; +}); + + + if(data.length>0){ - this.notifier.notify('warning', 'Please Fill All Mandatory Fields.!'); + + // FilteredFieldNames.forEach(field => { + + // }); + this.localcount = 1; + this.editPdMaster(masterdetail); + + // alert(this.localMandatoryFields); } else { let lenderMasterArray = { @@ -276,4 +355,4 @@ export class ViewPdComponent implements OnInit, OnDestroy { } -} +} \ No newline at end of file