offer cancel

This commit is contained in:
CHIEFSOFT\ameye
2023-12-11 11:35:31 -05:00
parent 0411363a31
commit 8c7b92e027
@@ -107,7 +107,8 @@ export class MyjobOffersComponent implements OnInit {
job_uid: string,
offer_code: string,
mode: number,
extend_days:number
extend_days:number,
reason:string
};
async pendingJobExtend(){
@@ -119,7 +120,8 @@ export class MyjobOffersComponent implements OnInit {
job_uid: this.currentJobSelected.job_uid,
offer_code: this.currentJobSelected .offer_code,
mode: 200,
extend_days: 2
extend_days: 2,
reason:''
};
const alert = await this.alertController.create({
@@ -166,7 +168,8 @@ pendingActionResult:string='';
job_uid: this.currentJobSelected.job_uid,
offer_code: this.currentJobSelected .offer_code,
mode: 200,
extend_days: 0
extend_days: 0,
reason:''
};
const alert = await this.alertController.create({
header: "Send Details.",
@@ -202,6 +205,19 @@ pendingActionResult:string='';
}
//
async pendingJobCancel(){
this.reqData = {
action:13043,
member_id: this.sessionDataProviderService.member_id,
uid: this.sessionDataProviderService.member_uid,
sessionid: this.sessionDataProviderService.session,
job_uid: this.currentJobSelected.job_uid,
offer_code: this.currentJobSelected .offer_code,
mode: 200,
extend_days: 0,
reason:'Cancelled from app.'
};
const alert = await this.alertController.create({
header: "Log out",
message: "Confirm you are ready to log out now.",
@@ -214,10 +230,19 @@ pendingActionResult:string='';
},
},
{
text: "Log out",
text: "Cancel Offer",
handler: () => {
// this.sessionDataProviderService.DestroySessionOnLogout();
// this.router.navigate(['logout']);
this.wrenchService.pendingJobCancel(this.reqData).subscribe(
res => {
if (res?.internal_return > 0){
this.pendingActionResult = "Offer Cancelled,";
setTimeout(()=>{
this.setCloseModal();
this.pendingActionResult ='';
},3000);
}
}
);
},
},
],