mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 13:02:56 +00:00
Fix merge
This commit is contained in:
@@ -100,9 +100,6 @@
|
||||
<ion-footer class="display-none-{{showAside}} ion-no-border">
|
||||
<div class="buttons">
|
||||
<button class="btn-cancel" shape="round" (click)="emendTask(loadedEvent.serialNumber)">Adicionar Nota</button>
|
||||
<ion-menu-button (click)="openMenu()" autoHide="false">
|
||||
<ion-icon name="ellipsis-vertical-outline"></ion-icon>
|
||||
</ion-menu-button>
|
||||
<button class="btn-ok" shape="round" (click)="approveTask(loadedEvent.serialNumber)">Aprovar</button>
|
||||
<button hidden class="btn-delete" shape="round" (click)="rejectTask(loadedEvent.serialNumber)">Rejeitar</button>
|
||||
</div>
|
||||
|
||||
@@ -106,18 +106,7 @@ export class ApproveEventPage implements OnInit {
|
||||
}); */
|
||||
}
|
||||
|
||||
async emendTask(serialNumber:string){
|
||||
/* console.log('Emendar'); */
|
||||
this.menu.close();
|
||||
|
||||
try {
|
||||
await this.openEmendMessageModal(serialNumber);
|
||||
this.modalController.dismiss(null);
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
async rejectTask(serialNumber:string) {
|
||||
|
||||
@@ -158,23 +147,22 @@ export class ApproveEventPage implements OnInit {
|
||||
});
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
openMenu() {
|
||||
this.menu.open();
|
||||
}
|
||||
|
||||
async openEmendMessageModal(serialNumber:string) {
|
||||
async emendTask(serialNumber:string){
|
||||
console.log('Desktop');
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: EmendMessageModalPage,
|
||||
componentProps:{
|
||||
},
|
||||
cssClass: 'emend-message-modal',
|
||||
backdropDismiss: false
|
||||
});-
|
||||
});
|
||||
|
||||
await modal.present();
|
||||
|
||||
modal.onDidDismiss().then( async (res) => {
|
||||
modal.onDidDismiss()
|
||||
.then( async (res) => {
|
||||
console.log(res.data);
|
||||
|
||||
if(res.data !== ''){
|
||||
@@ -184,24 +172,23 @@ export class ApproveEventPage implements OnInit {
|
||||
"ReviewUserComment": res.data,
|
||||
}
|
||||
}
|
||||
console.log(body);
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise()
|
||||
//this.router.navigate(['/home/gabinete-digital/event-list']);
|
||||
this.goToEventsToApprove();
|
||||
this.toastService.successMessage()
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
|
||||
console.log(body);
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise();
|
||||
this.toastService.successMessage('Pedido enviado');
|
||||
this.close();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest();
|
||||
}
|
||||
}
|
||||
else{
|
||||
//this.alertService.presentAlert('Operação cancelada!');
|
||||
}
|
||||
});
|
||||
|
||||
//this.openEmendMessageModal(serialNumber);
|
||||
//this.goBack();
|
||||
}
|
||||
|
||||
goToEventsToApprove(){
|
||||
@@ -237,5 +224,4 @@ export class ApproveEventPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user