diff --git a/.gitignore b/.gitignore index 41f6bb494..9796ab682 100644 --- a/.gitignore +++ b/.gitignore @@ -37,7 +37,7 @@ npm-debug.log* /android /package-lock.json - + src/app/architect/ src/environments/environment.e2e.ts .env @@ -51,4 +51,6 @@ src/app/store/notification.service.ts src/assets/www/pdfjs/web/compressed.tracemonkey-pldi-09.pdf.pdf node_modules_ -node_modules__ \ No newline at end of file +node_modules__ +plugins_ +ios diff --git a/src/app/home/home-routing.module.ts b/src/app/home/home-routing.module.ts index 564db5b3e..996e1b413 100644 --- a/src/app/home/home-routing.module.ts +++ b/src/app/home/home-routing.module.ts @@ -400,7 +400,7 @@ const routes: Routes = [ loadChildren: ()=> import('../pages/inactivity/inactivity.module').then(m => m.InactivityPageModule) }, ], - canActivate: [InactivityGuard] + // canActivate: [InactivityGuard] }, ]; diff --git a/src/app/modals/create-process/create-process.page.ts b/src/app/modals/create-process/create-process.page.ts index a2ef20d21..9e65782ad 100644 --- a/src/app/modals/create-process/create-process.page.ts +++ b/src/app/modals/create-process/create-process.page.ts @@ -291,7 +291,7 @@ export class CreateProcessPage implements OnInit { this.modalController.dismiss(); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() @@ -319,10 +319,10 @@ export class CreateProcessPage implements OnInit { } this.modalController.dismiss(); - this.toastService.successMessage('Pedido de Parecer enviado'); + this.toastService._successMessage('Pedido de Parecer enviado'); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() } @@ -344,10 +344,10 @@ export class CreateProcessPage implements OnInit { await this.pedidoService.taskCompleteDeferimento({serialNumber:this.task.serialNumber}).toPromise(); this.modalController.dismiss(); - this.toastService.successMessage('Pedido de Deferimento criado'); + this.toastService._successMessage('Pedido de Deferimento criado'); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() @@ -376,16 +376,16 @@ export class CreateProcessPage implements OnInit { await this.despachoService.CompleteTask({serialNumber: this.task.serialNumber}).toPromise(); this.modalController.dismiss(); - this.toastService.successMessage('Despacho criado'); + this.toastService._successMessage('Despacho criado'); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { //loader.remove(); } } else{ this.validateField = true; - this.toastService.badRequest('Por favor adicione uma descrição'); + this.toastService._badRequest('Por favor adicione uma descrição'); } loader.remove(); break; @@ -411,10 +411,10 @@ export class CreateProcessPage implements OnInit { } this.modalController.dismiss(); - this.toastService.successMessage('Pedido de Parecer criado'); + this.toastService._successMessage('Pedido de Parecer criado'); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() } @@ -436,10 +436,10 @@ export class CreateProcessPage implements OnInit { await this.pedidoService.taskCompleteDeferimento({serialNumber:this.task.serialNumber}).toPromise(); this.modalController.dismiss(); - this.toastService.successMessage('Pedido de Deferimento criado'); + this.toastService._successMessage('Pedido de Deferimento criado'); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() } @@ -494,9 +494,9 @@ export class CreateProcessPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); - this.toastService.successMessage(message); + this.toastService._successMessage(message); } catch (error) { - this.toastService.badRequest('Processo não efectuado'); + this.toastService._badRequest('Processo não efectuado'); } finally { loader.remove() } diff --git a/src/app/modals/dar-parecer/dar-parecer.page.ts b/src/app/modals/dar-parecer/dar-parecer.page.ts index a649265cb..e31ff5945 100644 --- a/src/app/modals/dar-parecer/dar-parecer.page.ts +++ b/src/app/modals/dar-parecer/dar-parecer.page.ts @@ -69,9 +69,9 @@ export class DarParecerPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); this.modalController.dismiss(); - this.toastService.successMessage('Parecer enviado'); + this.toastService._successMessage('Parecer enviado'); } catch (error) { - this.toastService.badRequest("Parecer não solicitado"); + this.toastService._badRequest("Parecer não solicitado"); } finally { loader.remove() } diff --git a/src/app/modals/delegar/delegar.page.ts b/src/app/modals/delegar/delegar.page.ts index 93304a383..b72e269e1 100644 --- a/src/app/modals/delegar/delegar.page.ts +++ b/src/app/modals/delegar/delegar.page.ts @@ -88,10 +88,10 @@ export class DelegarPage implements OnInit { async saveTask() { if(this.taskParticipants.length < 1){ - this.toastService.badRequest("Selecione um destinatário"); + this.toastService._badRequest("Selecione um destinatário"); } else if(this.taskParticipants.length > 1){ - this.toastService.badRequest("Selecione apenas um destinatário"); + this.toastService._badRequest("Selecione apenas um destinatário"); } else { let body = { @@ -109,11 +109,11 @@ export class DelegarPage implements OnInit { this.processes.DelegateTask(body).subscribe(res=>{ console.log(res); - this.toastService.successMessage('Processo delegado') + this.toastService._successMessage('Processo delegado') this.close(); }, (error)=>{ - this.toastService.badRequest("Processo não delegado") + this.toastService._badRequest("Processo não delegado") }, ()=>{ loader.remove() diff --git a/src/app/modals/document-set-up-meeting/document-set-up-meeting.page.ts b/src/app/modals/document-set-up-meeting/document-set-up-meeting.page.ts index 3d2429b35..4e1798522 100644 --- a/src/app/modals/document-set-up-meeting/document-set-up-meeting.page.ts +++ b/src/app/modals/document-set-up-meeting/document-set-up-meeting.page.ts @@ -224,11 +224,11 @@ export class DocumentSetUpMeetingPage implements OnInit { this.eventService.create({ body: postEvent, calendar: this.postData.CalendarName }).subscribe(async (respose) => { laoder.remove() - this.toastService.successMessage('Reunião criada') + this.toastService._successMessage('Reunião criada') this.modalController.dismiss() }, (error) => { laoder.remove() - this.toastService.badRequest('Não foi possível marcar a reunião'); + this.toastService._badRequest('Não foi possível marcar a reunião'); }, ()=>{ laoder.remove() }); diff --git a/src/app/modals/forward/forward.page.ts b/src/app/modals/forward/forward.page.ts index d56c77b7a..a40c1747c 100644 --- a/src/app/modals/forward/forward.page.ts +++ b/src/app/modals/forward/forward.page.ts @@ -124,7 +124,7 @@ export class ForwardPage implements OnInit { } if(this.taskParticipants.length < 1){ - this.toastService.badRequest("Selecione um destinatário"); + this.toastService._badRequest("Selecione um destinatário"); } else { @@ -150,11 +150,11 @@ export class ForwardPage implements OnInit { console.log(body); this.processes.CompleteParecerPrTask(body).subscribe(res=>{ console.log(res); - this.toastService.successMessage('Processo delegado'); + this.toastService._successMessage('Processo delegado'); this.goBack(); }, (error)=>{ - this.toastService.badRequest("Processo não delegado") + this.toastService._badRequest("Processo não delegado") }); } } diff --git a/src/app/pages/agenda/agenda.page.ts b/src/app/pages/agenda/agenda.page.ts index 54cace2f4..07ae8a76f 100644 --- a/src/app/pages/agenda/agenda.page.ts +++ b/src/app/pages/agenda/agenda.page.ts @@ -952,7 +952,7 @@ export class AgendaPage implements OnInit { // }); this.myCal.update(); this.myCal.loadEvents(); - // this.loadRangeEvents(this.rangeStartDate, this.rangeEndDate); + this.loadRangeEvents(this.rangeStartDate, this.rangeEndDate); } this.cloneAllmobileComponent(); @@ -1147,6 +1147,7 @@ export class AgendaPage implements OnInit { async closeComponentEditEventOrAdd() { if (this.IsEvent = 'edit') { + // this.loadRangeEvents(this.rangeStartDate, this.rangeEndDate); this.eventClicked(this.viewingEventObject); } else if (this.IsEvent = 'add') { this.cloneAllmobileComponent(); diff --git a/src/app/pages/agenda/new-event/new-event.page.ts b/src/app/pages/agenda/new-event/new-event.page.ts index 2c9954bcd..2c727befa 100644 --- a/src/app/pages/agenda/new-event/new-event.page.ts +++ b/src/app/pages/agenda/new-event/new-event.page.ts @@ -281,12 +281,12 @@ export class NewEventPage implements OnInit { }); - this.toastService.successMessage() + this.toastService._successMessage() this.modalController.dismiss(this.postEvent); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/despachos-pr/despacho-pr/despacho-pr.page.ts b/src/app/pages/gabinete-digital/despachos-pr/despacho-pr/despacho-pr.page.ts index e80b51e2b..6b51387c7 100644 --- a/src/app/pages/gabinete-digital/despachos-pr/despacho-pr/despacho-pr.page.ts +++ b/src/app/pages/gabinete-digital/despachos-pr/despacho-pr/despacho-pr.page.ts @@ -157,7 +157,7 @@ export class DespachoPrPage implements OnInit { } catch (e) { window.history.back(); } - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } }); @@ -272,9 +272,9 @@ export class DespachoPrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -297,10 +297,10 @@ export class DespachoPrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage('Processo arquivado') + this.toastService._successMessage('Processo arquivado') this.close(); } catch (error) { - this.toastService.badRequest('Processo não arquivado') + this.toastService._badRequest('Processo não arquivado') } finally { loader.remove() @@ -320,10 +320,10 @@ export class DespachoPrPage implements OnInit { documents }).toPromise() - this.toastService.successMessage('Processo criado') + this.toastService._successMessage('Processo criado') this.close(); } catch (error) { - this.toastService.badRequest('Processo não criado') + this.toastService._badRequest('Processo não criado') } finally { loader.remove() @@ -346,10 +346,10 @@ export class DespachoPrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage('') + this.toastService._successMessage('') this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -373,10 +373,10 @@ export class DespachoPrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -391,11 +391,11 @@ export class DespachoPrPage implements OnInit { sendExpedienteToPending() { this.processes.SetTaskToPending(this.serialNumber).subscribe(res => { this.popoverController.dismiss('close') - this.toastService.successMessage('Processo enviado para pendentes') + this.toastService._successMessage('Processo enviado para pendentes') this.goBack() }, () => { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } diff --git a/src/app/pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.page.ts b/src/app/pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.page.ts index 270c49bca..e4eb59fc6 100644 --- a/src/app/pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.page.ts +++ b/src/app/pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.page.ts @@ -117,15 +117,15 @@ export class DiplomaAssinarPage implements OnInit { }, (error)=>{ try { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') this.goBack() } catch (e) { window.history.back(); } finally { if(error.status == 0) { - this.toastService.badRequest('Não é possível visualizar este processo no modo offline') + this.toastService._badRequest('Não é possível visualizar este processo no modo offline') } else { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } } }); @@ -179,11 +179,11 @@ export class DiplomaAssinarPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage(false, ()=>{ + this.toastService._successMessage(false, ()=>{ this.goBack(); }) } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() diff --git a/src/app/pages/gabinete-digital/diplomas/diploma/diploma.page.ts b/src/app/pages/gabinete-digital/diplomas/diploma/diploma.page.ts index 54c9862f8..914df88d3 100644 --- a/src/app/pages/gabinete-digital/diplomas/diploma/diploma.page.ts +++ b/src/app/pages/gabinete-digital/diplomas/diploma/diploma.page.ts @@ -163,7 +163,7 @@ export class DiplomaPage implements OnInit { } catch (e) { window.history.back(); } - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } }); @@ -282,12 +282,12 @@ export class DiplomaPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage(false, () => { + this.toastService._successMessage(false, () => { this.close(); }) } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -308,9 +308,9 @@ export class DiplomaPage implements OnInit { const loader = this.toastService.loading() try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -334,9 +334,9 @@ export class DiplomaPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); - this.toastService.successMessage('Processo concluído') + this.toastService._successMessage('Processo concluído') } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() diff --git a/src/app/pages/gabinete-digital/event-list/approve-event-modal/approve-event-modal.page.ts b/src/app/pages/gabinete-digital/event-list/approve-event-modal/approve-event-modal.page.ts index 3dc0df31b..3318f254c 100644 --- a/src/app/pages/gabinete-digital/event-list/approve-event-modal/approve-event-modal.page.ts +++ b/src/app/pages/gabinete-digital/event-list/approve-event-modal/approve-event-modal.page.ts @@ -110,13 +110,13 @@ export class ApproveEventModalPage implements OnInit { try { await this.processes.PostTaskAction(body).toPromise() - this.toastService.successMessage('Evento aprovado', ()=>{ + this.toastService._successMessage('Evento aprovado', ()=>{ this.router.navigate(['/home/gabinete-digital/event-list']); this.modalController.dismiss(null); }) } catch (error) { - this.toastService.badRequest('Evento não aprovado') + this.toastService._badRequest('Evento não aprovado') } finally { loader.remove() @@ -141,11 +141,11 @@ export class ApproveEventModalPage implements OnInit { try { await this.processes.PostTaskAction(body).toPromise() - this.toastService.successMessage('Evento rejeitado', () =>{ + this.toastService._successMessage('Evento rejeitado', () =>{ this.router.navigate(['/home/gabinete-digital/event-list']); }) } catch (error) { - this.toastService.badRequest('Evento não rejeitado') + this.toastService._badRequest('Evento não rejeitado') } finally { loader.remove() diff --git a/src/app/pages/gabinete-digital/event-list/approve-event/approve-event.page.ts b/src/app/pages/gabinete-digital/event-list/approve-event/approve-event.page.ts index eb15015f1..1ba7a67a3 100644 --- a/src/app/pages/gabinete-digital/event-list/approve-event/approve-event.page.ts +++ b/src/app/pages/gabinete-digital/event-list/approve-event/approve-event.page.ts @@ -203,11 +203,11 @@ export class ApproveEventPage implements OnInit { try { await this.processes.PostTaskAction(body).toPromise() - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -256,10 +256,10 @@ export class ApproveEventPage implements OnInit { try { await this.processes.PostTaskAction(body).toPromise(); - this.toastService.successMessage('Pedido enviado'); + this.toastService._successMessage('Pedido enviado'); this.goBack(); } catch (error) { - this.toastService.badRequest(); + this.toastService._badRequest(); } finally { loader.remove() } @@ -280,10 +280,10 @@ export class ApproveEventPage implements OnInit { const loader = this.toastService.loading() try { await this.processes.PostTaskAction(body).toPromise(); - await this.toastService.successMessage('Processo rejeitado'); + await this.toastService._successMessage('Processo rejeitado'); this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -358,10 +358,10 @@ export class ApproveEventPage implements OnInit { try { await this.processes.PostTaskAction(body).toPromise(); - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest(); + this.toastService._badRequest(); } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/expediente/book-meeting-modal/book-meeting-modal.page.ts b/src/app/pages/gabinete-digital/expediente/book-meeting-modal/book-meeting-modal.page.ts index 7411339b3..060b0afb9 100644 --- a/src/app/pages/gabinete-digital/expediente/book-meeting-modal/book-meeting-modal.page.ts +++ b/src/app/pages/gabinete-digital/expediente/book-meeting-modal/book-meeting-modal.page.ts @@ -275,10 +275,10 @@ export class BookMeetingModalPage implements OnInit { this.modalController.dismiss(); // this.distartExpedientModal(); - this.toastService.successMessage('Reunião criada'); + this.toastService._successMessage('Reunião criada'); } catch (error) { - this.toastService.badRequest('Reunião não criada') + this.toastService._badRequest('Reunião não criada') } finally { loader.remove() @@ -300,10 +300,10 @@ export class BookMeetingModalPage implements OnInit { break; } this.close(); - this.toastService.successMessage('Reunião criada'); + this.toastService._successMessage('Reunião criada'); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page.ts b/src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page.ts index 66a2f128e..6b2a10354 100644 --- a/src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page.ts +++ b/src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page.ts @@ -328,11 +328,11 @@ export class ExpedientTaskModalPage implements OnInit { try { this.taskResult = await this.processes.postDespatcho(this.postData).toPromise(); - await this.toastService.successMessage('Processo efetuado'); + await this.toastService._successMessage('Processo efetuado'); this.modalController.dismiss(action_despacho); } catch (error) { - await this.toastService.badRequest('Processo não efetuado') + await this.toastService._badRequest('Processo não efetuado') } finally { loader.remove() } @@ -362,11 +362,11 @@ export class ExpedientTaskModalPage implements OnInit { try { this.taskResult = await this.processes.postParecer(this.postData).toPromise(); - await this.toastService.successMessage('Pedido enviado'); + await this.toastService._successMessage('Pedido enviado'); this.modalController.dismiss(action_parecer); } catch (error) { - await this.toastService.badRequest('Processo não efetuado') + await this.toastService._badRequest('Processo não efetuado') } finally { loader.remove() } @@ -394,10 +394,10 @@ export class ExpedientTaskModalPage implements OnInit { try { this.taskResult = await this.processes.postDeferimento(this.postData).toPromise(); - this.toastService.successMessage('Processo efetuado'); + this.toastService._successMessage('Processo efetuado'); this.modalController.dismiss(action_deferimento); } catch (error) { - await this.toastService.badRequest('Processo não efetuado') + await this.toastService._badRequest('Processo não efetuado') } finally { loader.remove() } @@ -436,18 +436,18 @@ export class ExpedientTaskModalPage implements OnInit { if(this.postData.DispatchFolder.Message){ try { this.taskResult = await this.despachoService.createDespacho(this.postData).toPromise(); - await this.toastService.successMessage('Processo efetuado'); + await this.toastService._successMessage('Processo efetuado'); this.modalController.dismiss(action_despacho_pr); } catch (error) { - await this.toastService.badRequest('Processo não efetuado') + await this.toastService._badRequest('Processo não efetuado') } finally { //loader.remove() } } else{ this.validateField = true; - this.toastService.badRequest('Por favor adicione uma descrição'); + this.toastService._badRequest('Por favor adicione uma descrição'); } loader.remove(); break; @@ -474,11 +474,11 @@ export class ExpedientTaskModalPage implements OnInit { try { this.taskResult = await this.processes.postParecerPr(this.postData).toPromise(); - await this.toastService.successMessage('Pedido enviado'); + await this.toastService._successMessage('Pedido enviado'); this.modalController.dismiss(action_parecer_pr); } catch (error) { - await this.toastService.badRequest('Processo não efetuado') + await this.toastService._badRequest('Processo não efetuado') } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html index 5e500863d..148cb3d61 100644 --- a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html +++ b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html @@ -111,7 +111,7 @@
-
+
diff --git a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.ts b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.ts index 4adf39246..4be371ca6 100644 --- a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.ts +++ b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.ts @@ -171,9 +171,9 @@ export class ExpedienteDetailPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); this.close(); - this.toastService.successMessage('Processo aprovado') + this.toastService._successMessage('Processo aprovado') } catch (error) { - this.toastService.badRequest('Processo não aprovado') + this.toastService._badRequest('Processo não aprovado') } finally { loader.remove() } @@ -196,9 +196,9 @@ export class ExpedienteDetailPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -293,11 +293,11 @@ export class ExpedienteDetailPage implements OnInit { sendExpedienteToPending() { this.processes.SetTaskToPending(this.serialNumber).subscribe(res => { console.log(res); - this.toastService.successMessage('Processo enviado para pendentes') + this.toastService._successMessage('Processo enviado para pendentes') this.goBack(); }, (error) => { - this.toastService.badRequest('Processo não enviado para pendentes') + this.toastService._badRequest('Processo não enviado para pendentes') }); } @@ -349,12 +349,12 @@ export class ExpedienteDetailPage implements OnInit { this.getFromDB(); } else { try { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') this.goBack() } catch (e) { window.history.back(); } - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } }); @@ -441,9 +441,9 @@ export class ExpedienteDetailPage implements OnInit { const loader = this.toastService.loading() this.attachmentsService.AddAttachment(body).subscribe((res) => { - this.toastService.successMessage() + this.toastService._successMessage() }, () => { - this.toastService.badRequest() + this.toastService._badRequest() }, () => { loader.remove() }); @@ -479,7 +479,7 @@ export class ExpedienteDetailPage implements OnInit { await this.processes.CompleteTask(body).toPromise(); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -510,10 +510,10 @@ export class ExpedienteDetailPage implements OnInit { try { await this.expedienteService.discard({ SerialNumber: this.task.SerialNumber }).toPromise() - this.toastService.successMessage('Processo descartado'); + this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -529,10 +529,10 @@ export class ExpedienteDetailPage implements OnInit { const loader = this.toastService.loading() try { await this.expedienteService.CompleteTask(body).toPromise(); - //this.toastService.successMessage('Processo descartado'); + //this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -543,10 +543,10 @@ export class ExpedienteDetailPage implements OnInit { const loader = this.toastService.loading() try { await this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(); - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.page.ts b/src/app/pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.page.ts index bdf1e1646..a23d40c14 100644 --- a/src/app/pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.page.ts +++ b/src/app/pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.page.ts @@ -135,11 +135,11 @@ export class ExpedientePrPage implements OnInit { sendExpedienteToPending() { this.processes.SetTaskToPending(this.serialnumber).subscribe(res=>{ console.log(res); - this.toastService.successMessage('Processo enviado para pendentes') + this.toastService._successMessage('Processo enviado para pendentes') this.goBack(); }, (error)=>{ - this.toastService.badRequest('Processo não enviado para pendentes') + this.toastService._badRequest('Processo não enviado para pendentes') }); } @@ -184,15 +184,15 @@ export class ExpedientePrPage implements OnInit { }, (error)=>{ try { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') this.goBack() } catch (e) { window.history.back(); } finally { if(error.status == 0) { - this.toastService.badRequest('Não é possível visualizar este processo no modo offline') + this.toastService._badRequest('Não é possível visualizar este processo no modo offline') } else { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } } }); @@ -303,9 +303,9 @@ export class ExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); this.close(); - this.toastService.successMessage('Processo aprovado') + this.toastService._successMessage('Processo aprovado') } catch(error) { - this.toastService.badRequest('Processo não aprovado') + this.toastService._badRequest('Processo não aprovado') } finally { loader.remove() } @@ -328,9 +328,9 @@ export class ExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch(error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -448,10 +448,10 @@ export class ExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(otherbody).toPromise() - this.toastService.successMessage('Processo descartado'); + this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -468,10 +468,10 @@ export class ExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); - // this.toastService.successMessage('Processo descartado'); + // this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - // this.toastService.badRequest('Processo não descartado') + // this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -485,10 +485,10 @@ export class ExpedientePrPage implements OnInit { try { await this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(); - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/pages/gabinete-digital/gabinete-digital.page.html b/src/app/pages/gabinete-digital/gabinete-digital.page.html index 6c3fcf1a9..e71f518e0 100644 --- a/src/app/pages/gabinete-digital/gabinete-digital.page.html +++ b/src/app/pages/gabinete-digital/gabinete-digital.page.html @@ -217,7 +217,7 @@

Diplomas por Validar

Diplomas por Assinar

-

{{ deplomasStore.deplomasReviewCount }} Documentos

+

{{ deplomasStore.deplomasReviewCount }} bug Documentos

diff --git a/src/app/pages/gabinete-digital/gabinete-digital.page.ts b/src/app/pages/gabinete-digital/gabinete-digital.page.ts index 9ae555f51..db593f0b1 100644 --- a/src/app/pages/gabinete-digital/gabinete-digital.page.ts +++ b/src/app/pages/gabinete-digital/gabinete-digital.page.ts @@ -618,6 +618,7 @@ export class GabineteDigitalPage implements OnInit, DoCheck { let diplomasAssinar = despachospr.filter(data => data.activityInstanceName == "Assinar Diploma"); this.count_dip_as = Object.keys(diplomasAssinar).length; + this.deplomasStore.resetDiplomasList(diplomasAssinar) diff --git a/src/app/pages/gabinete-digital/pedidos/pedido/pedido.page.ts b/src/app/pages/gabinete-digital/pedidos/pedido/pedido.page.ts index a3bd8e8f7..9a80658a7 100644 --- a/src/app/pages/gabinete-digital/pedidos/pedido/pedido.page.ts +++ b/src/app/pages/gabinete-digital/pedidos/pedido/pedido.page.ts @@ -182,7 +182,7 @@ export class PedidoPage implements OnInit { } catch (e) { window.history.back(); } - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') } }); @@ -370,10 +370,10 @@ export class PedidoPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -390,10 +390,10 @@ export class PedidoPage implements OnInit { note }).toPromise() - this.toastService.successMessage('Processo arquivado') + this.toastService._successMessage('Processo arquivado') this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -415,10 +415,10 @@ export class PedidoPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage('Processo arquivado') + this.toastService._successMessage('Processo arquivado') this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -430,7 +430,7 @@ export class PedidoPage implements OnInit { this.goBack(); }, () => { - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } diff --git a/src/app/pages/inactivity/inactivity.page.html b/src/app/pages/inactivity/inactivity.page.html index b34e1a58a..5f8114855 100644 --- a/src/app/pages/inactivity/inactivity.page.html +++ b/src/app/pages/inactivity/inactivity.page.html @@ -42,11 +42,11 @@
-
+
Entrar com senha
-
+
Limpar
diff --git a/src/app/pages/inactivity/inactivity.page.scss b/src/app/pages/inactivity/inactivity.page.scss index e8ba842b8..3cd90e111 100644 --- a/src/app/pages/inactivity/inactivity.page.scss +++ b/src/app/pages/inactivity/inactivity.page.scss @@ -9,12 +9,11 @@ ion-content{ } .main-wrapper{ - background: var(--login-background); + background: var(--PinBackground); display: flex; width: 100vw; height: 100vh; overflow: auto; - background: white !important; display: flex; align-items: center; justify-content: center; @@ -142,7 +141,7 @@ ion-item{ align-items: center; justify-content: center; font-size: 19pt; - background: #44b5ea; + background: var(--PinDots);; border-radius: 56px; margin-bottom: 15px; user-select: none; @@ -163,7 +162,7 @@ ion-item{ justify-content: center; display: flex; flex-direction: column; - background-image: url(/assets/background/auth.svg); + background-image: var(--PinCircleBackground); background-position: center; background-repeat: no-repeat; width: 100%; @@ -172,19 +171,20 @@ ion-item{ } .clear{ - color: #44b5ea; + color: var(--PinTextColor); font-size: 12pt; z-index: 1000; } + .dot-active{ - background: #44b5ea; + background: var(--PinDots); } .dot{ width: 25px; height: 25px; margin: 0 10px 0 0; - border: 3px solid #44b5ea; + border: 3px solid var(--PinDots); box-sizing: border-box; border-radius: 50px; -webkit-border-radius: 50px; diff --git a/src/app/pages/inactivity/inactivity.page.ts b/src/app/pages/inactivity/inactivity.page.ts index 1b2d1efae..5681c459f 100644 --- a/src/app/pages/inactivity/inactivity.page.ts +++ b/src/app/pages/inactivity/inactivity.page.ts @@ -132,11 +132,11 @@ export class InactivityPage implements OnInit { } } else { - this.toastService.badRequest('Por favor, insira a sua palavra-passe'); + this.toastService._badRequest('Por favor, insira a sua palavra-passe'); } } else { - this.toastService.badRequest('Por favor, insira o seu nome de utilizador'); + this.toastService._badRequest('Por favor, insira o seu nome de utilizador'); } } @@ -182,7 +182,7 @@ export class InactivityPage implements OnInit { }, 1000) } else { - this.toastService.badRequest('Pin incorreto') + this.toastService._badRequest('Pin incorreto') this.code = [] } diff --git a/src/app/pages/login/login.page.ts b/src/app/pages/login/login.page.ts index 32f026712..03fa662ba 100644 --- a/src/app/pages/login/login.page.ts +++ b/src/app/pages/login/login.page.ts @@ -123,11 +123,11 @@ export class LoginPage implements OnInit { } } else { - this.toastService.badRequest('Por favor, insira a sua palavra-passe'); + this.toastService._badRequest('Por favor, insira a sua palavra-passe'); } } else { - this.toastService.badRequest('Por favor, insira o seu nome de utilizador'); + this.toastService._badRequest('Por favor, insira o seu nome de utilizador'); } } diff --git a/src/app/pages/publications/edit-action/edit-action.page.ts b/src/app/pages/publications/edit-action/edit-action.page.ts index 97b765ca0..90eed9ce5 100644 --- a/src/app/pages/publications/edit-action/edit-action.page.ts +++ b/src/app/pages/publications/edit-action/edit-action.page.ts @@ -104,9 +104,9 @@ export class EditActionPage implements OnInit { await this.publicationsService.UpdatePresidentialAction(body).toPromise() this.close(); this.updateDesktopComponent.emit(); - this.toastService.successMessage('Acção presidencial atualizada') + this.toastService._successMessage('Acção presidencial atualizada') } catch (error) { - this.toastService.badRequest('Não foi possivel atualizar a acção presidencial') + this.toastService._badRequest('Não foi possivel atualizar a acção presidencial') } finally { loader.remove() } diff --git a/src/app/pages/publications/publications.page.ts b/src/app/pages/publications/publications.page.ts index b96eb8e80..c0e2309f1 100644 --- a/src/app/pages/publications/publications.page.ts +++ b/src/app/pages/publications/publications.page.ts @@ -238,9 +238,9 @@ export class PublicationsPage implements OnInit { try { await this.publications.DeletePresidentialAction(id).toPromise(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (e) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() diff --git a/src/app/services/agenda/list-box.service.ts b/src/app/services/agenda/list-box.service.ts index 04066f1da..8c3948e42 100644 --- a/src/app/services/agenda/list-box.service.ts +++ b/src/app/services/agenda/list-box.service.ts @@ -8,8 +8,8 @@ import { DateService } from '../date.service'; export class ListBoxService { constructor( - private dateService: DateService - ){} + private dateService: DateService + ){} filterProfile(eventSource: EventListStore[], profile: 'md' | 'pr' | 'all') { @@ -26,32 +26,34 @@ export class ListBoxService { }) } - filterSegment(eventSource: EventListStore[], segment): EventListStore[] { - return eventSource.filter( data => data.calendarName == segment) - } - + filterSegment(eventSource: EventListStore[], segment): EventListStore[] { + return eventSource.filter( data => data.calendarName == segment) + } daysBetween(){ } list(eventSource: EventListStore[], profile: 'md' | 'pr' | 'all', rangeStartDate, randEndDate, {segment = 'Combinado', selectedDate= null}) { - // filter range - if(selectedDate) { - eventSource = eventSource.filter(data => - data.startTime.toLocaleDateString('pt')>= selectedDate.toLocaleDateString('pt') && - data.endTime.toLocaleDateString('pt')>= selectedDate.toLocaleDateString('pt') - ) - } + // console.log('eventSource', eventSource ,'rangeStartDate', new Date(rangeStartDate).toLocaleDateString('pt') , 'randEndDate', new Date(randEndDate).toLocaleDateString('pt')) - if(segment!='Combinado') { - eventSource = this.filterSegment(eventSource, segment) - } + // // filter range + // if(selectedDate) { + // eventSource = eventSource.filter(data => + // data.startTime.toLocaleDateString('pt') >= new Date(rangeStartDate).toLocaleDateString('pt') && + // data.startTime.toLocaleDateString('pt') <= new Date(rangeStartDate).toLocaleDateString('pt') + // ) + // } + + + if(segment!='Combinado') { + eventSource = this.filterSegment(eventSource, segment) + } if(profile != 'all') { eventSource = this.filterProfile(eventSource, profile) } - let newStracture:CustomCalendarEvent[]; + let newStracture:CustomCalendarEvent[]; if(profile == 'md') { newStracture = this.encapsulation(eventSource, 'mdgpr'); diff --git a/src/app/services/toast.service.ts b/src/app/services/toast.service.ts index db279af79..0539f5085 100644 --- a/src/app/services/toast.service.ts +++ b/src/app/services/toast.service.ts @@ -24,6 +24,73 @@ export class ToastService { toast.present(); } + + async _successMessage(message?: any, callback?) { + + let notification = document.createElement('div') + notification.className = 'notification' + notification.innerHTML = ` + +
+

+ +

{{ message }}

+

+ +
+ ` + + document.body.append(notification) + notification.querySelector('.text').innerHTML = message || 'Processo efetuado' + setTimeout(()=>{ + if (callback) { + callback() + } + + notification.style.right = "-100%" + + setTimeout(()=>{ + notification.remove() + },1000) + + },6000) + + } + + async _badRequest(message?: string, callback?) { + + let notification = document.createElement('div') + notification.className = 'notification' + notification.innerHTML = ` + +
+

+ +

{{ message }}

+

+ +
+ ` + + notification.style.animationName = 'notification-top' + + document.body.append(notification) + notification.querySelector('.text').innerHTML = message || 'Processo não efetuado' + setTimeout(()=>{ + if (callback) { + callback() + } + + notification.style.right = "-100%" + + setTimeout(()=>{ + notification.remove() + },1000) + + },6000) + + } + async successMessage(message?: any, callback?) { let notification = document.createElement('div') diff --git a/src/app/shared/agenda/edit-event/edit-event.page.ts b/src/app/shared/agenda/edit-event/edit-event.page.ts index 4eef38a80..36759d852 100644 --- a/src/app/shared/agenda/edit-event/edit-event.page.ts +++ b/src/app/shared/agenda/edit-event/edit-event.page.ts @@ -142,6 +142,10 @@ export class EditEventPage implements OnInit { } + ngOnChanges(changes: any): void { + // this.loadedEventAttachments = this.loadedEventAttachments.concat(this.postEvent.Attachments) + } + close() { this.closeComponent.emit(); this.setIntervenient.emit([]); @@ -282,7 +286,6 @@ export class EditEventPage implements OnInit { async saveDocument() { - console.log(this.loadedEventAttachments) await this.loadedEventAttachments.forEach( async (e)=>{ @@ -303,10 +306,10 @@ export class EditEventPage implements OnInit { }; await this.attachmentsService.setEventAttachmentById(DocumentToSave).toPromise(); - this.getAttachments(this.postEvent.EventId); + await this.getAttachments(this.postEvent.EventId); } else if(remove) { - this.attachmentsService.deleteEventAttachmentById(e.Id).subscribe( res=> {}) + await this.attachmentsService.deleteEventAttachmentById(e.Id).toPromise() } }) @@ -365,11 +368,9 @@ export class EditEventPage implements OnInit { window['temp.path:/home/agenda/edit-event.component.ts'] = {} } - getAttachments(eventId: string){ - this.attachmentsService.getAttachmentsById(eventId).subscribe(res=>{ - this.loadedEventAttachments = res; - console.log('res', res); - }); + async getAttachments(eventId: string){ + const rest: any = this.attachmentsService.getAttachmentsById(eventId).toPromise() + this.loadedEventAttachments = rest; } deleteAttachment(attachmentID: string, index) { diff --git a/src/app/shared/agenda/new-event/new-event.page.ts b/src/app/shared/agenda/new-event/new-event.page.ts index bcf7d5dc4..058c0910f 100644 --- a/src/app/shared/agenda/new-event/new-event.page.ts +++ b/src/app/shared/agenda/new-event/new-event.page.ts @@ -409,14 +409,14 @@ export class NewEventPage implements OnInit { this.afterSave(); } - this.toastService.successMessage('Evento criado') + this.toastService._successMessage('Evento criado') }, error => { loader.remove() this.showLoader = false - this.toastService.badRequest('Evento não criado') + this.toastService._badRequest('Evento não criado') }); diff --git a/src/app/shared/agenda/view-event/view-event.page.ts b/src/app/shared/agenda/view-event/view-event.page.ts index cff1408fe..2de4d89da 100644 --- a/src/app/shared/agenda/view-event/view-event.page.ts +++ b/src/app/shared/agenda/view-event/view-event.page.ts @@ -95,6 +95,7 @@ export class ViewEventPage implements OnInit { } loadEvent() { + this.eventsService.getEvent(this.eventId).subscribe(res => { console.log(res); this.loadedEvent = res; diff --git a/src/app/shared/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts b/src/app/shared/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts index 2292ba298..247e6e8f2 100644 --- a/src/app/shared/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts +++ b/src/app/shared/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts @@ -31,7 +31,7 @@ export class DiplomasAssinarPage implements OnInit { private router: Router, private sortService: SortService, public ThemeService: ThemeService - ) { } + ) {} ngOnInit() { @@ -56,30 +56,27 @@ export class DiplomasAssinarPage implements OnInit { doRefresh() { setTimeout(() => { this.LoadList(); - //event.target.complete(); }, 1000); } async LoadList() { + + this.skeletonLoader = true let diplomas = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise(); this.diplomasList = new Array(); this.skeletonLoader = false - console.log(diplomas); let diplomasAssinar = diplomas.reverse().filter(data => data.activityInstanceName == "Assinar Diploma"); - console.log(diplomasAssinar); diplomasAssinar.forEach(element => { - let task: customTask = this.customTaskPipe.transform(element) this.diplomasList.push(task); - this.deplomasStore.resetDiplomasList(this.sortService.sortArrayByDate(this.diplomasList)); - }); + this.deplomasStore.resetDiplomasList(this.diplomasList); } } diff --git a/src/app/shared/popover/deploma-options/deploma-options.page.ts b/src/app/shared/popover/deploma-options/deploma-options.page.ts index d976e4540..0ad15f77b 100644 --- a/src/app/shared/popover/deploma-options/deploma-options.page.ts +++ b/src/app/shared/popover/deploma-options/deploma-options.page.ts @@ -107,9 +107,9 @@ export class DeplomaOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -154,9 +154,9 @@ export class DeplomaOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -180,9 +180,9 @@ export class DeplomaOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -205,9 +205,9 @@ export class DeplomaOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); - this.toastService.successMessage('Processo concluído') + this.toastService._successMessage('Processo concluído') } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() diff --git a/src/app/shared/popover/despachos-options/despachos-options.page.ts b/src/app/shared/popover/despachos-options/despachos-options.page.ts index b1d62bbc8..bd2ea5e42 100644 --- a/src/app/shared/popover/despachos-options/despachos-options.page.ts +++ b/src/app/shared/popover/despachos-options/despachos-options.page.ts @@ -74,12 +74,12 @@ export class DespachosOptionsPage implements OnInit { sendExpedienteToPending(){ this.popoverController.dismiss(); this.processes.SetTaskToPending(this.task.SerialNumber).subscribe(res=>{ - this.toastService.successMessage() + this.toastService._successMessage() console.log(res); this.close(); },()=>{ - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } @@ -163,10 +163,10 @@ export class DespachosOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -244,10 +244,10 @@ export class DespachosOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage('Processo arquivado') + this.toastService._successMessage('Processo arquivado') this.close(); } catch (error) { - this.toastService.badRequest('Processo não arquivado') + this.toastService._badRequest('Processo não arquivado') } finally { loader.remove() } @@ -272,9 +272,9 @@ export class DespachosOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch(error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -298,10 +298,10 @@ export class DespachosOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/shared/popover/despachos-pr-options/despachos-pr-options.page.ts b/src/app/shared/popover/despachos-pr-options/despachos-pr-options.page.ts index 5ba9b2902..abe5d0913 100644 --- a/src/app/shared/popover/despachos-pr-options/despachos-pr-options.page.ts +++ b/src/app/shared/popover/despachos-pr-options/despachos-pr-options.page.ts @@ -100,11 +100,11 @@ export class DespachosPrOptionsPage implements OnInit { sendExpedienteToPending() { this.processes.SetTaskToPending(this.serialNumber).subscribe(res=>{ console.log(res); - this.toastService.successMessage() + this.toastService._successMessage() this.popoverController.dismiss('close') },()=>{ - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } @@ -192,10 +192,10 @@ export class DespachosPrOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -275,10 +275,10 @@ export class DespachosPrOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() - this.toastService.successMessage('') + this.toastService._successMessage('') this.close(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() diff --git a/src/app/shared/popover/opts-expediente-pr/opts-expediente-pr.page.ts b/src/app/shared/popover/opts-expediente-pr/opts-expediente-pr.page.ts index 35a192b50..8fd55d91f 100644 --- a/src/app/shared/popover/opts-expediente-pr/opts-expediente-pr.page.ts +++ b/src/app/shared/popover/opts-expediente-pr/opts-expediente-pr.page.ts @@ -142,9 +142,9 @@ export class OptsExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch(error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -179,10 +179,10 @@ export class OptsExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(otherbody).toPromise() - this.toastService.successMessage('Processo descartado'); + this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -201,7 +201,7 @@ export class OptsExpedientePrPage implements OnInit { // this.toastService.successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado'); + this.toastService._badRequest('Processo não descartado'); } finally { loader.remove() } @@ -213,10 +213,10 @@ export class OptsExpedientePrPage implements OnInit { try { await this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(); - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest(); + this.toastService._badRequest(); } finally { loader.remove() } @@ -242,9 +242,9 @@ export class OptsExpedientePrPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch(error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -258,7 +258,7 @@ export class OptsExpedientePrPage implements OnInit { this.close(); },()=>{ - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } @@ -295,7 +295,7 @@ export class OptsExpedientePrPage implements OnInit { // this.toastService.successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado'); + this.toastService._badRequest('Processo não descartado'); } finally { loader.remove() } diff --git a/src/app/shared/popover/opts-expediente/opts-expediente.page.ts b/src/app/shared/popover/opts-expediente/opts-expediente.page.ts index b8d1bb688..f874a9f4d 100644 --- a/src/app/shared/popover/opts-expediente/opts-expediente.page.ts +++ b/src/app/shared/popover/opts-expediente/opts-expediente.page.ts @@ -166,9 +166,9 @@ export class OptsExpedientePage implements OnInit { const loader = this.toastService.loading() this.attachmentsService.AddAttachment(body).subscribe((res)=> { - this.toastService.successMessage() + this.toastService._successMessage() },()=> { - this.toastService.badRequest() + this.toastService._badRequest() },()=> { loader.remove() }); @@ -243,9 +243,9 @@ export class OptsExpedientePage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch(error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -257,7 +257,7 @@ export class OptsExpedientePage implements OnInit { this.goBack(); },()=>{ - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } @@ -279,9 +279,9 @@ export class OptsExpedientePage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); this.close(); - this.toastService.successMessage('Processo aprovado') + this.toastService._successMessage('Processo aprovado') } catch(error) { - this.toastService.badRequest('Processo não aprovado') + this.toastService._badRequest('Processo não aprovado') } finally { loader.remove() } @@ -337,7 +337,7 @@ export class OptsExpedientePage implements OnInit { await this.processes.CompleteTask(body).toPromise(); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -369,10 +369,10 @@ export class OptsExpedientePage implements OnInit { try { await this.expedienteService.discard({SerialNumber: this.task.SerialNumber}).toPromise() - this.toastService.successMessage('Processo descartado'); + this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -389,10 +389,10 @@ export class OptsExpedientePage implements OnInit { try { await this.processes.CompleteTask(body).toPromise(); - this.toastService.successMessage('Processo descartado'); + this.toastService._successMessage('Processo descartado'); this.goBack(); } catch (error) { - this.toastService.badRequest('Processo não descartado') + this.toastService._badRequest('Processo não descartado') } finally { loader.remove() } @@ -404,10 +404,10 @@ export class OptsExpedientePage implements OnInit { try { await this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(); - this.toastService.successMessage(); + this.toastService._successMessage(); this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } diff --git a/src/app/shared/popover/request-options/request-options.page.ts b/src/app/shared/popover/request-options/request-options.page.ts index ed59e7c99..d64b9d583 100644 --- a/src/app/shared/popover/request-options/request-options.page.ts +++ b/src/app/shared/popover/request-options/request-options.page.ts @@ -80,11 +80,11 @@ export class RequestOptionsPage implements OnInit { sendExpedienteToPending() { this.processes.SetTaskToPending(this.task.SerialNumber).subscribe(res=>{ console.log(res); - this.toastService.successMessage() + this.toastService._successMessage() this.close(); },()=>{ - this.toastService.badRequest('Processo não encontrado') + this.toastService._badRequest('Processo não encontrado') }); } @@ -157,9 +157,9 @@ export class RequestOptionsPage implements OnInit { try { await this.processes.CompleteTask(body).toPromise() this.close(); - this.toastService.successMessage() + this.toastService._successMessage() } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() @@ -226,9 +226,9 @@ export class RequestOptionsPage implements OnInit { note }).toPromise() - this.toastService.successMessage('Processo arquivado') + this.toastService._successMessage('Processo arquivado') } catch (error) { - this.toastService.badRequest('Processo não arquivado') + this.toastService._badRequest('Processo não arquivado') } finally { loader.remove() } diff --git a/src/app/shared/publication/new-publication/new-publication.page.ts b/src/app/shared/publication/new-publication/new-publication.page.ts index 50c3a3d32..4d25f3b8f 100644 --- a/src/app/shared/publication/new-publication/new-publication.page.ts +++ b/src/app/shared/publication/new-publication/new-publication.page.ts @@ -200,11 +200,11 @@ export class NewPublicationPage implements OnInit { try { await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -228,11 +228,12 @@ export class NewPublicationPage implements OnInit { try { console.log(this.publication); await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise() - this.toastService.successMessage() + + this.toastService._successMessage() this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -256,11 +257,11 @@ export class NewPublicationPage implements OnInit { try { await this.publications.UpdatePublication(this.publication.ProcessId, this.publication).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.goBack(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -287,11 +288,11 @@ export class NewPublicationPage implements OnInit { try { console.log(this.publication); await this.publications.CreatePublication(this.folderId, this.publication).toPromise() - this.toastService.successMessage() + this.toastService._successMessage() this.goBackToViewPublications.emit(); } catch (error) { - this.toastService.badRequest() + this.toastService._badRequest() } finally { loader.remove() } @@ -302,9 +303,11 @@ export class NewPublicationPage implements OnInit { close(){ this.goBack(); } + clear(){ this.capturedImage = ''; } + setTitle(){ if(this.publicationType == '1') { this.publicationTitle = 'Nova Publicação Rápida'; diff --git a/src/app/shared/publication/view-publications/publication-detail/publication-detail.page.ts b/src/app/shared/publication/view-publications/publication-detail/publication-detail.page.ts index b94ed647f..0dc8d3c09 100644 --- a/src/app/shared/publication/view-publications/publication-detail/publication-detail.page.ts +++ b/src/app/shared/publication/view-publications/publication-detail/publication-detail.page.ts @@ -94,10 +94,10 @@ export class PublicationDetailPage implements OnInit { try { await this.publications.DeletePublication(this.folderId, this.publicationId).toPromise(); - this.toastService.successMessage("Publicação eliminado") + this.toastService._successMessage("Publicação eliminado") this.goBackToViewPublications.emit(); } catch (error) { - this.toastService.badRequest("Publicação não eliminado") + this.toastService._badRequest("Publicação não eliminado") } finally { laoder.remove() } diff --git a/src/global.scss b/src/global.scss index 60aff4c0b..0dcae205f 100644 --- a/src/global.scss +++ b/src/global.scss @@ -1235,7 +1235,7 @@ ngx-mat-datetime-content{ .loading-blocker { .loading-blocker-container { - width: 250px; + width: 196px; } } } @@ -1297,4 +1297,6 @@ ngx-mat-datetime-content{ .add-people { align-items: center; height: 45px; -} \ No newline at end of file +} + + diff --git a/src/proxy.conf.json b/src/proxy.conf.json new file mode 100644 index 000000000..9e26dfeeb --- /dev/null +++ b/src/proxy.conf.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/src/theme/variables.scss b/src/theme/variables.scss index b9d52a1e0..a4271f04d 100644 --- a/src/theme/variables.scss +++ b/src/theme/variables.scss @@ -588,9 +588,11 @@ $app-theme: mat-light-theme( color: #061b52 !important; margin: 0 auto !important; } + .btn-no-color { background-color: #fff; } + .exp-workflow { float: left; margin-left: 15px; @@ -627,6 +629,7 @@ body { --indicator-color: transparent !important; --indicator-color-checked: transparent !important; } + .yellow-orange{ color: #ffb703 !important; } @@ -647,8 +650,12 @@ body { --header-container-background: #fff; --header-bottom-line-background: rgb(255, 0, 0); --header-bottom-line-background-image: linear-gradient(to right, #ff0000, #fd0000, #ff0000); - --font-awesome: #ff0000; + --font-awesome: #f7dddd; --font-awesome-1: #c63527; + --PinDots: #44b5ea; + --PinCircleBackground: url(/auth.svg); + --PinBackground: #e1e7eb; + --PinTextColor: #44b5ea; --color: #97cae631; --color2: #97cae631; @@ -721,6 +728,7 @@ body { --button-color: #ffb81c; --button-text-color: white; --inicio-open-page-from-box: #c63527; + --PinBackground: #e1e7eb; --header-tab-top-border: #000; --header-tab-text-white: rgb(0, 0, 0); @@ -733,6 +741,9 @@ body { --mat-selected-hover: #c634277e; --mat-calendar-body-selected: #c63527; --monthview-selected: rgb(198 53 39 / 49%); + --PinDots: #c63527; + --PinTextColor: black; + --PinCircleBackground: url(/auth.svg); --color: #d9d9d9; --color2: #f0f0f0; @@ -802,6 +813,12 @@ body { --mat-selected-hover: rgb(216 240 255); --mat-calendar-body-selected: #42b9fe ; --monthview-selected: lightskyblue; + + --PinDots: #44b5ea; + --PinTextColor: #44b5ea; + --PinCircleBackground: url(/assets/background/auth.svg); + --PinBackground: white !important; + --header-container-background: linear-gradient( 270deg, var(--color2) 0%,