From 2aba281a60037b93f2ec5c641b84347fba14adc7 Mon Sep 17 00:00:00 2001 From: Peter Maquiran Date: Wed, 18 Aug 2021 15:42:36 +0100 Subject: [PATCH] improve --- src/app/home/home.page.ts | 2 +- src/app/modals/create-process/create-process.page.ts | 4 +--- src/app/modals/document-detail/document-detail.page.ts | 2 +- .../pages/gabinete-digital/despachos-pr/despachos-pr.page.ts | 2 ++ src/app/pages/gabinete-digital/despachos/despachos.page.ts | 2 ++ .../diplomas-assinar/diplomas-assinar.page.ts | 2 ++ src/app/pages/gabinete-digital/diplomas/diplomas.page.ts | 2 ++ src/app/pages/gabinete-digital/event-list/event-list.page.ts | 2 ++ src/app/pages/gabinete-digital/pedidos/pedidos.page.ts | 2 ++ src/app/pages/gabinete-digital/pendentes/pendentes.page.ts | 2 ++ .../shared/gabinete-digital/despachos-pr/despachos-pr.page.ts | 2 ++ .../diplomas-assinar/diplomas-assinar.page.ts | 2 ++ src/app/shared/gabinete-digital/diplomas/diplomas.page.ts | 3 ++- .../gabinete-digital/expedientes-pr/expedientes-pr.page.ts | 2 ++ src/app/shared/gabinete-digital/expedients/expedients.page.ts | 1 + src/app/shared/gabinete-digital/pedidos/pedidos.page.ts | 1 - .../popover/despachos-pr-options/despachos-pr-options.page.ts | 1 - 17 files changed, 26 insertions(+), 8 deletions(-) diff --git a/src/app/home/home.page.ts b/src/app/home/home.page.ts index 3b890bebb..2bc6199e0 100644 --- a/src/app/home/home.page.ts +++ b/src/app/home/home.page.ts @@ -118,7 +118,7 @@ export class HomePage implements OnInit { //this.MFPushNotification(); }, (error) => { - alert("Connect with JavaAdapter Failure: " + JSON.stringify(error)); + console.log("Connect with JavaAdapter Failure: " + JSON.stringify(error)); } ); }, (error) => { diff --git a/src/app/modals/create-process/create-process.page.ts b/src/app/modals/create-process/create-process.page.ts index 94505b7d0..fd6afb325 100644 --- a/src/app/modals/create-process/create-process.page.ts +++ b/src/app/modals/create-process/create-process.page.ts @@ -330,7 +330,6 @@ export class CreateProcessPage implements OnInit { try { await this.pedidoService.createDeferimento(this.postData).toPromise(); await this.pedidoService.taskCompleteDeferimento({serialNumber:this.task.serialNumber}).toPromise(); - alert('!!__!!') this.modalController.dismiss(); this.toastService.successMessage('Pedido de Deferimento criado'); @@ -470,8 +469,7 @@ export class CreateProcessPage implements OnInit { } } else { - alert('!!!') - console.log('this.task', this.task) + console.log('unexpected activityInstanceName', this.task) } console.log(body); diff --git a/src/app/modals/document-detail/document-detail.page.ts b/src/app/modals/document-detail/document-detail.page.ts index fca534e33..e12d6c44c 100644 --- a/src/app/modals/document-detail/document-detail.page.ts +++ b/src/app/modals/document-detail/document-detail.page.ts @@ -89,7 +89,7 @@ export class DocumentDetailPage implements OnInit { } } } else { - alert('!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! alert') + console.log('unexpected ApplicationID') } this.task = task diff --git a/src/app/pages/gabinete-digital/despachos-pr/despachos-pr.page.ts b/src/app/pages/gabinete-digital/despachos-pr/despachos-pr.page.ts index bc907a020..640e05a21 100644 --- a/src/app/pages/gabinete-digital/despachos-pr/despachos-pr.page.ts +++ b/src/app/pages/gabinete-digital/despachos-pr/despachos-pr.page.ts @@ -69,6 +69,8 @@ export class DespachosPrPage implements OnInit { const location = window.location const pathname = location.pathname + location.search + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/pages/gabinete-digital/despachos/despachos.page.ts b/src/app/pages/gabinete-digital/despachos/despachos.page.ts index caa24bbc5..693bd6009 100644 --- a/src/app/pages/gabinete-digital/despachos/despachos.page.ts +++ b/src/app/pages/gabinete-digital/despachos/despachos.page.ts @@ -57,6 +57,8 @@ export class DespachosPage implements OnInit { const location = window.location const pathname = location.pathname + location.search + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/pages/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts b/src/app/pages/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts index d91790366..9d571a3ad 100644 --- a/src/app/pages/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts +++ b/src/app/pages/gabinete-digital/diplomas-assinar/diplomas-assinar.page.ts @@ -38,6 +38,8 @@ export class DiplomasAssinarPage implements OnInit { const location = window.location const pathname = location.pathname + location.search + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationEnd && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/pages/gabinete-digital/diplomas/diplomas.page.ts b/src/app/pages/gabinete-digital/diplomas/diplomas.page.ts index 50fdb4bcc..b9307ed0a 100644 --- a/src/app/pages/gabinete-digital/diplomas/diplomas.page.ts +++ b/src/app/pages/gabinete-digital/diplomas/diplomas.page.ts @@ -44,6 +44,8 @@ constructor( const location = window.location const pathname = location.pathname + location.search + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/pages/gabinete-digital/event-list/event-list.page.ts b/src/app/pages/gabinete-digital/event-list/event-list.page.ts index ae89785ba..56e95d9c1 100644 --- a/src/app/pages/gabinete-digital/event-list/event-list.page.ts +++ b/src/app/pages/gabinete-digital/event-list/event-list.page.ts @@ -43,6 +43,8 @@ export class EventListPage implements OnInit { const location = window.location const pathname = location.pathname + location.search + this.LoadToApproveEvents() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/pages/gabinete-digital/pedidos/pedidos.page.ts b/src/app/pages/gabinete-digital/pedidos/pedidos.page.ts index bdef5c4e8..2ff1e9906 100644 --- a/src/app/pages/gabinete-digital/pedidos/pedidos.page.ts +++ b/src/app/pages/gabinete-digital/pedidos/pedidos.page.ts @@ -53,6 +53,8 @@ export class PedidosPage implements OnInit { ngOnInit() { + this.LoadList() + this.router.events.forEach((event) => { if(event instanceof NavigationStart && '/home/gabinete-digital/pedidos?parecer=true'.startsWith(event.url) || event instanceof NavigationStart && '/home/gabinete-digital/pedidos?deferimento=true'.startsWith(event.url) diff --git a/src/app/pages/gabinete-digital/pendentes/pendentes.page.ts b/src/app/pages/gabinete-digital/pendentes/pendentes.page.ts index a479aa377..33a947cfb 100644 --- a/src/app/pages/gabinete-digital/pendentes/pendentes.page.ts +++ b/src/app/pages/gabinete-digital/pendentes/pendentes.page.ts @@ -50,6 +50,8 @@ export class PendentesPage implements OnInit { const location = window.location const pathname = location.pathname + location.search + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationEnd && event.url.startsWith(pathname)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/shared/gabinete-digital/despachos-pr/despachos-pr.page.ts b/src/app/shared/gabinete-digital/despachos-pr/despachos-pr.page.ts index db7457ab7..5191f345a 100644 --- a/src/app/shared/gabinete-digital/despachos-pr/despachos-pr.page.ts +++ b/src/app/shared/gabinete-digital/despachos-pr/despachos-pr.page.ts @@ -33,6 +33,8 @@ constructor ( ngOnInit() { + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith('/home/gabinete-digital?despachospr=true')) { 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 5c85d212d..544687609 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 @@ -30,6 +30,8 @@ export class DiplomasAssinarPage implements OnInit { ngOnInit() { + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && '/home/gabinete-digital?diplomasassinar=true'.startsWith(event.url)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/shared/gabinete-digital/diplomas/diplomas.page.ts b/src/app/shared/gabinete-digital/diplomas/diplomas.page.ts index dfcdfa62f..83c02725d 100644 --- a/src/app/shared/gabinete-digital/diplomas/diplomas.page.ts +++ b/src/app/shared/gabinete-digital/diplomas/diplomas.page.ts @@ -39,7 +39,8 @@ constructor( ngOnInit() { // update list - + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && '/home/gabinete-digital?diplomas=true'.startsWith(event.url)) { if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) { diff --git a/src/app/shared/gabinete-digital/expedientes-pr/expedientes-pr.page.ts b/src/app/shared/gabinete-digital/expedientes-pr/expedientes-pr.page.ts index c6ffe1005..02f107b1f 100644 --- a/src/app/shared/gabinete-digital/expedientes-pr/expedientes-pr.page.ts +++ b/src/app/shared/gabinete-digital/expedientes-pr/expedientes-pr.page.ts @@ -37,6 +37,8 @@ export class ExpedientesPrPage implements OnInit { ngOnInit() { + this.LoadList() + this.router.events.forEach((event) => { if (event instanceof NavigationStart && event.url.startsWith('/home/gabinete-digital?expedientespr=true') || diff --git a/src/app/shared/gabinete-digital/expedients/expedients.page.ts b/src/app/shared/gabinete-digital/expedients/expedients.page.ts index 823423c2b..821991bc2 100644 --- a/src/app/shared/gabinete-digital/expedients/expedients.page.ts +++ b/src/app/shared/gabinete-digital/expedients/expedients.page.ts @@ -43,6 +43,7 @@ export class ExpedientsPage implements OnInit { ngOnInit() { //Inicializar segment this.segment = "expedientes"; + this.LoadList() this.router.events.forEach((event) => { if (event instanceof NavigationStart && diff --git a/src/app/shared/gabinete-digital/pedidos/pedidos.page.ts b/src/app/shared/gabinete-digital/pedidos/pedidos.page.ts index bc9212c63..ecd2c9a10 100644 --- a/src/app/shared/gabinete-digital/pedidos/pedidos.page.ts +++ b/src/app/shared/gabinete-digital/pedidos/pedidos.page.ts @@ -50,7 +50,6 @@ export class PedidosPage implements OnInit { ngOnInit() { - this.router.events.forEach((event) => { if(event instanceof NavigationStart && '/home/gabinete-digital?parecer=true'.startsWith(event.url) || event instanceof NavigationStart && '/home/gabinete-digital?deferimento=true'.startsWith(event.url) || 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 4ad0e7ebb..b64235c28 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 @@ -88,7 +88,6 @@ export class DespachosPrOptionsPage implements OnInit { } this.popoverController.dismiss('close') - alert('closer!!!') }); }