Fairoj : Credit manager issue fixes and customer img recapture api success msg displayed
This commit is contained in:
parent
9204bc657b
commit
e705d273e0
@ -161,7 +161,7 @@ export class QueriesDocsComponent implements OnInit {
|
||||
retrieved_data.pdid=this.pdid
|
||||
retrieved_data.formid="24"
|
||||
retrieved_data.fk_createdby=this.awsService.getlocale();
|
||||
retrieved_data.addtional_requirements[0].name=''
|
||||
retrieved_data.hasOwnProperty('addtional_requirements') ? retrieved_data.addtional_requirements[0].name='' : ''
|
||||
retrieved_data.hasOwnProperty('link') ? retrieved_data.link : retrieved_data.link=''
|
||||
// let geoCoords
|
||||
// if(retrieved_data.link == ''){
|
||||
@ -191,6 +191,7 @@ export class QueriesDocsComponent implements OnInit {
|
||||
})
|
||||
}
|
||||
if(retrieved_data.hasOwnProperty('covid_section') && retrieved_data.covid_section) {
|
||||
console.log(retrieved_data.covid_section)
|
||||
this.covidAnswers = retrieved_data.covid_section
|
||||
|
||||
}
|
||||
@ -357,7 +358,10 @@ export class QueriesDocsComponent implements OnInit {
|
||||
return;
|
||||
}
|
||||
}
|
||||
let formParams:any;
|
||||
let formParams:any ={ parent_pdid:this.parent_pdid,
|
||||
formid:"24",
|
||||
pdid:this.pdid,
|
||||
fk_createdby:this.awsService.getlocale(),};
|
||||
this.disableAfterSubmit=true
|
||||
if((this.queries_docs.length > 0 || this.docs_array_value.length > 0)) {
|
||||
formParams = this.docsCollectedForm.value
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
import { Component, OnInit, ViewChild, ElementRef, Inject } from '@angular/core';
|
||||
import { MatDialogRef, MatDialog, MAT_DIALOG_DATA } from '@angular/material';
|
||||
import { QcService } from '../qc-service/qc.service';
|
||||
import { NotifierService } from 'angular-notifier';
|
||||
|
||||
@Component({
|
||||
selector: 'app-qc-cus-images',
|
||||
@ -14,10 +15,13 @@ export class QcCusImagesComponent implements OnInit {
|
||||
current_index: any;
|
||||
@ViewChild('dummy_img_more') dummyImgMoreRef:ElementRef
|
||||
imgReCaptureBucket: any[] =[];
|
||||
notifier: NotifierService;
|
||||
constructor(private apiService:QcService,
|
||||
private dialogRef: MatDialogRef<QcCusImagesComponent>,
|
||||
private dialog: MatDialog,
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) { }
|
||||
private dialog: MatDialog, notifier:NotifierService,
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
this.notifier = notifier
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
// this.records = JSON.parse(this.records)
|
||||
@ -50,14 +54,20 @@ export class QcCusImagesComponent implements OnInit {
|
||||
// }
|
||||
}
|
||||
else{
|
||||
let msgObj ={title:'',subtitle:result.msg?result.msg : 'Invalid Link',is_homebtn:false,message:'The requested url is Invalid. Please contant info@pdgenie.com'}
|
||||
this.goToErrorComponent(msgObj)
|
||||
// this.records.is_loaded = false
|
||||
this.imageData =[]
|
||||
this.notifier.notify('error',result.hasOwnProperty('msg') && result.msg ?result.msg : 'Something went wrong try again later!!');
|
||||
// let msgObj ={title:'',subtitle:result.msg?result.msg : 'Invalid Link',is_homebtn:false,message:'The requested url is Invalid. Please contant info@pdgenie.com'}
|
||||
// this.goToErrorComponent(msgObj)
|
||||
}
|
||||
|
||||
},err=>{
|
||||
|
||||
let msgObj ={title:'404',subtitle:'Not Found',is_homebtn:false,message:'The requested url returns 404. Please check your internet connection'}
|
||||
this.goToErrorComponent(msgObj)
|
||||
console.log(err)
|
||||
// this.records.is_loaded = false
|
||||
this.imageData =[]
|
||||
this.notifier.notify('error','Network Error. Please check your internet connection!!');
|
||||
// let msgObj ={title:'404',subtitle:'Not Found',is_homebtn:false,message:'The requested url returns 404. Please check your internet connection'}
|
||||
// this.goToErrorComponent(msgObj)
|
||||
})
|
||||
}
|
||||
goToErrorComponent(msgObj) {
|
||||
@ -261,7 +271,19 @@ openBase64(url) {
|
||||
submitQcImages() {
|
||||
console.log(this.imgReCaptureBucket,JSON.stringify(this.imgReCaptureBucket))
|
||||
this.apiService.auditSmartPDImages(this.imgReCaptureBucket).subscribe(res=>{
|
||||
if(res['dataStatus']) {
|
||||
this.notifier.notify('info','Submitted successfully..');
|
||||
setTimeout(()=>{
|
||||
this.dialogRef.close()
|
||||
},2000)
|
||||
}
|
||||
else {
|
||||
this.notifier.notify('warning',res.hasOwnProperty('msg') && res['msg'] ? res['msg'] : 'Something went wrong try again later!!')
|
||||
}
|
||||
|
||||
},err=>{
|
||||
console.log(err);
|
||||
this.notifier.notify('error','Network Error. Please check your internet connection')
|
||||
})
|
||||
}
|
||||
clearSelected() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user