Fairoj: reusable component for docs in all forms, delete img facility, current loan changes, page break implemented and some minor changes are done
This commit is contained in:
parent
b9351e1076
commit
13bbd7bd9f
@ -86,7 +86,7 @@
|
||||
"fileReplacements": [
|
||||
{
|
||||
"replace": "src/environments/environment.ts",
|
||||
"with": "src/environments/environment.prod.ts"
|
||||
"with": "src/environments/environment.stage.ts"
|
||||
}]
|
||||
}
|
||||
}
|
||||
|
||||
@ -60,28 +60,28 @@
|
||||
</mat-form-field><br/>
|
||||
<!-- </div> -->
|
||||
|
||||
<mat-form-field style="width: 28%">
|
||||
<!-- <mat-form-field style="width: 28%">
|
||||
<input matInput autocomplete="off" placeholder="Lender Contact Person" formControlName="lender_contact_person" type="text" >
|
||||
<!-- <mat-error *ngIf="pdMain.lender_contact_person.hasError('required')">Lender Contact Person Required</mat-error> -->
|
||||
<mat-error *ngIf="pdMain.lender_contact_person.hasError('required')">Lender Contact Person Required</mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 28%">
|
||||
<input matInput autocomplete="off" placeholder="Lender's Mobile Number" formControlName="lender_contact_mobile" type="text" ForMobileNumbers maxlength="10" minlength="10">
|
||||
<mat-error *ngIf="pdMain.lender_contact_mobile.hasError('maxlength') || pdMain.lender_contact_mobile.hasError('minlength')">Enter Valid Mobile Number. </mat-error>
|
||||
</mat-form-field>
|
||||
</mat-form-field> -->
|
||||
|
||||
<!--<mat-form-field style="width: 32%">
|
||||
<input matInput autocomplete="off" placeholder="Lender Contact Number" formControlName="lender_contact_mobile" type="text" OnlyNumber maxlength="10" required>
|
||||
<mat-error *ngIf="pdMain.lender_contact_mobile.hasError('pattern') || pdMain.lender_contact_mobile.hasError('maxlength') || pdMain.lender_contact_mobile.hasError('minlength')">Enter Valid Mobile Number. </mat-error>
|
||||
</mat-form-field>-->
|
||||
|
||||
<mat-form-field style="width: 8%">
|
||||
<!-- <mat-form-field style="width: 8%">
|
||||
<input matInput autocomplete="off" placeholder="STD Code" formControlName="lender_stdcode" type="text" maxlength="5" ForMobileNumbers>
|
||||
<mat-error *ngIf="pdMain.lender_stdcode.hasError('maxlength') || pdMain.lender_stdcode.hasError('minlength')">Enter Valid STD Code Number.</mat-error>
|
||||
</mat-form-field> -
|
||||
<mat-form-field style="width: 17%">
|
||||
<input matInput autocomplete="off" placeholder="Landline Number" formControlName="lender_landline" type="text" maxlength="8" ForMobileNumbers>
|
||||
<mat-error *ngIf="pdMain.lender_landline.hasError('maxlength') || pdMain.lender_landline.hasError('minlength')">Enter Valid LandLine Number. </mat-error>
|
||||
</mat-form-field>
|
||||
</mat-form-field> -->
|
||||
|
||||
<mat-form-field style="width: 28%">
|
||||
<mat-select placeholder="Product Name" formControlName="fk_product_id" (selectionChange)="getSubproductList(pdMain.fk_product_id.value)">
|
||||
@ -109,7 +109,7 @@
|
||||
</mat-form-field>
|
||||
<!-- {{customerSegmentList | json}} -->
|
||||
<mat-form-field style="width: 28%">
|
||||
<mat-select placeholder="Customer Segment" formControlName="fk_customer_segment">
|
||||
<mat-select placeholder="Customer Segment" formControlName="fk_customer_segment" (selectionChange)="customerSegmentChange($event.value)">
|
||||
<mat-option>
|
||||
Select
|
||||
</mat-option>
|
||||
@ -225,7 +225,7 @@
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field style="width: 38%" *ngIf="pdMain.fk_customer_segment.value != '8'">
|
||||
<input matInput autocomplete="off" placeholder="Company / Firm Name" formControlName="company_name" type="text">
|
||||
<input matInput autocomplete="off" [placeholder]="selected_cus_abbr == 'SEP_INDV' ? 'Nature of Service' : 'Company / Firm Name'" formControlName="company_name" type="text">
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field style="width: 38%">
|
||||
|
||||
@ -55,6 +55,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
sales_and_credit_person:any=[]
|
||||
sales_and_credit_enable:boolean=false;
|
||||
finInstitutionList: any;
|
||||
selected_cus_abbr: any;
|
||||
constructor(notifier: NotifierService, private _fb: FormBuilder, private route: ActivatedRoute,
|
||||
private router: Router, private _pd: PdTrigerService, private _aws: AwsService, private ListPdComponent: ListPdComponent,
|
||||
private titleCase : TitleCasePipe) {
|
||||
@ -106,12 +107,12 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
pd_branch_id: [null],
|
||||
lender_applicant_id: [null, Validators.compose([Validators.required])],
|
||||
lender_sales_person:[null],
|
||||
lender_credit_person:[null],
|
||||
lender_credit_person:[null,Validators.compose([Validators.required])],
|
||||
imgc_fin_institute:[null],
|
||||
lender_contact_person: [null],
|
||||
lender_contact_mobile: [null, Validators.compose([Validators.minLength(10), Validators.maxLength(12), Validators.pattern('^[0-9]*$')])],
|
||||
lender_stdcode: [null, Validators.compose([Validators.minLength(3), Validators.maxLength(5), Validators.pattern('^[0-9]*$')])],
|
||||
lender_landline: [null, Validators.compose([Validators.minLength(6), Validators.maxLength(8), Validators.pattern('^[0-9]*$')])],
|
||||
// lender_contact_person: [null],
|
||||
// lender_contact_mobile: [null, Validators.compose([Validators.minLength(10), Validators.maxLength(12), Validators.pattern('^[0-9]*$')])],
|
||||
// lender_stdcode: [null, Validators.compose([Validators.minLength(3), Validators.maxLength(5), Validators.pattern('^[0-9]*$')])],
|
||||
// lender_landline: [null, Validators.compose([Validators.minLength(6), Validators.maxLength(8), Validators.pattern('^[0-9]*$')])],
|
||||
//lender_billing: [null],
|
||||
fk_product_id: [null],
|
||||
fk_subproduct_id: [null],
|
||||
@ -524,7 +525,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
// this._PDtriggerForm.controls['pincode'].setValidators([Validators.required]);
|
||||
// this._PDtriggerForm.controls['pincode'].updateValueAndValidity();
|
||||
setTimeout(() => {
|
||||
this.clearCustomValidatorFields();
|
||||
//this.clearCustomValidatorFields();
|
||||
}, 10000);
|
||||
this.submitPdDetails(formValue, status);
|
||||
}
|
||||
@ -594,9 +595,9 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
this.notifier.notify('warning', 'Please Fill All Mandatory Fields.!');
|
||||
return;
|
||||
}
|
||||
if((this._PDtriggerForm.value.lender_contact_person == '' || this._PDtriggerForm.value.lender_contact_person == null) && (this._PDtriggerForm.value.lender_credit_person== '' || this._PDtriggerForm.value.lender_credit_person == null)){
|
||||
this.notifier.notify("warning","Either Lender contact person or Lender credit person Need..!");
|
||||
}
|
||||
// if((this._PDtriggerForm.value.lender_contact_person == '' || this._PDtriggerForm.value.lender_contact_person == null) && (this._PDtriggerForm.value.lender_credit_person== '' || this._PDtriggerForm.value.lender_credit_person == null)){
|
||||
// this.notifier.notify("warning","Either Lender contact person or Lender credit person Need..!");
|
||||
// }
|
||||
else {
|
||||
|
||||
// if ((formValue.lender_contact_mobile == '' || formValue.lender_contact_mobile == null) && (formValue.lender_stdcode == '' || formValue.lender_stdcode == null && formValue.lender_landline == '' || formValue.lender_landline == null) && !this.sales_and_credit_enable) {
|
||||
@ -614,18 +615,18 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
let lender_landline_no;
|
||||
let applicant_landline_no;
|
||||
|
||||
if(!formValue.lender_stdcode || !formValue.lender_landline){
|
||||
lender_landline_no = null;
|
||||
}
|
||||
else if(!formValue.lender_stdcode && !formValue.lender_landline){
|
||||
lender_landline_no = null;
|
||||
}
|
||||
else if(formValue.lender_stdcode && formValue.lender_landline){
|
||||
lender_landline_no = formValue.lender_stdcode + '-' + formValue.lender_landline;
|
||||
}
|
||||
else{
|
||||
lender_landline_no = null;
|
||||
}
|
||||
// if(!formValue.lender_stdcode || !formValue.lender_landline){
|
||||
// lender_landline_no = null;
|
||||
// }
|
||||
// else if(!formValue.lender_stdcode && !formValue.lender_landline){
|
||||
// lender_landline_no = null;
|
||||
// }
|
||||
// else if(formValue.lender_stdcode && formValue.lender_landline){
|
||||
// lender_landline_no = formValue.lender_stdcode + '-' + formValue.lender_landline;
|
||||
// }
|
||||
// else{
|
||||
// lender_landline_no = null;
|
||||
// }
|
||||
|
||||
if(!formValue.applicant_stdcode || !formValue.applicant_landline){
|
||||
applicant_landline_no = null;
|
||||
@ -647,9 +648,9 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
"lender_sales_person":formValue.lender_sales_person,
|
||||
"lender_credit_person":formValue.lender_credit_person,
|
||||
"imgc_fin_institute":formValue.imgc_fin_institute,
|
||||
"pd_contact_person": formValue.lender_contact_person,
|
||||
"pd_contact_mobileno": formValue.lender_contact_mobile,
|
||||
"pd_contact_landline": lender_landline_no,
|
||||
// "pd_contact_person": formValue.lender_contact_person,
|
||||
// "pd_contact_mobileno": formValue.lender_contact_mobile,
|
||||
// "pd_contact_landline": lender_landline_no,
|
||||
"fk_product_id": formValue.fk_product_id,
|
||||
"fk_subproduct_id": formValue.fk_product_id != 4 ? formValue.fk_subproduct_id != '' || formValue.fk_subproduct_id != 0 ? formValue.fk_subproduct_id : null : null,
|
||||
"fk_pd_type": formValue.fk_pd_type,
|
||||
@ -831,9 +832,9 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
|
||||
if(lender_filter=="IMGC"){
|
||||
this.sales_and_credit_enable=true;
|
||||
this._PDtriggerForm.controls['lender_contact_person'].setValue(null)
|
||||
this._PDtriggerForm.controls['lender_contact_person'].clearValidators()
|
||||
this._PDtriggerForm.controls['lender_contact_person'].updateValueAndValidity()
|
||||
// this._PDtriggerForm.controls['lender_contact_person'].setValue(null)
|
||||
// this._PDtriggerForm.controls['lender_contact_person'].clearValidators()
|
||||
// this._PDtriggerForm.controls['lender_contact_person'].updateValueAndValidity()
|
||||
}
|
||||
else{
|
||||
this.sales_and_credit_enable=false;
|
||||
@ -854,8 +855,8 @@ export class AddPdComponent implements OnInit, OnDestroy {
|
||||
|
||||
}
|
||||
|
||||
if( this._PDtriggerForm.value.pd_branch_id !=null){
|
||||
let param={fk_lender_id:this._PDtriggerForm.value.fk_lender_id,pd_branch_id:this._PDtriggerForm.value.pd_branch_id}
|
||||
// if( this._PDtriggerForm.value.pd_branch_id !=null){
|
||||
let param={fk_lender_id:this._PDtriggerForm.value.fk_lender_id}
|
||||
this._pd.getLenderContactPersons(param).subscribe(result=>{
|
||||
if(result['dataStatus']){
|
||||
let records=result['records']
|
||||
@ -872,7 +873,7 @@ if( this._PDtriggerForm.value.pd_branch_id !=null){
|
||||
}
|
||||
},err=>{this.notifier.notify("error","Network Error")})
|
||||
|
||||
}
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
@ -884,4 +885,11 @@ if( this._PDtriggerForm.value.pd_branch_id !=null){
|
||||
}
|
||||
}
|
||||
|
||||
customerSegmentChange(value){
|
||||
console.log(value)
|
||||
this.selected_cus_abbr=this.customerSegmentList.filter(val=>val.customer_segment_id == value).map(vl=>vl.abbr)[0]
|
||||
console.log(this.selected_cus_abbr);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -31,7 +31,7 @@
|
||||
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 40%" *ngIf="CSAbbr != 'SE-RI'">
|
||||
<input matInput placeholder="Company / Firm Name" formControlName="company_name" type="text">
|
||||
<input matInput [placeholder]="selected_cus_abbr == 'SEP_INDV' ? 'Nature of Service' : 'Company / Firm Name'" formControlName="company_name" type="text">
|
||||
|
||||
</mat-form-field>
|
||||
|
||||
|
||||
@ -71,7 +71,7 @@
|
||||
</mat-select>
|
||||
</mat-form-field><br/>
|
||||
<!-- </div> -->
|
||||
<mat-form-field style="width: 28%">
|
||||
<!-- <mat-form-field style="width: 28%">
|
||||
<input matInput placeholder="Lender Contact Person" formControlName="pd_contact_person"
|
||||
type="text" >
|
||||
</mat-form-field>
|
||||
@ -80,11 +80,11 @@
|
||||
type="text" maxlength="10" ForMobileNumbers>
|
||||
<mat-error *ngIf="pdMain.pd_contact_mobileno.hasError('pattern') || pdMain.pd_contact_mobileno.hasError('maxlength') || pdMain.pd_contact_mobileno.hasError('minlength')">Enter
|
||||
Valid Mobile Number. </mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 10%">
|
||||
</mat-form-field> -->
|
||||
<!-- <mat-form-field style="width: 10%">
|
||||
<input matInput placeholder="STD Code" formControlName="lender_stdcode" type="text" maxlength="5"
|
||||
ForMobileNumbers>
|
||||
<!-- <span matPrefix>+91</span> -->
|
||||
|
||||
<mat-error *ngIf="pdMain.lender_stdcode.hasError('maxlength') || pdMain.lender_stdcode.hasError('minlength')">Enter
|
||||
Valid STD Code. </mat-error>
|
||||
</mat-form-field> -
|
||||
@ -93,7 +93,7 @@
|
||||
type="text" maxlength="8" ForMobileNumbers>
|
||||
<mat-error *ngIf="pdMain.lender_landline.hasError('maxlength') || pdMain.lender_landline.hasError('minlength')">Enter
|
||||
Valid Landline Number. </mat-error>
|
||||
</mat-form-field>
|
||||
</mat-form-field> -->
|
||||
<!-- <mat-form-field style="width: 21.5%">
|
||||
<mat-select placeholder="Branch" formControlName="pd_branch_id"> -->
|
||||
<!-- (selectionChange)="getBillingDetails(pdMain.fk_lender_id.value)" -->
|
||||
|
||||
@ -93,6 +93,10 @@ export class EditPdMasterComponent implements OnInit {
|
||||
this._pd.getEntityPreferences(entity_id).subscribe(res=>{
|
||||
if(res['dataStatus']){
|
||||
this.productAllList=res['records'].products
|
||||
let x = this.lenderList.filter(item => item.entity_id == this.data.records.fk_lender_id)
|
||||
this.lenderBranchList = x[0]['branches'];
|
||||
this.lenderShortName = x[0]['short_name'] ;
|
||||
this.filterProductAbbr(x[0]['short_name'],1);
|
||||
|
||||
this.pdTypeList=res['records'].pd_types
|
||||
this.customerSegmentAllList=res['records'].customer_segments
|
||||
@ -121,16 +125,14 @@ export class EditPdMasterComponent implements OnInit {
|
||||
if (data.status == 200) {
|
||||
this.lenderList=data.records;
|
||||
if(this.data.records.fk_lender_id != null){
|
||||
let x = this.lenderList.filter(item => item.entity_id == this.data.records.fk_lender_id)
|
||||
this.lenderBranchList = x[0]['branches'];
|
||||
this.lenderShortName = x[0]['short_name'] ;
|
||||
this.filterProductAbbr(x[0]['short_name'],1);
|
||||
if(this.data.records.fk_lender_id){
|
||||
this.getProCusPDType(this.data.records.fk_lender_id,'start')
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
this.applicantLength=this.data.applicantLength;
|
||||
if(this.data.records.fk_lender_id){
|
||||
this.getProCusPDType(this.data.records.fk_lender_id,'start')
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -199,6 +201,7 @@ if(!option){
|
||||
|
||||
filterProductAbbr(param,flag){
|
||||
if(param == 'CLIX'){
|
||||
console.log(this.productAllList);
|
||||
// console.log(this.productAllList);
|
||||
let getProductAbbr = this.productAllList.map(dval => dval.product_abbr);
|
||||
// console.log('getProductAbbr',getProductAbbr);
|
||||
@ -302,13 +305,13 @@ if(!option){
|
||||
fk_lender_id: [this.data.records.fk_lender_id, Validators.compose([Validators.required])],
|
||||
lender_applicant_id: [this.data.records.lender_applicant_id, Validators.compose([Validators.required])],
|
||||
pd_branch_id:[this.data.records.pd_branch_id],
|
||||
pd_contact_person: [this.data.records.pd_contact_person],
|
||||
// pd_contact_person: [this.data.records.pd_contact_person],
|
||||
lender_sales_person:[this.data.records.lender_sales_person],
|
||||
lender_credit_person:[this.data.records.lender_credit_person],
|
||||
imgc_fin_institute:[this.data.records.imgc_fin_institute],
|
||||
pd_contact_mobileno: [this.data.records.pd_contact_mobileno, Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
|
||||
lender_stdcode: [stdcode, Validators.compose([Validators.minLength(3),Validators.maxLength(5)])],
|
||||
lender_landline: [landline,Validators.compose([Validators.minLength(6),Validators.maxLength(8)])],
|
||||
// pd_contact_mobileno: [this.data.records.pd_contact_mobileno, Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
|
||||
// lender_stdcode: [stdcode, Validators.compose([Validators.minLength(3),Validators.maxLength(5)])],
|
||||
// lender_landline: [landline,Validators.compose([Validators.minLength(6),Validators.maxLength(8)])],
|
||||
fk_product_id: [this.data.records.fk_product_id],
|
||||
fk_subproduct_id: [this.data.records.fk_subproduct_id],
|
||||
fk_pd_type: [this.data.records.fk_pd_type],
|
||||
@ -374,6 +377,7 @@ if(!option){
|
||||
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;
|
||||
console.log("dd sub",this.subProductList)
|
||||
}
|
||||
else {
|
||||
this.productShortName = '';
|
||||
@ -385,14 +389,14 @@ if(!option){
|
||||
// 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._EditPDtriggerForm.controls['fk_subproduct_id'].setValue(this.subProductList[0].subproduct_id);
|
||||
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);
|
||||
this._EditPDtriggerForm.controls['fk_subproduct_id'].setValue(this.subProductList[0].subproduct_id);
|
||||
if(this.lenderShortName == 'CLIX' && flag==2 ){ this._EditPDtriggerForm.controls['fk_customer_segment'].setValue('5'); }
|
||||
this.subProductList=[];
|
||||
this.isSubproductShown = false;
|
||||
@ -617,8 +621,8 @@ if(!option){
|
||||
// this._EditPDtriggerForm.controls['imgc_fin_institute'].setValidators([Validators.required]);
|
||||
// this._EditPDtriggerForm.controls['imgc_fin_institute'].updateValueAndValidity();
|
||||
|
||||
this._EditPDtriggerForm.controls['pd_contact_mobileno'].setValidators([Validators.required]);
|
||||
this._EditPDtriggerForm.controls['pd_contact_mobileno'].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();
|
||||
@ -638,24 +642,27 @@ if(!option){
|
||||
}
|
||||
|
||||
let my_array = this._EditPDtriggerForm.value;
|
||||
let concat_landline
|
||||
if(my_array.lender_stdcode != null && my_array.lender_landline != null){
|
||||
if(my_array.lender_stdcode == '' && my_array.lender_landline == ''){
|
||||
concat_landline = null;
|
||||
}else{
|
||||
let std = my_array.lender_stdcode == '' ? '' : my_array.lender_stdcode;
|
||||
let landline = my_array.lender_landline == '' ? '' : my_array.lender_landline;
|
||||
concat_landline = std+'-'+landline;
|
||||
}
|
||||
}else if(my_array.lender_stdcode == '' && my_array.lender_landerline == ''){
|
||||
concat_landline = null;
|
||||
}else{
|
||||
concat_landline = null;
|
||||
}
|
||||
let concat_landline=''
|
||||
// if(my_array.lender_stdcode != null && my_array.lender_landline != null){
|
||||
// if(my_array.lender_stdcode == '' && my_array.lender_landline == ''){
|
||||
// concat_landline = null;
|
||||
// }else{
|
||||
// let std = my_array.lender_stdcode == '' ? '' : my_array.lender_stdcode;
|
||||
// let landline = my_array.lender_landline == '' ? '' : my_array.lender_landline;
|
||||
// concat_landline = std+'-'+landline;
|
||||
// }
|
||||
// }else if(my_array.lender_stdcode == '' && my_array.lender_landerline == ''){
|
||||
// concat_landline = null;
|
||||
// }else{
|
||||
// concat_landline = null;
|
||||
// }
|
||||
|
||||
if((my_array.pd_contact_mobileno == '' || my_array.pd_contact_mobileno == null) && (concat_landline == '' || concat_landline == null )){
|
||||
this.notifier.notify('warning', 'Either Mobile or Landline Need.!');
|
||||
return;
|
||||
// if((my_array.pd_contact_mobileno == '' || my_array.pd_contact_mobileno == null) && (concat_landline == '' || concat_landline == null )){
|
||||
// this.notifier.notify('warning', 'Either Mobile or Landline Need.!');
|
||||
// return;
|
||||
// }
|
||||
if(concat_landline != ''){
|
||||
|
||||
}
|
||||
else{
|
||||
let filteredAddressesdata = my_array.addresses.filter(item => item.isactive == 1);
|
||||
@ -664,12 +671,12 @@ if(!option){
|
||||
"fk_lender_id": my_array.fk_lender_id,
|
||||
"lender_applicant_id": my_array.lender_applicant_id,
|
||||
"pd_branch_id":my_array.pd_branch_id,
|
||||
"pd_contact_person": my_array.pd_contact_person,
|
||||
// "pd_contact_person": my_array.pd_contact_person,
|
||||
"lender_sales_person":my_array.lender_sales_person,
|
||||
"lender_credit_person":my_array.lender_credit_person,
|
||||
"imgc_fin_institute":my_array.imgc_fin_institute,
|
||||
"pd_contact_mobileno": my_array.pd_contact_mobileno,
|
||||
"pd_contact_landline": concat_landline,
|
||||
// "pd_contact_mobileno": my_array.pd_contact_mobileno,
|
||||
// "pd_contact_landline": concat_landline,
|
||||
"fk_product_id": my_array.fk_product_id,
|
||||
"fk_subproduct_id": my_array.fk_product_id != '4' ? my_array.fk_subproduct_id : null,
|
||||
"fk_pd_type": my_array.fk_pd_type,
|
||||
@ -748,9 +755,9 @@ getContactPerson(){
|
||||
|
||||
if(lender_filter=="IMGC"){
|
||||
this.sales_and_credit_enable=true;
|
||||
this._EditPDtriggerForm.controls['pd_contact_person'].setValue(null)
|
||||
this._EditPDtriggerForm.controls['pd_contact_person'].clearValidators()
|
||||
this._EditPDtriggerForm.controls['pd_contact_person'].updateValueAndValidity()
|
||||
// this._EditPDtriggerForm.controls['pd_contact_person'].setValue(null)
|
||||
// this._EditPDtriggerForm.controls['pd_contact_person'].clearValidators()
|
||||
// this._EditPDtriggerForm.controls['pd_contact_person'].updateValueAndValidity()
|
||||
}
|
||||
else{
|
||||
this.loadControl=true
|
||||
@ -772,8 +779,8 @@ getContactPerson(){
|
||||
|
||||
}
|
||||
|
||||
if(this._EditPDtriggerForm.value.pd_branch_id !=null ){
|
||||
let param={fk_lender_id:this._EditPDtriggerForm.value.fk_lender_id,pd_branch_id:this._EditPDtriggerForm.value.pd_branch_id}
|
||||
// if(this._EditPDtriggerForm.value.pd_branch_id !=null ){
|
||||
let param={fk_lender_id:this._EditPDtriggerForm.value.fk_lender_id}
|
||||
this._pd.getLenderContactPersons(param).subscribe(result=>{
|
||||
if(result['dataStatus']){
|
||||
let records=result['records']
|
||||
@ -792,10 +799,10 @@ getContactPerson(){
|
||||
},err=>{this.notifier.notify("error","Network Error")})
|
||||
|
||||
|
||||
}
|
||||
else{
|
||||
this.loadControl=true
|
||||
}
|
||||
// }
|
||||
// else{
|
||||
// this.loadControl=true
|
||||
// }
|
||||
}
|
||||
else{
|
||||
this.loadControl=true
|
||||
|
||||
@ -349,14 +349,14 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -377,13 +377,13 @@
|
||||
<div *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
*ngIf="doc.document_type == 'pdf';">-->
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
<mat-icon
|
||||
<!-- <mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -394,8 +394,9 @@
|
||||
<ng-template #noFiles>
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</mat-card-content>
|
||||
</ng-template>-->
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -62,6 +62,7 @@ export class AddressComponent implements OnInit {
|
||||
private notifier: NotifierService;
|
||||
public addressForm: FormGroup;
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||
|
||||
/**Constructor of the class */
|
||||
constructor(private el: ElementRef, notifier: NotifierService,
|
||||
@ -89,7 +90,7 @@ export class AddressComponent implements OnInit {
|
||||
this.CustSegAbbr = this.pd_all_details.pdmaster_details.customer_segment_abbr.substr(0, CSAbbrSearch);
|
||||
|
||||
this.notifier = notifier;
|
||||
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
|
||||
/**Init Fns of the class */
|
||||
@ -108,7 +109,7 @@ export class AddressComponent implements OnInit {
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = '5';
|
||||
this.setAddressFromDatas(params);
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
}
|
||||
|
||||
loadPDAddressesDetails() {
|
||||
@ -616,25 +617,25 @@ export class AddressComponent implements OnInit {
|
||||
}
|
||||
};
|
||||
|
||||
imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
pic.form_id = this.form_id;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
data: pic,
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh',
|
||||
height: '100%',
|
||||
width: '100%',
|
||||
});
|
||||
imageRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
if(dataresult == 1){
|
||||
this.documentsAndFilesList = [];
|
||||
this.retriveFile();
|
||||
}
|
||||
});
|
||||
}
|
||||
// imageCrop(pic) {
|
||||
// // let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
// pic.pdid = this.pdid;
|
||||
// pic.form_id = this.form_id;
|
||||
// const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
// data: pic,
|
||||
// maxWidth: '100vw',
|
||||
// maxHeight: '100vh',
|
||||
// height: '100%',
|
||||
// width: '100%',
|
||||
// });
|
||||
// imageRef.afterClosed()
|
||||
// .subscribe(dataresult => {
|
||||
// if(dataresult == 1){
|
||||
// this.documentsAndFilesList = [];
|
||||
// this.retriveFile();
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
setAddressFromDatas(params){
|
||||
this._pd.retriveForm(params).subscribe(data => {
|
||||
@ -804,29 +805,29 @@ export class AddressComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
retriveFile(){
|
||||
this._pd.retriveFile(this.pdid, '5', null).subscribe(data => {
|
||||
// retriveFile(){
|
||||
// this._pd.retriveFile(this.pdid, '5', null).subscribe(data => {
|
||||
|
||||
if (data.status == 200) {
|
||||
if (data.records.length > 0) {
|
||||
data.records.forEach((val, index) => {
|
||||
let splitted = val.pd_document_name.split(".");
|
||||
let DocumentsAndFiles = {
|
||||
'document_id':val.pd_document_id,
|
||||
'document_name': val.pd_document_name,
|
||||
'document_title': val.pd_document_title,
|
||||
'document': val.doc_url,
|
||||
'document_type': splitted[1] == 'pdf' ? 'pdf' : 'image',
|
||||
'is_show_report':val.is_show_report
|
||||
}
|
||||
this.documentsAndFilesList.push(DocumentsAndFiles);
|
||||
});
|
||||
}
|
||||
}
|
||||
else {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
// if (data.status == 200) {
|
||||
// if (data.records.length > 0) {
|
||||
// data.records.forEach((val, index) => {
|
||||
// let splitted = val.pd_document_name.split(".");
|
||||
// let DocumentsAndFiles = {
|
||||
// 'document_id':val.pd_document_id,
|
||||
// 'document_name': val.pd_document_name,
|
||||
// 'document_title': val.pd_document_title,
|
||||
// 'document': val.doc_url,
|
||||
// 'document_type': splitted[1] == 'pdf' ? 'pdf' : 'image',
|
||||
// 'is_show_report':val.is_show_report
|
||||
// }
|
||||
// this.documentsAndFilesList.push(DocumentsAndFiles);
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// else {
|
||||
// this.documentsAndFilesList = [];
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
}
|
||||
@ -440,14 +440,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -469,12 +470,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -486,7 +487,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -71,6 +71,8 @@ export class AssetsInfoComponent implements OnInit {
|
||||
currentYear: any = new Date().getFullYear();
|
||||
documentsAndFilesList: any = [];
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: string; form_id: any; company_id: string; };
|
||||
form_id: string;
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
private _formBuilder: FormBuilder,
|
||||
@ -81,6 +83,7 @@ export class AssetsInfoComponent implements OnInit {
|
||||
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.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id='4'
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
this.applicants = this.applicants.filter(val => val.applicant_type == 0 || val.applicant_type == 1)
|
||||
this.applicants.push({ 'pd_co_applicant_id': '0', 'applicant_name': 'Others' });
|
||||
@ -89,6 +92,7 @@ export class AssetsInfoComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
|
||||
public viewerOptions: any = {
|
||||
@ -151,7 +155,7 @@ export class AssetsInfoComponent implements OnInit {
|
||||
this.getM_Vehicle_Type();
|
||||
this.getM_UOM_Type();
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -983,7 +987,7 @@ export class AssetsInfoComponent implements OnInit {
|
||||
}
|
||||
});
|
||||
}
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -1023,7 +1027,7 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
setAction(dummy){
|
||||
console.log(this._assetsQuesFrom.value);
|
||||
let value=dummy
|
||||
|
||||
@ -228,14 +228,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -257,12 +258,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -274,7 +275,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -51,6 +51,8 @@ export class BankingDetailsComponent implements OnInit {
|
||||
existCompanyList: any = [];
|
||||
mergeCompanyApplicant: any = [];
|
||||
documentsAndFilesList: any = [];
|
||||
image_doc_params: { pdid: number; form_id: any; company_id: string; };
|
||||
form_id: string;
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private _pd: PdTrigerService,
|
||||
@ -59,6 +61,7 @@ export class BankingDetailsComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
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='7'
|
||||
this.pd_cus_segment = this.pd_all_details.pdmaster_details.customer_segment_abbr.toUpperCase();
|
||||
this.pd_cus_segment = this.pd_cus_segment.substring(0, 3);
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
@ -70,7 +73,7 @@ export class BankingDetailsComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
|
||||
public viewerOptions: any = {
|
||||
@ -167,7 +170,7 @@ export class BankingDetailsComponent implements OnInit {
|
||||
}
|
||||
});
|
||||
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
|
||||
}
|
||||
|
||||
@ -389,7 +392,7 @@ export class BankingDetailsComponent implements OnInit {
|
||||
window.open(fileURL);
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -429,7 +432,7 @@ export class BankingDetailsComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
onChangeAvailable(value){
|
||||
console.log(value)
|
||||
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
||||
|
||||
@ -468,14 +468,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -497,12 +498,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -514,7 +515,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -66,6 +66,8 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
endUserList = [];
|
||||
address_type: any;
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: string; form_id: any; company_id: any; };
|
||||
form_id: string;
|
||||
/**Constructor of the class */
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
@ -76,6 +78,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
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='22'
|
||||
this.lender_short_name=this.pd_all_details.pdmaster_details.lender_short_name
|
||||
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
@ -92,6 +95,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
this.generalExistBusinessMonth = this.pd_all_details.business_month;
|
||||
|
||||
this.getM_Address_Type();
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
documentsAndFilesList: any = [];
|
||||
/** init Function */
|
||||
@ -132,7 +136,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
this.getM_Assets_Type();
|
||||
this.getM_PropertyType();
|
||||
this.getM_Vehicle_Type();
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
/** init Function Ends Here */
|
||||
|
||||
@ -1165,7 +1169,7 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
pdf(fileURL) {
|
||||
window.open(fileURL);
|
||||
}
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -1205,7 +1209,7 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
/** For Docs Tab */
|
||||
public viewerOptions: any = {
|
||||
navbar: false,
|
||||
|
||||
@ -159,14 +159,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -188,12 +189,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -205,7 +206,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -56,6 +56,8 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
generalExistBusinessMonth: Number;
|
||||
yearErrorMessage: any = [];
|
||||
monthErrorMessage: any = [];
|
||||
image_doc_params: { pdid: number; form_id: any; company_id: String; };
|
||||
form_id: string;
|
||||
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
@ -65,6 +67,7 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
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='21'
|
||||
this.pd_cus_segment = this.pd_all_details.pdmaster_details.customer_segment_abbr.toUpperCase();
|
||||
this.pd_cus_segment = this.pd_cus_segment.substring(0, 3);
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
@ -79,6 +82,7 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||
this.generalExistBusinessYear = this.pd_all_details.business_years;
|
||||
this.generalExistBusinessMonth = this.pd_all_details.business_month;
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -166,7 +170,7 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
// control.push(this.createBankarray());
|
||||
}
|
||||
});
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
|
||||
// ======================
|
||||
@ -429,7 +433,7 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -469,7 +473,7 @@ export class BusinessBankingDetailsComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
onChangeAvailable(value){
|
||||
console.log(value)
|
||||
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
||||
|
||||
@ -75,8 +75,8 @@
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<p style="margin-left: 2% !important">No of Years in
|
||||
Current Business </p>
|
||||
<p style="margin-left: 2% !important"> No of Years in
|
||||
Current <span *ngIf="customer_segment_abbr == 'SEP_INDV'">Profession</span> <span *ngIf="customer_segment_abbr != 'SEP_INDV'"> Business </span></p>
|
||||
|
||||
<div fxLayout="row nowrap" class="state-margin">
|
||||
|
||||
@ -1857,14 +1857,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -1886,12 +1887,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -1903,7 +1904,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -92,6 +92,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
|
||||
temp_noofposmachine: any;
|
||||
temp_additiondetailofposmachine: any = [];
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: String; };
|
||||
|
||||
constructor(notifier: NotifierService,
|
||||
private fb: FormBuilder,
|
||||
@ -119,6 +120,8 @@ export class BusinessInfoComponent implements OnInit {
|
||||
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;
|
||||
console.log("com",this.company_id)
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
documentsAndFilesList: any = [];
|
||||
pdf(fileURL){
|
||||
@ -655,7 +658,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
val.toUpperCase() == 'YES' ? this.businessForm.addControl('month_of_business_run', new FormControl('', Validators.required)) : this.businessForm.removeControl('month_of_business_run');
|
||||
});
|
||||
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
}
|
||||
public initBusinessForm(): void {
|
||||
this.businessForm = this.fb.group({
|
||||
@ -1986,7 +1989,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
if(Flag == 8) {event.value =='yes' ? this.businessForm.addControl('fire_noc_pic', new FormControl('')) : this.businessForm.removeControl('fire_noc_pic');}
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -2026,5 +2029,5 @@ export class BusinessInfoComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
} */
|
||||
}
|
||||
|
||||
@ -469,14 +469,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -498,12 +499,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -515,7 +516,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -79,6 +79,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
}
|
||||
];
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
@ -97,6 +98,7 @@ export class ClientInfoComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -188,7 +190,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
// this.getPdSupplierFormDetails();
|
||||
this.getMasterDetails('COMPANYRELATIONSHIPS', 1);
|
||||
this.getMasterDetails('TITLES', 2);
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
|
||||
// retaildTradingForm: Boolean = false;
|
||||
@ -782,7 +784,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
}
|
||||
});
|
||||
}
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -822,5 +824,5 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ -26,16 +26,25 @@
|
||||
<mat-card>
|
||||
<!-- <mat-card-title></mat-card-title> -->
|
||||
<mat-card-content>
|
||||
|
||||
<mat-form-field style="width:60% !important;">
|
||||
<mat-select (selectionChange)="selectedLoanChanges($event.value)" placeholder="Do you have any other existing loan"
|
||||
<mat-select placeholder="Do you have any other existing loan"
|
||||
formControlName="existing_loan">
|
||||
<mat-option>Select</mat-option>
|
||||
<mat-option value="Yes">Yes</mat-option>
|
||||
<mat-option value="No">No</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:60% !important;" *ngIf="currentLoanForm.controls.existing_loan.value == 'Yes'">
|
||||
<mat-select (selectionChange)="selectedLoanChanges($event.value)" placeholder="Details of all loan info available"
|
||||
formControlName="loan_info_available">
|
||||
<mat-option>Select</mat-option>
|
||||
<mat-option value="Yes">Yes</mat-option>
|
||||
<mat-option value="No">No</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-card *ngIf="currentLoanForm.controls.existing_loan.value == 'Yes'">
|
||||
<mat-card *ngIf="currentLoanForm.controls.loan_info_available.value == 'Yes' && currentLoanForm.controls.existing_loan.value == 'Yes'">
|
||||
|
||||
<div formArrayName="loan_details">
|
||||
<div *ngFor="let details of currentLoanForm.get('loan_details').controls; let i=index; let last=last"
|
||||
@ -179,6 +188,23 @@
|
||||
</div>
|
||||
</mat-card>
|
||||
|
||||
<mat-card *ngIf="currentLoanForm.controls.loan_info_available.value == 'No' && currentLoanForm.controls['tot_outstanding_loans'] && currentLoanForm.controls.existing_loan.value == 'Yes'">
|
||||
<mat-card-header>
|
||||
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<mat-form-field style="width: 30%">
|
||||
<input matInput type="number" placeholder="Total no of running loans" formControlName="tot_running_loans">
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 30%">
|
||||
<input matInput type="number" placeholder="Total EMI being paid" formControlName="tot_emi_paid">
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 30%">
|
||||
<input matInput type="number" placeholder="Total Outstanding of all running loans" formControlName="tot_outstanding_loans">
|
||||
</mat-form-field>
|
||||
</mat-card-content>
|
||||
</mat-card>
|
||||
|
||||
</mat-card-content>
|
||||
|
||||
<mat-card-actions align="end">
|
||||
@ -195,14 +221,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -224,12 +251,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -241,7 +268,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -44,6 +44,7 @@ export class CurrentLoanComponent implements OnInit {
|
||||
existCompanyList: any = [];
|
||||
mergeCompanyApplicant: any = [];
|
||||
isOtherLoanTakenBy:any = [];
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
@ -61,6 +62,7 @@ export class CurrentLoanComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -129,9 +131,15 @@ export class CurrentLoanComponent implements OnInit {
|
||||
if (value.status == 200) {
|
||||
|
||||
this.currentLoanForm.controls['existing_loan'].setValue(value.records.existing_loan);
|
||||
this.currentLoanForm.controls['loan_info_available'].setValue(value.records.hasOwnProperty('loan_info_available') ? value.records.loan_info_available : 'Yes');
|
||||
value.records.loan_info_available=this.currentLoanForm.value.loan_info_available
|
||||
this.currentLoanForm.controls['currentloan_remarks'].setValue(value.records.currentloan_remarks);
|
||||
if(this.currentLoanForm.value.loan_info_available == 'No'){
|
||||
this.selectedLoanChanges(value.records.loan_info_available)
|
||||
}
|
||||
|
||||
if (value.records.existing_loan == 'Yes') {
|
||||
if (value.records.loan_info_available == 'Yes') {
|
||||
console.log("yes part",)
|
||||
|
||||
let loandetails = value.records.loan_details
|
||||
|
||||
@ -172,6 +180,13 @@ export class CurrentLoanComponent implements OnInit {
|
||||
// control.push(this.createLoanDetail());
|
||||
}
|
||||
}
|
||||
else if(value.records.loan_info_available == 'No'){
|
||||
this.currentLoanForm.patchValue({
|
||||
tot_running_loans:value.records.tot_running_loans,
|
||||
tot_emi_paid:value.records.tot_emi_paid,
|
||||
tot_outstanding_loans:value.records.tot_outstanding_loans
|
||||
})
|
||||
}
|
||||
} else {
|
||||
|
||||
this._pd.getAssetsWithLoanFromBusiness(this.pdid).subscribe(data => {
|
||||
@ -347,6 +362,7 @@ export class CurrentLoanComponent implements OnInit {
|
||||
let arr: any = [];
|
||||
if (this.labelArr.length > 0) {
|
||||
this.currentLoanForm.controls['existing_loan'].setValue('Yes');
|
||||
this.currentLoanForm.controls['loan_info_available'].setValue('Yes');
|
||||
this.labelArr.forEach((v, index) => {
|
||||
arr = {
|
||||
'label': v,
|
||||
@ -380,7 +396,7 @@ export class CurrentLoanComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
})
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
checkTenure(details) {
|
||||
let originalTenure = details.value.original_tenure;
|
||||
@ -412,6 +428,7 @@ this.retriveFile();
|
||||
public initCurrentloanForm(): void {
|
||||
this.currentLoanForm = this.fb.group({
|
||||
existing_loan: [''],
|
||||
loan_info_available:[''],
|
||||
currentloan_remarks: [''],
|
||||
loan_details: this.fb.array([]),
|
||||
});
|
||||
@ -420,6 +437,9 @@ this.retriveFile();
|
||||
selectedLoanChanges(e): void {
|
||||
|
||||
if (e == 'Yes') {
|
||||
this.currentLoanForm.removeControl('tot_running_loans')
|
||||
this.currentLoanForm.removeControl('tot_emi_paid')
|
||||
this.currentLoanForm.removeControl('tot_outstanding_loans')
|
||||
|
||||
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
|
||||
// let objs = {
|
||||
@ -444,6 +464,12 @@ this.retriveFile();
|
||||
|
||||
const arr = <FormArray>this.currentLoanForm.controls.loan_details;
|
||||
arr.removeAt(0);
|
||||
// this.currentLoanForm.removeControl('')
|
||||
|
||||
|
||||
this.currentLoanForm.addControl('tot_running_loans',new FormControl(''))
|
||||
this.currentLoanForm.addControl('tot_emi_paid',new FormControl(''))
|
||||
this.currentLoanForm.addControl('tot_outstanding_loans',new FormControl(''))
|
||||
}
|
||||
}
|
||||
// selectedBorrower(e,i){
|
||||
@ -537,10 +563,16 @@ this.retriveFile();
|
||||
records.formid = this.form_id;
|
||||
records.fk_createdby = this.pdid;
|
||||
records.existing_loan = this.currentLoanForm.controls['existing_loan'].value;
|
||||
records.loan_info_available=this.currentLoanForm.controls['loan_info_available'].value
|
||||
records.currentloan_remarks = this.currentLoanForm.controls['currentloan_remarks'].value;
|
||||
if (records.existing_loan == 'Yes') {
|
||||
if (records.loan_info_available == 'Yes') {
|
||||
records.loan_details = this.currentLoanForm.controls['loan_details'].value;
|
||||
}
|
||||
else{
|
||||
records.tot_running_loans=this.currentLoanForm.controls['tot_running_loans'].value
|
||||
records.tot_emi_paid=this.currentLoanForm.controls['tot_emi_paid'].value
|
||||
records.tot_outstanding_loans=this.currentLoanForm.controls['tot_outstanding_loans'].value
|
||||
}
|
||||
this._pd.saveForm(records).subscribe(data => {
|
||||
if (data.status == 200) {
|
||||
this.notifier.notify('success', 'Saved Successfully.');
|
||||
@ -659,7 +691,7 @@ this.retriveFile();
|
||||
}
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -699,7 +731,7 @@ this.retriveFile();
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
titleCaseWord(word:string) {
|
||||
const unicodeWordMatch =
|
||||
@ -710,4 +742,7 @@ this.retriveFile();
|
||||
unicodeWordMatch, (txt => txt[0].toUpperCase() + txt.substr(1).toLowerCase()));
|
||||
// return word[0].toUpperCase() + word.substr(1).toLowerCase();
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -280,14 +280,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -309,12 +310,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -326,7 +327,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -56,6 +56,7 @@ export class EmploymentInfoComponent implements OnInit {
|
||||
public todate: any[] = this.dateonly;
|
||||
generalExistBusinessYear:any;
|
||||
generalExistBusinessMonth:any;
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||
|
||||
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
@ -74,7 +75,7 @@ export class EmploymentInfoComponent implements OnInit {
|
||||
this.customer_segment_abbr = this.pd_all_details.pdmaster_details.customer_segment_abbr;
|
||||
this.generalExistBusinessYear=100;
|
||||
this.generalExistBusinessMonth=12;
|
||||
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
|
||||
}
|
||||
pdf(fileURL){
|
||||
@ -185,7 +186,7 @@ export class EmploymentInfoComponent implements OnInit {
|
||||
this.company_relationship_list.push({ 'company_relationship_id': 0, 'name': 'Not Applicable' });
|
||||
}
|
||||
});
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
}
|
||||
|
||||
public initemploymentForm(): void {
|
||||
@ -580,7 +581,7 @@ export class EmploymentInfoComponent implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -620,5 +621,5 @@ export class EmploymentInfoComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ -297,14 +297,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -326,12 +327,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -343,7 +344,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -58,6 +58,7 @@ export class FamilyDetailsComponent implements OnInit {
|
||||
{ id: 2, type: 'Non Earning' }]
|
||||
documentsAndFilesList : any = [];
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
/** constructor Of the class */
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
@ -76,7 +77,7 @@ export class FamilyDetailsComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
|
||||
}
|
||||
|
||||
@ -167,7 +168,7 @@ export class FamilyDetailsComponent implements OnInit {
|
||||
}
|
||||
});
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -686,7 +687,7 @@ export class FamilyDetailsComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -726,7 +727,7 @@ export class FamilyDetailsComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
// validateAllFormFields(formGroup: FormGroup) {
|
||||
// Object.keys(formGroup.controls).forEach(field => {
|
||||
|
||||
@ -249,14 +249,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -278,12 +279,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -295,7 +296,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -52,6 +52,7 @@ export class FinalRemarksComponent implements OnInit {
|
||||
public m_recommendationList = [];
|
||||
public documentsAndFilesList = [];
|
||||
private notifier: NotifierService;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
@ -122,6 +123,7 @@ export class FinalRemarksComponent implements OnInit {
|
||||
|
||||
this.getM_Type();
|
||||
this.getM_Recommendation();
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
|
||||
CreateRecommendationPositive(data) {
|
||||
@ -267,7 +269,7 @@ export class FinalRemarksComponent implements OnInit {
|
||||
}, err => {
|
||||
|
||||
})
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
}
|
||||
|
||||
getM_Recommendation() {
|
||||
@ -655,7 +657,7 @@ export class FinalRemarksComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -695,6 +697,6 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
}
|
||||
|
||||
@ -647,14 +647,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -676,12 +677,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -693,7 +694,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -83,6 +83,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
{id:1, name:'Others'}]
|
||||
// values = [0, 1, 2, 3];
|
||||
documentsAndFilesList: any = [];
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
constructor(notifier: NotifierService,
|
||||
private fb: FormBuilder,
|
||||
@ -107,7 +108,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
let x = this.customer_segment_abbr.split("-");
|
||||
this.CustSegAbbr = x[1];
|
||||
|
||||
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
|
||||
}
|
||||
|
||||
@ -342,7 +343,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
}
|
||||
})
|
||||
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
|
||||
}
|
||||
|
||||
@ -2016,7 +2017,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -2056,5 +2057,5 @@ export class FinancialInfoComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
@ -65,14 +65,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -94,12 +95,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -111,7 +112,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -53,6 +53,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
||||
public m_recommendationList = [];
|
||||
public documentsAndFilesList = [];
|
||||
private notifier: NotifierService;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: any; };
|
||||
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
@ -90,7 +91,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
||||
|
||||
if(this.lender_short_name == 'CLIX' || this.product_abbr == 'LAEP'){ }
|
||||
else{ }
|
||||
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
|
||||
|
||||
@ -141,7 +142,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
||||
|
||||
})
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
|
||||
/** To Save/Edited Popup Data */
|
||||
@ -195,7 +196,7 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
||||
}
|
||||
});
|
||||
}
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -235,6 +236,6 @@ export class FuturePlansAndBusinessEnvironmentComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ -32,7 +32,7 @@
|
||||
<mat-cell *matCellDef="let details;let i = index;" [formGroupName]="i">
|
||||
<input matInput placeholder="ApplicantName" formControlName="applicant_name"
|
||||
[value]="details.get('applicant_name').value | titlecase" autocomplete="off"
|
||||
(change)="ApplicantName($event,details.value.pd_co_applicant_id)">
|
||||
(change)="ApplicantName($event,details.value,i)">
|
||||
<!-- {{details.value.applicant_name | titlecase}} -->
|
||||
</mat-cell>
|
||||
</ng-container>
|
||||
@ -157,7 +157,8 @@
|
||||
<!-- companies start -->
|
||||
<mat-card *ngIf="customer_segment_abbr != 'SE-RI'">
|
||||
<mat-card-header>
|
||||
<mat-card-title>Company/Firm</mat-card-title>
|
||||
<mat-card-title><span *ngIf="customer_segment_abbr == 'SEP_INDV'">Nature of Service</span>
|
||||
<span *ngIf="customer_segment_abbr != 'SEP_INDV'">Company/Firm</span></mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-card-content formArrayName="companies">
|
||||
<div *ngFor="let com of _generalForm.controls.companies['controls']; let c = index;"
|
||||
@ -165,7 +166,7 @@
|
||||
<mat-card *ngIf="com.value.is_active==true">
|
||||
<mat-card-content>
|
||||
<mat-form-field style="width: 50%">
|
||||
<input matInput placeholder="Company/Firm" formControlName="company_name"
|
||||
<input matInput [placeholder]="customer_segment_abbr == 'SEP_INDV' ? 'Nature of Service' : 'Company/Firm'" formControlName="company_name"
|
||||
type="text">
|
||||
</mat-form-field>
|
||||
<mat-checkbox class="table-checkbox-com" color="primary"
|
||||
@ -173,7 +174,7 @@
|
||||
Is Applicant</mat-checkbox>
|
||||
|
||||
<mat-form-field style="width: 45%;">
|
||||
<mat-select placeholder="Business Entity Type"
|
||||
<mat-select [placeholder]="customer_segment_abbr == 'SEP_INDV' ? 'Entity type' : 'Business Entity Type'"
|
||||
formControlName="business_entity_type"
|
||||
(selectionChange)="checkEntityType(com.value.business_entity_type,c)"
|
||||
required>
|
||||
@ -193,7 +194,8 @@
|
||||
Specify Others Required</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<p>Number of Years For Which The Business Has Been Running</p>
|
||||
<p><span *ngIf="customer_segment_abbr == 'SEP_INDV'">Number of Years in Current Profession</span>
|
||||
<span *ngIf="customer_segment_abbr != 'SEP_INDV'">Number of Years For Which The Business Has Been Running</span></p>
|
||||
<mat-form-field style="width: 20%;">
|
||||
<mat-label>Year</mat-label>
|
||||
<input matInput placeholder="No of years (Eg. 10)"
|
||||
@ -235,7 +237,8 @@
|
||||
<mat-card-actions align="center">
|
||||
<button mat-flat-button type="button" matTooltip="Add More" matTooltipPosition="above"
|
||||
color="primary" (click)="addMoreCompanies()"><strong>Add More
|
||||
Company/Firm</strong></button>
|
||||
<span *ngIf="customer_segment_abbr == 'SEP_INDV'">Nature of Service</span>
|
||||
<span *ngIf="customer_segment_abbr != 'SEP_INDV'">Company/Firm</span></strong></button>
|
||||
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
@ -302,7 +305,7 @@
|
||||
<mat-card *ngIf="customer_segment_abbr != 'SE-RI'">
|
||||
<mat-card-header>
|
||||
|
||||
<mat-card-title> Relationship of Individuals to Company / Firm </mat-card-title>
|
||||
<mat-card-title> Relationship of Individuals to <span *ngIf="customer_segment_abbr == 'SEP_INDV'">Profession</span> <span *ngIf="customer_segment_abbr != 'SEP_INDV'">Company / Firm</span> </mat-card-title>
|
||||
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
@ -459,57 +462,8 @@
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button
|
||||
class="date mr-1 mb-1 hover-icon" type="button"
|
||||
matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
<mat-icon>edit</mat-icon>
|
||||
</button>
|
||||
<img src="{{doc.document}}" alt="{{doc.document_name}}">
|
||||
</div>
|
||||
<label *ngIf="doc.document_title != ''"
|
||||
style="font-size: 0.85rem">{{doc.document_title}}</label>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div fxFlex="row">
|
||||
<div fxFlex="100" class="m-gap p-gap">
|
||||
<div fxLayout="row" fxLayoutWrap="wrap">
|
||||
<div *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<ng-template #noFiles>
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
<ng-template matTabContent>
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -17,10 +17,19 @@
|
||||
position: absolute;
|
||||
right: -10px;
|
||||
top: 4px;
|
||||
|
||||
background-color: #e00201 ;
|
||||
}
|
||||
.top .thumbnail .date1 {
|
||||
// margin-right: 13px;
|
||||
position: absolute;
|
||||
right: -10px;
|
||||
top: 50px;
|
||||
background-color: #e00201 ;
|
||||
}
|
||||
.top .thumbnail{
|
||||
//height: 400px;
|
||||
position: relative;
|
||||
|
||||
}
|
||||
.example-container {
|
||||
// display: flex;
|
||||
|
||||
@ -82,6 +82,8 @@ export class GeneralInfoComponent implements OnInit {
|
||||
companyList: any = [];
|
||||
qualificationList: any = [];
|
||||
businessEntityTypeList: any = [];
|
||||
role_id: string;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
/********************** Declaration Section Ends Here *****************/
|
||||
|
||||
@ -97,6 +99,8 @@ export class GeneralInfoComponent implements OnInit {
|
||||
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.disableAfterSubmit = false;
|
||||
this.role_id=localStorage.getItem('user_role')
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
/********************** Constructor Section Ends Here ****************/
|
||||
documentsAndFilesList: any = [];
|
||||
@ -136,7 +140,7 @@ export class GeneralInfoComponent implements OnInit {
|
||||
this.CompanySource.data = ComapnyControl.controls;
|
||||
});
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
/***************************** ng Oninit Section Ends Here **********************************/
|
||||
|
||||
@ -418,7 +422,8 @@ export class GeneralInfoComponent implements OnInit {
|
||||
|
||||
createCompaniesRelationshipWithData(elementValue: any) {
|
||||
return this._fb.group({
|
||||
applicant_name: [this.titleCase.transform(elementValue.applicant_name.toString())],
|
||||
applicant_name:[elementValue.applicant_name],
|
||||
//applicant_name: [this.titleCase.transform(elementValue.applicant_name.toString())],
|
||||
company_relationship: [elementValue.company_relationship],
|
||||
relation_to_company: [elementValue.relation_to_company]
|
||||
});
|
||||
@ -557,17 +562,37 @@ export class GeneralInfoComponent implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
ApplicantName(event, coApplicantId) {
|
||||
ApplicantName(event, control_value,index1) {
|
||||
|
||||
console.log("d",event,control_value)
|
||||
|
||||
let relationControl = <FormArray>this._generalForm.controls['persons_with_relationships'];
|
||||
let index1 = relationControl.value.map(data => data.pd_co_applicant_id).indexOf(coApplicantId);
|
||||
|
||||
// let index1 = relationControl.value.map(data => data.pd_co_applicant_id).indexOf(control_value.pd_co_applicant_id);
|
||||
// if(index1 == '-1'){
|
||||
// index1=1
|
||||
// }
|
||||
// details.value.applicant_name
|
||||
let control = relationControl.controls[index1] as FormArray;
|
||||
|
||||
// console.log(index1,control,relationControl);
|
||||
// console.log(index1 == '-1')
|
||||
|
||||
console.log("dd cha",index1);
|
||||
|
||||
control.controls['applicant_name'].setValue(this.titleCase.transform(event.target.value));
|
||||
|
||||
//for updating the applicant name
|
||||
if(control_value.is_person_met_pic == '' || control_value.is_person_met_pic == null){
|
||||
|
||||
let param_data=control_value
|
||||
param_data.fk_pd_id= this.pdid
|
||||
param_data.hasOwnProperty('link') ? param_data.link : param_data.link=""
|
||||
this._pd.saveApplicantFromGeneralForm(param_data).subscribe(result=>{
|
||||
if(result['dataStatus']){
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// event.target.value
|
||||
// controls.controls[index1].disable();
|
||||
// let personsWithRelationshipsControl : any = <FormArray>control.controls[index1];
|
||||
@ -853,7 +878,7 @@ export class GeneralInfoComponent implements OnInit {
|
||||
// });
|
||||
// }
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -883,7 +908,8 @@ export class GeneralInfoComponent implements OnInit {
|
||||
'document_title': val.pd_document_title,
|
||||
'document': val.doc_url,
|
||||
'document_type': splitted[1] == 'pdf' ? 'pdf' : 'image',
|
||||
'is_show_report': val.is_show_report
|
||||
'is_show_report': val.is_show_report,
|
||||
'is_active':val.isactive ? val.isactive : ''
|
||||
}
|
||||
this.documentsAndFilesList.push(DocumentsAndFiles);
|
||||
});
|
||||
@ -893,6 +919,33 @@ export class GeneralInfoComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}*/
|
||||
updateImage(image_arr){
|
||||
console.log(image_arr)
|
||||
let records= {
|
||||
"pd_document_id": image_arr.document_id,
|
||||
"pd_document_title": image_arr.document_title,
|
||||
"pd_document_name": image_arr.document_name,
|
||||
"is_show_report":image_arr.is_show_report,
|
||||
"fk_updatedby":'',
|
||||
"image": image_arr.document,
|
||||
"fk_pd_id":this.pdid,
|
||||
"isactive":''
|
||||
}
|
||||
if(image_arr.is_active == 1){
|
||||
records.isactive="0"
|
||||
}
|
||||
else{
|
||||
records.isactive="1"
|
||||
}
|
||||
this._pd.updatePDPhoto(records).subscribe(result=>{
|
||||
if(result.dataStatus){
|
||||
this.notifier.notify('success','Updated Successfully');
|
||||
}
|
||||
else{
|
||||
this.notifier.notify('warning','Something went wrong');
|
||||
}
|
||||
},err=>{console.log(err)})
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,73 @@
|
||||
<!-- <ng-template matTabContent> -->
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<!-- {{documentsAndFilesList.length}} -->
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
<div class="thumbnail">
|
||||
|
||||
<div *ngIf="role_id == '2' || role_id == '3' || role_id == '6'|| role_id == '7' || role_id == '10'">
|
||||
<button mat-raised-button mat-icon-button mat-mini-fab
|
||||
class="date mr-1 mb-1 hover-icon" type="button"
|
||||
matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right" [disabled]="doc.is_active == 0">
|
||||
<mat-icon>edit</mat-icon>
|
||||
</button>
|
||||
<div *ngIf="doc.is_active == 1">
|
||||
<button mat-raised-button mat-icon-button mat-mini-fab
|
||||
class="date1 mr-1 mb-1 hover-icon" type="button"
|
||||
matTooltip="Delete" (click)="updateImage(doc)"
|
||||
matTooltipPosition="right">
|
||||
<mat-icon>delete</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
<div *ngIf="doc.is_active == 0">
|
||||
<button mat-raised-button mat-icon-button mat-mini-fab
|
||||
class="date1 mr-1 mb-1 hover-icon" type="button"
|
||||
matTooltip="Enable Image" (click)="updateImage(doc)"
|
||||
matTooltipPosition="right">
|
||||
<mat-icon>lock_open</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<img src="{{doc.document}}" alt="{{doc.document_name}}">
|
||||
</div>
|
||||
<label *ngIf="doc.document_title != ''"
|
||||
style="font-size: 0.85rem">{{doc.document_title}}</label>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div fxFlex="row">
|
||||
<div fxFlex="100" class="m-gap p-gap">
|
||||
<div fxLayout="row" fxLayoutWrap="wrap">
|
||||
<div *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<ng-template #noFiles>
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
<!-- </ng-template> -->
|
||||
@ -0,0 +1,86 @@
|
||||
.top .thumbnail .date {
|
||||
// margin-right: 13px;
|
||||
position: absolute;
|
||||
right: -10px;
|
||||
top: 4px;
|
||||
background-color: #e00201 ;
|
||||
}
|
||||
.top .thumbnail .date1 {
|
||||
// margin-right: 13px;
|
||||
position: absolute;
|
||||
right: -10px;
|
||||
top: 50px;
|
||||
background-color: #e00201 ;
|
||||
}
|
||||
.top .thumbnail{
|
||||
//height: 400px;
|
||||
position: relative;
|
||||
|
||||
}
|
||||
$base-card-box-shadow:1.5px 2.6px 24px 0 rgba(0, 35, 136, 0.08) !important;
|
||||
$product-bg-color-hover: rgba(103, 58, 183, 0.7);
|
||||
.p-list-main {
|
||||
background: white;
|
||||
margin: auto;
|
||||
position: relative;
|
||||
overflow: hidden !important;
|
||||
border-radius: 10px 10px 10px 10px;
|
||||
box-shadow: $base-card-box-shadow;
|
||||
transform: scale(0.95);
|
||||
transition: box-shadow 0.5s, transform 0.5s;
|
||||
&:hover {
|
||||
transform: scale(1);
|
||||
box-shadow: 5px 20px 30px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
.p-list {
|
||||
position: relative;
|
||||
.top {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
// background: url(https://s-media-cache-ak0.pinimg.com/736x/49/80/6f/49806f3f1c7483093855ebca1b8ae2c4.jpg) no-repeat center center;
|
||||
-webkit-background-size: 100%;
|
||||
-moz-background-size: 100%;
|
||||
-o-background-size: 100%;
|
||||
background-size: 100%;
|
||||
}
|
||||
.bottom {
|
||||
width: 200%;
|
||||
height: 15%;
|
||||
transition: transform 0.5s;
|
||||
h1 {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
p {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.left {
|
||||
height: 100%;
|
||||
width: 50%;
|
||||
background: #f4f4f4;
|
||||
position: relative;
|
||||
float: left;
|
||||
.details {
|
||||
padding: 5px;
|
||||
float: left;
|
||||
// width: calc(70% - 40px);
|
||||
}
|
||||
|
||||
}
|
||||
.right {
|
||||
width: 50%;
|
||||
background: #A6CDDE;
|
||||
color: white;
|
||||
float: right;
|
||||
height: 200%;
|
||||
overflow: hidden;
|
||||
.details {
|
||||
padding: 20px;
|
||||
float: right;
|
||||
width: calc(70% - 40px);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { ImageDocsComponent } from './image-docs.component';
|
||||
|
||||
describe('ImageDocsComponent', () => {
|
||||
let component: ImageDocsComponent;
|
||||
let fixture: ComponentFixture<ImageDocsComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ ImageDocsComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(ImageDocsComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,114 @@
|
||||
import { Component, OnInit, Input, SimpleChanges } from '@angular/core';
|
||||
import { PdTrigerService } from 'app/personal-discussion/pd-service/pd-triger.service';
|
||||
import { NotifierService } from 'angular-notifier';
|
||||
import { ImageCropComponent } from '../dialogue/image-crop/image-crop.component';
|
||||
import { MatDialog } from '@angular/material';
|
||||
|
||||
@Component({
|
||||
selector: 'app-image-docs',
|
||||
templateUrl: './image-docs.component.html',
|
||||
styleUrls: ['./image-docs.component.scss']
|
||||
})
|
||||
export class ImageDocsComponent implements OnInit {
|
||||
notifier:any;
|
||||
pdid:any
|
||||
formId:any;
|
||||
company_id:any;
|
||||
role_id:string;
|
||||
@Input() data_values:any;
|
||||
documentsAndFilesList: any=[];
|
||||
constructor(private _pd:PdTrigerService,notifier:NotifierService,private dialog: MatDialog) {
|
||||
this.notifier=notifier
|
||||
this.role_id=localStorage.getItem('user_role')
|
||||
// console.log(this.data_values)
|
||||
// this.pdid=this.data_values.pd_id;
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
// console.log(this.data_values)
|
||||
this.pdid=this.data_values.pdid;
|
||||
this.formId=this.data_values.form_id
|
||||
this.company_id=this.data_values.company_id
|
||||
this.retriveFile()
|
||||
}
|
||||
ngOnChanges(changes: SimpleChanges) {
|
||||
// console.log(this.data_values)
|
||||
|
||||
}
|
||||
|
||||
retriveFile() {
|
||||
this._pd.retriveFile(this.pdid, this.formId, 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(".");
|
||||
let DocumentsAndFiles = {
|
||||
'document_id': val.pd_document_id,
|
||||
'document_name': val.pd_document_name,
|
||||
'document_title': val.pd_document_title,
|
||||
'document': val.doc_url,
|
||||
'document_type': splitted[1] == 'pdf' ? 'pdf' : 'image',
|
||||
'is_show_report': val.is_show_report,
|
||||
'is_active':val.isactive ? val.isactive : ''
|
||||
}
|
||||
this.documentsAndFilesList.push(DocumentsAndFiles);
|
||||
|
||||
});
|
||||
console.log("document docs image",this.documentsAndFilesList)
|
||||
}
|
||||
}
|
||||
else {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
updateImage(image_arr){
|
||||
console.log(image_arr)
|
||||
let records= {
|
||||
"pd_document_id": image_arr.document_id,
|
||||
"pd_document_title": image_arr.document_title,
|
||||
"pd_document_name": image_arr.document_name,
|
||||
"is_show_report":image_arr.is_show_report,
|
||||
"fk_updatedby":'',
|
||||
"image": image_arr.document,
|
||||
"fk_pd_id":this.pdid,
|
||||
"isactive":''
|
||||
}
|
||||
if(image_arr.is_active == 1){
|
||||
records.isactive="0"
|
||||
}
|
||||
else{
|
||||
records.isactive="1"
|
||||
}
|
||||
this._pd.updatePDPhoto(records).subscribe(result=>{
|
||||
if(result.dataStatus){
|
||||
this.notifier.notify('success','Updated Successfully');
|
||||
this.documentsAndFilesList = [];
|
||||
this.retriveFile()
|
||||
}
|
||||
else{
|
||||
this.notifier.notify('warning','Something went wrong');
|
||||
}
|
||||
},err=>{console.log(err)})
|
||||
}
|
||||
imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
data: pic,
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh',
|
||||
height: '100%',
|
||||
width: '100%',
|
||||
});
|
||||
imageRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
if (dataresult == 1) {
|
||||
this.documentsAndFilesList = [];
|
||||
this.retriveFile();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -297,14 +297,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -325,13 +326,13 @@
|
||||
<div *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
*ngIf="doc.document_type == 'pdf';">-->
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
<mat-icon
|
||||
<!--<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -343,7 +344,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -84,6 +84,7 @@ export class LoanDetailsComponent implements OnInit {
|
||||
generalFormApplicantList:any = [];
|
||||
Owner_placeholder:string;
|
||||
address_placeholder: string;
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||
/** Constructor Of the Class */
|
||||
constructor(notifier: NotifierService,
|
||||
private fb: FormBuilder,
|
||||
@ -124,7 +125,7 @@ export class LoanDetailsComponent implements OnInit {
|
||||
this.Owner_placeholder='Name of Owner'
|
||||
this.address_placeholder="Address of Property"
|
||||
}
|
||||
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
documentsAndFilesList: any = [];
|
||||
/** init Fns */
|
||||
@ -343,7 +344,7 @@ export class LoanDetailsComponent implements OnInit {
|
||||
this.loanDetailsForm.controls['owner_name'].updateValueAndValidity();
|
||||
|
||||
}
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
|
||||
getM_EndUseofLoad() {
|
||||
@ -965,7 +966,7 @@ export class LoanDetailsComponent implements OnInit {
|
||||
}
|
||||
};
|
||||
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -1005,5 +1006,5 @@ export class LoanDetailsComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
@ -227,14 +227,15 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -256,12 +257,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -273,7 +274,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
|
||||
@ -40,6 +40,7 @@ export class NeighbourHoodComponent implements OnInit {
|
||||
existCompanyList: any =[];
|
||||
mergeCompanyApplicant: any=[];
|
||||
isOrganisationOwner: any=[];
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
// amtInwords : any = [];
|
||||
|
||||
// isOtherApplicant: any = [];
|
||||
@ -54,7 +55,8 @@ export class NeighbourHoodComponent implements OnInit {
|
||||
this.customer_segment_abbr = this.data.pdmaster_details.customer_segment_abbr;
|
||||
this.applicants = this.data.pdapplicants_detials;
|
||||
this.applicants = this.applicants.filter(appt=>appt.applicant_type != 2);
|
||||
this.applicants.push({'pd_co_applicant_id': 0,'applicant_name': "Others"})
|
||||
this.applicants.push({'pd_co_applicant_id': 0,'applicant_name': "Others"})
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
documentsAndFilesList: any = [];
|
||||
ngOnInit() {
|
||||
@ -106,7 +108,7 @@ export class NeighbourHoodComponent implements OnInit {
|
||||
// }
|
||||
// });
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -542,7 +544,7 @@ getOtherOrganisationOwner(value,i) {
|
||||
|
||||
ChdCtrls.controls.other_organisation_owner.updateValueAndValidity();
|
||||
}
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -582,5 +584,5 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ -155,14 +155,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -184,12 +185,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -201,7 +202,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -61,6 +61,7 @@ export class OtherIncomeComponent implements OnInit {
|
||||
existCompanyList: any = [];
|
||||
mergeCompanyApplicant: any = [];
|
||||
isIncomeEarnedBy: any = [];
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
// stringArr = [];
|
||||
constructor(notifier: NotifierService,
|
||||
private fb: FormBuilder,
|
||||
@ -82,6 +83,7 @@ export class OtherIncomeComponent implements OnInit {
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
this.applicants = this.applicants.filter(val => val.applicant_type == 0 || val.applicant_type == 1);
|
||||
// this.applicants.push({ 'pd_co_applicant_id': '0', 'applicant_name': 'Others' });
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -174,7 +176,7 @@ export class OtherIncomeComponent implements OnInit {
|
||||
//control.push(this.createDetail());
|
||||
}
|
||||
})
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
public initOtherincomeForm(): void {
|
||||
this.otherIncomeForm = this.fb.group({
|
||||
@ -447,7 +449,7 @@ export class OtherIncomeComponent implements OnInit {
|
||||
ChdCtrls.controls.others_income_earned_by.updateValueAndValidity();
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -487,6 +489,6 @@ export class OtherIncomeComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
}
|
||||
|
||||
@ -211,7 +211,8 @@
|
||||
</mat-tab>
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer>
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer>
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap">
|
||||
@ -302,7 +303,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -63,6 +63,7 @@ export class PersonalInfoComponent implements OnInit {
|
||||
public mainApplicantDetails :any=[];
|
||||
public coApplicantDetails :any=[];
|
||||
errorMessage:any;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
|
||||
constructor(notifier: NotifierService,private _fb: FormBuilder,private _pd: PdTrigerService , @Inject(MAT_DIALOG_DATA) public pd_all_details: any,private dialogRef: MatDialogRef<PersonalInfoComponent>) {
|
||||
@ -73,6 +74,7 @@ export class PersonalInfoComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
}
|
||||
public viewerOptions: any = {
|
||||
navbar: false,
|
||||
|
||||
@ -698,14 +698,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -727,12 +728,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -744,7 +745,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -68,6 +68,7 @@ export class ManageRentalVerificationComponent implements OnInit {
|
||||
documentsAndFilesList: any = [];
|
||||
SwalButtonText: string;
|
||||
SwalMessage: string;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
constructor(notifier: NotifierService, private _pd: PdTrigerService ,private _fb: FormBuilder, @Inject(MAT_DIALOG_DATA) public data: any,private dialogRef: MatDialogRef<ManageRentalVerificationComponent>,private dialog: MatDialog) {
|
||||
|
||||
@ -83,6 +84,7 @@ export class ManageRentalVerificationComponent implements OnInit {
|
||||
this.unitMeasurementList = this.data.masterData.unitMeasurementList;
|
||||
// console.log(this.mergeCompanyApplicant);
|
||||
// console.log(this.data.masterData.mergeCompanyApplicant);
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:''}
|
||||
|
||||
}
|
||||
|
||||
@ -184,7 +186,7 @@ export class ManageRentalVerificationComponent implements OnInit {
|
||||
});
|
||||
this.loadFormData(this.data.editData);
|
||||
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
|
||||
}
|
||||
|
||||
@ -1050,7 +1052,7 @@ export class ManageRentalVerificationComponent implements OnInit {
|
||||
}
|
||||
}
|
||||
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -1090,7 +1092,7 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
// validate all form group and form array fields
|
||||
validateAllFormFields(formGroup: any) {
|
||||
|
||||
@ -524,14 +524,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!--<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button class="date mr-1 mb-1 hover-icon" type="button" matTooltip="edit" (click)="imageCrop(doc)"
|
||||
matTooltipPosition="right">
|
||||
@ -553,12 +554,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -570,7 +571,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -58,6 +58,7 @@ export class StockComponent implements OnInit {
|
||||
public TGsufficientList: any = [{value:"yes",isdisplayvalue:"Yes",isdisabled:false},{value:"no",isdisplayvalue:"No",isdisabled:false},{value:"not applicable",isdisplayvalue:"Stock not required to be maintained",isdisabled:false}];
|
||||
public SPsufficientList: any = [{value:"yes",isdisplayvalue:"Yes",isdisabled:false},{value:"no",isdisplayvalue:"No",isdisabled:false},{value:"not applicable",isdisplayvalue:"Stock not required to be maintained",isdisabled:false}];
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: number; form_id: number; company_id: string; };
|
||||
|
||||
/** Constructor */
|
||||
constructor(notifier: NotifierService,
|
||||
@ -81,6 +82,7 @@ export class StockComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
pdf(fileURL){
|
||||
window.open(fileURL);
|
||||
@ -133,7 +135,7 @@ export class StockComponent implements OnInit {
|
||||
|
||||
this.getUOM();
|
||||
|
||||
this.retriveFile();
|
||||
//this.retriveFile();
|
||||
}
|
||||
|
||||
public initstockForms(record) {
|
||||
@ -1048,7 +1050,7 @@ export class StockComponent implements OnInit {
|
||||
// }
|
||||
// }
|
||||
|
||||
imageCrop(pic) {
|
||||
/* imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -1088,6 +1090,6 @@ retriveFile(){
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
|
||||
}
|
||||
@ -561,14 +561,15 @@
|
||||
|
||||
<mat-tab label="Docs">
|
||||
<ng-template matTabContent>
|
||||
<div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<app-image-docs [data_values]="image_doc_params"> </app-image-docs>
|
||||
<!-- <div ngxViewer *ngIf="documentsAndFilesList.length>0; else noFiles">
|
||||
<div fxLayout="row wrap" style="padding:20px;">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="20" class="m-gap p-gap" *ngFor="let doc of documentsAndFilesList">
|
||||
<div class="p-list-main mb-2" *ngIf="doc.document_type != 'pdf'">
|
||||
<div class="p-list">
|
||||
<div class="top">
|
||||
<!-- Thumbnail-->
|
||||
|
||||
<div class="thumbnail">
|
||||
<button mat-raised-button mat-icon-button
|
||||
class="date mr-1 mb-1 hover-icon" type="button"
|
||||
@ -593,12 +594,12 @@
|
||||
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
|
||||
fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"
|
||||
*ngIf="doc.document_type == 'pdf';">
|
||||
<!-- <a href="http://www.google.com" target="_blank"> -->
|
||||
|
||||
<mat-icon
|
||||
style="color: #e00201;font-size: 60px !important;width:inherit !important;"
|
||||
(click)="pdf(doc.document)">picture_as_pdf</mat-icon>
|
||||
<span class="d-block">{{doc.document_title}}</span>
|
||||
<!-- </a> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -610,7 +611,7 @@
|
||||
<mat-card-content>
|
||||
<p style="margin: 20px;">No Files</p>
|
||||
</mat-card-content>
|
||||
</ng-template>
|
||||
</ng-template>-->
|
||||
</ng-template>
|
||||
</mat-tab>
|
||||
|
||||
|
||||
@ -43,6 +43,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
titleList: any = [];
|
||||
companyRelationShipList: any = [];
|
||||
lender_short_name: any;
|
||||
image_doc_params: { pdid: string; form_id: number; company_id: string; };
|
||||
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
@ -61,7 +62,7 @@ export class SupplierInfoComponent 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.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
pdf(fileURL) {
|
||||
window.open(fileURL);
|
||||
@ -158,7 +159,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
// this.getPdSupplierFormDetails();
|
||||
this.getMasterDetails('COMPANYRELATIONSHIPS', 1);
|
||||
this.getMasterDetails('TITLES', 2);
|
||||
this.retriveFile();
|
||||
// this.retriveFile();
|
||||
}
|
||||
|
||||
initFormLoadDetails(record) {
|
||||
@ -749,7 +750,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
// }
|
||||
// ]
|
||||
// }
|
||||
imageCrop(pic) {
|
||||
/*imageCrop(pic) {
|
||||
// let arr = { 'pic_name':pic_name,'pic':pic,'from_id':this.form_id}
|
||||
pic.pdid = this.pdid;
|
||||
const imageRef = this.dialog.open(ImageCropComponent, {
|
||||
@ -789,5 +790,5 @@ export class SupplierInfoComponent implements OnInit {
|
||||
this.documentsAndFilesList = [];
|
||||
}
|
||||
});
|
||||
}
|
||||
}*/
|
||||
}
|
||||
@ -79,14 +79,44 @@
|
||||
|
||||
<div>
|
||||
<mat-card-title style="color:#e00201;">Lender Contact Details</mat-card-title>
|
||||
<mat-list>
|
||||
<mat-list >
|
||||
<div *ngIf="master.pd_contact_person != '' && master.pd_contact_person != null">
|
||||
<mat-list-item align="left" *ngIf="master.pd_contact_person" style="height:48px !important;">
|
||||
<i class="fa-1x fa fa-user"></i><small style="margin-left: 2%; font-size: inherit">{{master.pd_contact_person}}</small>
|
||||
</mat-list-item>
|
||||
<mat-list-item align="left" *ngIf="master.pd_contact_mobileno" style="height:48px !important;">
|
||||
<i class="fa-1x fa fa-phone"></i><small style="margin-left: 2%; font-size: inherit">{{master.pd_contact_mobileno}}</small>
|
||||
</mat-list-item>
|
||||
</mat-list>
|
||||
</div>
|
||||
<div *ngIf="master.lender_credit_person_name != '' && master.lender_credit_person_name != null">
|
||||
<!-- <mat-list-item> -->
|
||||
<mat-card-subtitle>Credit Person</mat-card-subtitle>
|
||||
<!-- </mat-list-item> -->
|
||||
<div fxLayout="row" fxFlex="100">
|
||||
<!-- <div > -->
|
||||
<div fxFlex="50" align="left">
|
||||
<i class="fa-1x fa fa-user"></i><small style="margin-left: 1%; font-size: inherit">{{master.lender_credit_person_name}}</small>
|
||||
</div>
|
||||
<div fxFlex="50" align="right">
|
||||
<i class="fa-1x fa fa-phone"></i><small style="margin-left: 1%; font-size: inherit">{{master.lender_credit_person_contact_mobileno}}</small>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
</div><br/>
|
||||
<div *ngIf="master.lender_sales_person_name != '' && master.lender_sales_person_name != null">
|
||||
<mat-card-subtitle>Sales Person</mat-card-subtitle><br/>
|
||||
<div fxFlex="row">
|
||||
<div fxFlex="100">
|
||||
<div fxFlex="50" align="left">
|
||||
<i class="fa-1x fa fa-user"></i><small style="margin-left: 2%; font-size: inherit">{{master.lender_sales_person_name}}</small>
|
||||
</div>
|
||||
<div fxFlex="50" align="right">
|
||||
<i class="fa-1x fa fa-phone"></i><small style="margin-left: 2%; font-size: inherit">{{master.lender_sales_contact_mobileno}}</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</mat-list>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
</mat-card>
|
||||
|
||||
@ -125,7 +125,8 @@ import { FuturePlansAndBusinessEnvironmentComponent } from './list-pd/start-pd/f
|
||||
import { ImageCropComponent } from './list-pd/start-pd/forms/dialogue/image-crop/image-crop.component';
|
||||
import {PurchaseCalculationComponent} from './list-pd/start-pd/forms/assessed-income/purchase-calculation/purchase-calculation.component'
|
||||
import { QueriesDocsComponent } from './list-pd/start-pd/forms/queries-docs/queries-docs.component';
|
||||
import {AngularSplitModule} from 'angular-split'
|
||||
import {AngularSplitModule} from 'angular-split';
|
||||
import { ImageDocsComponent } from './list-pd/start-pd/forms/image-docs/image-docs.component'
|
||||
|
||||
/**
|
||||
* Custom angular notifier options
|
||||
@ -172,7 +173,7 @@ const pdCustomNotifierOptions: NotifierOptions = {
|
||||
};
|
||||
|
||||
@NgModule({
|
||||
declarations: [TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent,PdCollectedDocsComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent, SearchRelationPipe, RupeeCurrencyFormatPipe, NumberToWordsPipe, DeleteRecordsCountPipe, BusinessAssetsInfoComponent, BusinessBankingDetailsComponent, SalesDetailsComponent, DailySalesDetailsComponent, SalesCalculationComponent, ManageSalesComponent, PurchaseDetailsComponent, BusinessExpenseDetailsComponent, HouseHoldDetailsComponent, OtherBusinessIncomeDetailsComponent, ManagePurchaseComponent, ManageBusinesExpenseComponent, ManageHouseHoldComponent, ManageOtherBusinessIncomeComponent, GrossProfitCalculationComponent, ManageDailySalesComponent, PdStatusChangeDialogueComponent, PdLocatedMapViewDirective, ViewLocationComponent, GetAnswerableFormsPipe, ConfirmAiDetailsComponent, RentalVerificationComponent, InitiateAdditionalPdComponent ,ManageDailyPurchaseComponent, DailyPurchaseDetailsComponent, ManageRentalVerificationComponent, FuturePlansAndBusinessEnvironmentComponent, ImageCropComponent,PurchaseCalculationComponent,QueriesDocsComponent],
|
||||
declarations: [TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent,PdCollectedDocsComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent, SearchRelationPipe, RupeeCurrencyFormatPipe, NumberToWordsPipe, DeleteRecordsCountPipe, BusinessAssetsInfoComponent, BusinessBankingDetailsComponent, SalesDetailsComponent, DailySalesDetailsComponent, SalesCalculationComponent, ManageSalesComponent, PurchaseDetailsComponent, BusinessExpenseDetailsComponent, HouseHoldDetailsComponent, OtherBusinessIncomeDetailsComponent, ManagePurchaseComponent, ManageBusinesExpenseComponent, ManageHouseHoldComponent, ManageOtherBusinessIncomeComponent, GrossProfitCalculationComponent, ManageDailySalesComponent, PdStatusChangeDialogueComponent, PdLocatedMapViewDirective, ViewLocationComponent, GetAnswerableFormsPipe, ConfirmAiDetailsComponent, RentalVerificationComponent, InitiateAdditionalPdComponent ,ManageDailyPurchaseComponent, DailyPurchaseDetailsComponent, ManageRentalVerificationComponent, FuturePlansAndBusinessEnvironmentComponent, ImageCropComponent,PurchaseCalculationComponent,QueriesDocsComponent, ImageDocsComponent],
|
||||
imports: [
|
||||
CommonModule,
|
||||
ManagePdRoutingModule,
|
||||
|
||||
@ -64,12 +64,13 @@
|
||||
|
||||
<div style="margin: 12px;">
|
||||
|
||||
<div *ngIf="reGenerateBtn" style="width: 1200px; height: 450px;">
|
||||
<div *ngIf="reGenerateBtn" style="width: auto; height: 455px;">
|
||||
<!-- {{pdf_src}} -->
|
||||
<!-- <pdf-viewer [src]="latestPDDetails.doc_uri" [original-size]="false" [page]="1">
|
||||
</pdf-viewer> -->
|
||||
<!-- <iframe width="100%" frameBorder="0" [src]="urlSafe" #IFrameContent id="iframeId" style="height: -webkit-fill-available;" seamless></iframe> -->
|
||||
<as-split direction="horizontal">
|
||||
<as-split-area >
|
||||
<as-split-area [size]="html_viewer_split_size">
|
||||
<as-split direction="vertical">
|
||||
<as-split-area >
|
||||
|
||||
@ -78,16 +79,18 @@
|
||||
</as-split-area>
|
||||
</as-split>
|
||||
</as-split-area>
|
||||
<!-- <as-split-area style="background-color:grey;" size="50" *ngIf="pdf_src !=''">
|
||||
<!-- <as-split-area style="background-color:grey;" [size]="pdf_viewer_split_size" *ngIf="pdf_src !=''">
|
||||
<as-split direction="vertical">
|
||||
<as-split-area>
|
||||
<pdf-viewer [src]="pdf_src" [zoom]="0.8"></pdf-viewer>
|
||||
<pdf-viewer [src]="pdf_src"
|
||||
[render-text]="false"
|
||||
style="display: block;" [zoom]="0.8"></pdf-viewer>
|
||||
|
||||
</as-split-area>
|
||||
</as-split>
|
||||
</as-split-area> -->
|
||||
</as-split>
|
||||
<button style="position:absolute;z-index:2;bottom:3px;" type="button" mat-raised-button mat-icon-button class="mr-1 ml-1 hover-icon" matTooltip="Preview" matTooltipPosition="above" (click)="getPDreportPDF()" ><mat-icon>remove_red_eye</mat-icon></button>
|
||||
<!-- <button style="position:absolute;z-index:2;bottom:3px;" type="button" mat-raised-button mat-icon-button class="mr-1 ml-1 hover-icon" matTooltip="Preview" matTooltipPosition="above" (click)="getPDreportPDF()" ><mat-icon>remove_red_eye</mat-icon></button> -->
|
||||
<!-- latestPDDetails.doc_uri -->
|
||||
</div>
|
||||
|
||||
|
||||
@ -21,6 +21,7 @@ import { environment } from 'environments/environment';
|
||||
import { QcNewComponent } from './qc-new/qc-new.component';
|
||||
|
||||
|
||||
|
||||
@Component({
|
||||
selector: 'app-qc-pd-report',
|
||||
templateUrl: './qc-pd-report.component.html',
|
||||
@ -63,7 +64,9 @@ export class QcPdReportComponent implements OnInit {
|
||||
apiUrl:string = environment.apiEndpoint;
|
||||
reportRandomString : string;
|
||||
arra:any;
|
||||
pdf_src:any='';
|
||||
pdf_src:any='assets/pdf.pdf';
|
||||
pdf_viewer_split_size:String='70'
|
||||
html_viewer_split_size:String='30'
|
||||
|
||||
private notifier: NotifierService;
|
||||
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
|
||||
@ -286,6 +289,7 @@ export class QcPdReportComponent implements OnInit {
|
||||
this.reGenerateBtn = data.records.is_original_report_created == 1 ? true : false;
|
||||
if(this.reGenerateBtn){
|
||||
this.getHTMLPDReport()
|
||||
this.getPDreportPDF()
|
||||
}
|
||||
// console.log(this.reGenerateBtn);
|
||||
}
|
||||
@ -470,13 +474,34 @@ export class QcPdReportComponent implements OnInit {
|
||||
this.listPDComponent.showListView(true);
|
||||
}
|
||||
getPDreportPDF(){
|
||||
let modifiedHtml=this.dataContainer.nativeElement.outerHTML;
|
||||
// console.log(this.dataContainer.nativeElement.outerHTML);
|
||||
this.pdf_src=''
|
||||
this.pdf_viewer_split_size='70'
|
||||
this.html_viewer_split_size='30'
|
||||
console.log("data datacontainer",this.dataContainer)
|
||||
let modifiedHtml=''
|
||||
if(this.dataContainer != undefined){
|
||||
modifiedHtml =this.dataContainer.nativeElement.outerHTML;
|
||||
}
|
||||
|
||||
console.log(this.dataContainer);
|
||||
let encryptReportRandomString = atob(this.route.snapshot.params['string']);
|
||||
this.pdTrigerService.getPDReportPDFpreview(encryptReportRandomString,this.startPD,modifiedHtml).subscribe(response=>{
|
||||
if(response['dataStatus']){
|
||||
// if(response['dataStatus']){
|
||||
// 'https://cors-anywhere.herokuapp.com/'
|
||||
this.pdf_src=response['link']
|
||||
}
|
||||
// window.open(this.pdf_src);
|
||||
console.log("pdf source",this.pdf_src)
|
||||
//}
|
||||
// setTimeout(()=>{
|
||||
// this.pdf_src='https://len24.s3.ap-south-1.amazonaws.com/pd1290/pd_reports/%20Vinoth%20Kumar.pdf?X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAJ3QDSPT3LDSWRYUQ%2F20190921%2Fap-south-1%2Fs3%2Faws4_request&X-Amz-Date=20190921T105502Z&X-Amz-SignedHeaders=host&X-Amz-Expires=1800&X-Amz-Signature=a31a8370400e95aeab91ea7fc266d02763539e277e801a69b91ea4d2bbd65bce'
|
||||
|
||||
// },5000)
|
||||
setTimeout(()=>{
|
||||
// this.pdf_src='assets/Vinoth.pdf'
|
||||
this.pdf_viewer_split_size='55'
|
||||
this.html_viewer_split_size='45'
|
||||
},9000)
|
||||
|
||||
})
|
||||
}
|
||||
changePDStatus(){
|
||||
|
||||
@ -629,6 +629,6 @@ export class QcService {
|
||||
return this._http.get(this.apiUrl+'getPDReportHTML/'+random_string+'/'+pd_id,{responseType: 'text'})
|
||||
}
|
||||
getPDReportPDFpreview(random_string,pd_id,htmlData){
|
||||
return this._http.post(this.apiUrl+'getPDReportPDFpreview/'+random_string+'/'+pd_id,{records:{"pdid":pd_id,"myData":htmlData}},{responseType:'json'})
|
||||
return this._http.post(this.apiUrl+'getPDReportPDFpreview/'+random_string+'/'+pd_id,{"myData":htmlData,responseType:'json'})
|
||||
}
|
||||
}
|
||||
|
||||
@ -255,6 +255,11 @@
|
||||
<td mat-cell *matCellDef="let row">
|
||||
<span *ngIf="row.application_id" mat-line>{{row.application_id}}</span> </td>
|
||||
</ng-container>
|
||||
<ng-container matColumnDef="pd_sno">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Lender Sr No. </th>
|
||||
<td mat-cell *matCellDef="let row">
|
||||
<span *ngIf="row.pd_sno" mat-line>{{row.pd_sno}}</span> </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="sineedge_ref_no">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Sineedge Ref No </th>
|
||||
|
||||
@ -35,6 +35,7 @@ export class PdMisComponent implements OnInit {
|
||||
displayedColumns = ['serialno',
|
||||
'applicant',
|
||||
'application_id',
|
||||
'pd_sno',
|
||||
'sineedge_ref_no',
|
||||
'created_on',
|
||||
'name_of_underwriter',
|
||||
|
||||
Loading…
Reference in New Issue
Block a user