PD report and two other buttons hided and credit manager image capture issue

This commit is contained in:
venbatechnologies@gmail.com 2020-10-17 16:10:10 +05:30
parent bc74e60d95
commit 54c9466a71
3 changed files with 73 additions and 73 deletions

View File

@ -791,7 +791,7 @@
<div > <div >
<app-dynamic-docs-form [docs_array_value] = "docs_tobe_collect" [doc_answers] = "creditManagerAnswer" [form_group] = "getQuestionControl().at(6)" <app-dynamic-docs-form [docs_array_value] = "docs_tobe_collect" [doc_answers] = "creditManagerAnswer" [form_group] = "getQuestionControl().at(6)"
(eventCapturePic) ="capturePic($event.controls,$event.img_name,$event.form_id)"></app-dynamic-docs-form> (eventCapturePic) ="captureControls($event.controls,$event.img_name,$event.form_id)"></app-dynamic-docs-form>
</div> </div>
<div class="mat-button-div"> <div class="mat-button-div">

View File

@ -10,9 +10,9 @@
<strong> {{master.vendor_status==pdStatusCheck.QC_COMPLETED ? 'QC Completed' : master.vendor_status==pdStatusCheck.ADD_ON_PENDING ? 'Addon Pending' : master.vendor_status | titlecase}}</strong> <strong> {{master.vendor_status==pdStatusCheck.QC_COMPLETED ? 'QC Completed' : master.vendor_status==pdStatusCheck.ADD_ON_PENDING ? 'Addon Pending' : master.vendor_status | titlecase}}</strong>
</button> </button>
<button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="editPdMaster(master)" matTooltipPosition="above" matTooltip="Edit PD Master"><mat-icon>edit</mat-icon></button> <!-- <button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="editPdMaster(master)" matTooltipPosition="above" matTooltip="Edit PD Master"><mat-icon>edit</mat-icon></button> -->
<button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Trigger" matTooltipPosition="above" (click)="directTriggerPD(mandatoryFieldsValidations,master)"><mat-icon>flash_on</mat-icon></button> <!-- <button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Trigger" matTooltipPosition="above" (click)="directTriggerPD(mandatoryFieldsValidations,master)"><mat-icon>flash_on</mat-icon></button> -->
<button *ngIf="roleAccessDetails.reports && master.pd_type_name && currentPDStatus==pdStatusCheck.QC_COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="PD Report" matTooltipPosition="above" (click)="getPDIDReport(viewID)"><mat-icon>ballot</mat-icon></button> <!-- <button *ngIf="roleAccessDetails.reports && master.pd_type_name && currentPDStatus==pdStatusCheck.QC_COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="PD Report" matTooltipPosition="above" (click)="getPDIDReport(viewID)"><mat-icon>ballot</mat-icon></button> -->
<span *ngIf="!is_from_link"><button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="above" (click)="loadPdListCompoent()"><mat-icon>close</mat-icon></button></span> <span *ngIf="!is_from_link"><button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="above" (click)="loadPdListCompoent()"><mat-icon>close</mat-icon></button></span>
</div> </div>
</div> </div>

View File

@ -243,47 +243,47 @@ export class ViewPdComponent implements OnInit, OnDestroy {
// window.open(concat_url, '_blank'); // window.open(concat_url, '_blank');
// } // }
editPdMaster(masterData: any, flag) { // editPdMaster(masterData: any, flag) {
let record = { // let record = {
"records": masterData, // "records": masterData,
"applicantLength": this.pdApplicantData.length // "applicantLength": this.pdApplicantData.length
} // }
const dialogPDMaster = this.dialog.open(EditPdMasterComponent, { // const dialogPDMaster = this.dialog.open(EditPdMasterComponent, {
data: record, // data: record,
position: { right: '0' }, // position: { right: '0' },
width: '80%', // width: '80%',
disableClose: true // disableClose: true
}); // });
dialogPDMaster.afterOpen() // dialogPDMaster.afterOpen()
.subscribe(dataresult => { // .subscribe(dataresult => {
if (flag == 1) { // if (flag == 1) {
let ffd: any = []; // let ffd: any = [];
this.FilteredFieldNames.forEach(field => { // this.FilteredFieldNames.forEach(field => {
if(field != undefined){ // if(field != undefined){
ffd.push(field.frontEnd_FieldName); // ffd.push(field.frontEnd_FieldName);
} // }
});
// this.notifier.notify('info', 'Please Fill ' + ffd.join(' , ') + ' Fields.!');
Swal({
title: 'Please complete the below details',
confirmButtonColor: "red",
// html:true,
//text:'Please Fill' + ffd.forEach(data=>{ data }) + ' ! ',
text: ffd.join(' , ')
});
// Swal({
// title: "HTML <small>Title</small>!",
// text: "...<div class='row my_tracking_swal'>" + flag + "</div>...",
// }); // });
}
});
dialogPDMaster.afterClosed().subscribe(dataresult => {
this.viewPdDetails(this.viewID) // // this.notifier.notify('info', 'Please Fill ' + ffd.join(' , ') + ' Fields.!');
}); // Swal({
} // title: 'Please complete the below details',
// confirmButtonColor: "red",
// // html:true,
// //text:'Please Fill' + ffd.forEach(data=>{ data }) + ' ! ',
// text: ffd.join(' , ')
// });
// // Swal({
// // title: "HTML <small>Title</small>!",
// // text: "...<div class='row my_tracking_swal'>" + flag + "</div>...",
// // }) ;
// }
// });
// dialogPDMaster.afterClosed().subscribe(dataresult => {
// this.viewPdDetails(this.viewID)
// });
// }
editPdApplicant(applicantData: any,CSAbbr : any) { editPdApplicant(applicantData: any,CSAbbr : any) {
let setPdDetails = { let setPdDetails = {
"pdID": this.viewID, "pdID": this.viewID,
@ -444,10 +444,10 @@ export class ViewPdComponent implements OnInit, OnDestroy {
}); });
} }
getPDIDReport(pdID: any) { // getPDIDReport(pdID: any) {
this.destroyType = 3; // this.destroyType = 3;
this.router.navigate(['../../../pd_report', pdID,this.masterRandomString], { relativeTo: this.route }); // this.router.navigate(['../../../pd_report', pdID,this.masterRandomString], { relativeTo: this.route });
} // }
// // direct trigger the pd // // direct trigger the pd
// directTriggerPD(data: any,masterdetail : any){ // directTriggerPD(data: any,masterdetail : any){
@ -484,36 +484,36 @@ export class ViewPdComponent implements OnInit, OnDestroy {
// direct trigger the pd // direct trigger the pd
directTriggerPD(data: any, masterdetail: any) { // directTriggerPD(data: any, masterdetail: any) {
let pdid = masterdetail.pd_id; // let pdid = masterdetail.pd_id;
let random_string=masterdetail.random_string // let random_string=masterdetail.random_string
let getValues = data.filter(val => val).map(Val => Val); // let getValues = data.filter(val => val).map(Val => Val);
this.FilteredFieldNames = getValues.map(x => { // this.FilteredFieldNames = getValues.map(x => {
let findIndex = this.localMandatoryFields.map(val => val.backEnd_FieldName).indexOf(x); // let findIndex = this.localMandatoryFields.map(val => val.backEnd_FieldName).indexOf(x);
return this.localMandatoryFields[findIndex]; // return this.localMandatoryFields[findIndex];
}); // });
if (data.length > 0) { // if (data.length > 0) {
this.localcount = 1; // this.localcount = 1;
this.editPdMaster(masterdetail, this.localcount); // this.editPdMaster(masterdetail, this.localcount);
} // }
else { // else {
let lenderMasterArray = { "pd_id": pdid,random_string:random_string } // let lenderMasterArray = { "pd_id": pdid,random_string:random_string }
this._pd.editPdMasterDetails(lenderMasterArray, this.pdStatusCheck.TRIGGERED).subscribe(result => { // this._pd.editPdMasterDetails(lenderMasterArray, this.pdStatusCheck.TRIGGERED).subscribe(result => {
if (result.status == 200) { // if (result.status == 200) {
this.notifier.notify('success', 'PD Status Updated.'); // this.notifier.notify('success', 'PD Status Updated.');
this.viewPdDetails(this.viewID); // this.viewPdDetails(this.viewID);
} // }
else { // else {
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!'); // this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
} // }
}, error => { // }, error => {
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!'); // this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
}); // });
} // }
} // }
// this is for initiate additional pd // this is for initiate additional pd
initiateAddtionalPD(parentData: any, childData: any, type: boolean){ initiateAddtionalPD(parentData: any, childData: any, type: boolean){