Is smc pd flag : ps

This commit is contained in:
VE10-Sanjeev 2022-09-09 22:36:03 +05:30
parent 5ecb86506c
commit eba16d35ad
2 changed files with 22 additions and 6 deletions

View File

@ -129,10 +129,15 @@ export class PdStatusChangeDialogueComponent implements OnInit {
else else
{ {
let update_status = { let update_status : any = {
"pd_id":this.data.pdid, "pd_id":this.data.pdid,
"random_string":this.data.random_string "random_string":this.data.random_string
}; };
// sconsole.log("i am called here . ");
if(this.data.pd_status=='COMPLETED'){
update_status.is_this_smc_pd = 1;
}
this.pd.editPdMasterDetails(update_status, status).subscribe(result => { this.pd.editPdMasterDetails(update_status, status).subscribe(result => {
if (result.status == 200) { if (result.status == 200) {
this.dialogRef.close({update_status:true}); this.dialogRef.close({update_status:true});

View File

@ -320,7 +320,9 @@ export class PdTrigerService {
editPdMasterDetails(editData: any, status: string): Observable<any> { editPdMasterDetails(editData: any, status: string): Observable<any> {
editData.pd_status = status; editData.pd_status = status;
editData.fk_updatedby = this._aws.getlocale(); editData.fk_updatedby = this._aws.getlocale();
// console.log("i am 1",editData);
// editData.updatedon = currentdate; // editData.updatedon = currentdate;
// return this._http.post<any>("http://localhost/AWSEC2/sparqapi/api/updatePDMaster", { records: editData })
return this._http.post<any>(this.apiUrl + "updatePDMaster", { records: editData }) return this._http.post<any>(this.apiUrl + "updatePDMaster", { records: editData })
.pipe( .pipe(
@ -353,8 +355,9 @@ export class PdTrigerService {
// initiate address for pd process // initiate address for pd process
initiateAddressPdProcess(updateDate: any): Observable<any> { initiateAddressPdProcess(updateDate: any): Observable<any> {
updateDate.fk_updatedby = this._aws.getlocale(); updateDate.fk_updatedby = this._aws.getlocale();
console.log("i am 2",updateDate);
// editData.updatedon = currentdate; // editData.updatedon = currentdate;
return this._http.post<any>(this.apiUrl + "updatePDMaster", { records: updateDate }) return this._http.post<any>("http://localhost/AWSEC2/sparqapi/api/updatePDMaster", { records: updateDate })
.pipe( .pipe(
catchError(this.handleError('operation', [])) catchError(this.handleError('operation', []))
@ -562,8 +565,9 @@ export class PdTrigerService {
// pd review status update details // pd review status update details
pdReviewStatusUpdate(editData: any): Observable<any> { pdReviewStatusUpdate(editData: any): Observable<any> {
editData.fk_updatedby = this._aws.getlocale(); editData.fk_updatedby = this._aws.getlocale();
console.log("i am 3",editData);
// editData.updatedon = currentdate; // editData.updatedon = currentdate;
return this._http.post<any>(this.apiUrl + "updatePDMaster", { records: editData }) return this._http.post<any>("http://localhost/AWSEC2/sparqapi/api/updatePDMaster", { records: editData })
.pipe( .pipe(
catchError(this.handleError('operation', [])) catchError(this.handleError('operation', []))
@ -943,10 +947,14 @@ generatePDReportPDF(pdId: any): Observable<any> {
return this._http.post<any>(this.apiUrl + "generatePDReportPDF", { "records": pdId }); return this._http.post<any>(this.apiUrl + "generatePDReportPDF", { "records": pdId });
} }
archivePDImages(Dtl : any): Observable<any> { archivePDImages(Dtl : any): Observable<any> {
return this._http.post<any>(this.apiUrl + "archivePDSMCImages", { "records": Dtl }); return this._http.post<any>("http://localhost/AWSEC2/sparqapi/api/archivePDSMCImages", { "records": Dtl });
// return this._http.post<any>(this.apiUrl + "archivePDSMCImages", { "records": Dtl });
} }
photoPDFDownload(params:any): Observable<any>{ photoPDFDownload(params:any): Observable<any>{
return this._http.post<any>(this.apiUrl + "smcPhotoPDFDownload", { "records": params });
return this._http.post<any>("http://localhost/AWSEC2/sparqapi/api/smcPhotoPDFDownload", { "records": params });
// return this._http.post<any>(this.apiUrl + "smcPhotoPDFDownload", { "records": params });
} }
checkExistPDDetails(datas,entity_id){ checkExistPDDetails(datas,entity_id){
return this._http.post(this.apiUrl+'checkExistPDDetails',{records:datas,client:entity_id}) return this._http.post(this.apiUrl+'checkExistPDDetails',{records:datas,client:entity_id})
@ -1068,7 +1076,10 @@ loadTemplate(form_id) {
// if(users.user_role != '19'){ // if(users.user_role != '19'){
// apiName = 'uploadCreditPDDataToCETApp'; // apiName = 'uploadCreditPDDataToCETApp';
// } // }
return this._http.get<any[]>(this.apiUrl +"uploadCreditPDDataToCETApp/"+id); return this._http.get<any[]>(this.apiUrl+'uploadCreditPDDataToCETApp/'+id)
.pipe(
catchError(this.handleError('operation', []))
);
// let apiName = "http://localhost/AWSEC2/sparqapi/api/uploadCreditPDDataToCETApp"; // let apiName = "http://localhost/AWSEC2/sparqapi/api/uploadCreditPDDataToCETApp";
// return this._http.get<any[]>(apiName+"/"+id); // return this._http.get<any[]>(apiName+"/"+id);
} }