put loader in gabinete method despachos and despachos-pr

This commit is contained in:
EQUILIBRIUM\hirondino.van-dunem
2022-06-20 14:21:06 +01:00
parent 53ff43c05b
commit a42b336133
2 changed files with 7 additions and 3 deletions
@@ -394,12 +394,14 @@ export class DespachoPrPage implements OnInit {
}
sendExpedienteToPending() {
const loader = this.toastService.loading()
this.processes.SetTaskToPending(this.serialNumber).subscribe(res => {
this.popoverController.dismiss('close')
this.toastService._successMessage('Processo enviado para pendentes')
this.goBack()
loader.remove()
}, () => {
loader.remove()
this.toastService._badRequest('Processo não encontrado')
});
}
@@ -387,15 +387,17 @@ export class DespachoPage implements OnInit {
}
async sendExpedienteToPending() {
const loader = this.toastService.loading()
this.despachoService.sendExpedienteToPending(this.serialnumber).subscribe(res => {
this.goBack();
loader.remove()
this.toastService.successMessage()
},
error => {
loader.remove()
this.toastService.badRequest("Processo não enviado para despacho")
});
// loader.remove()
}
async openAddNoteModal(actionName: string) {