From 4d65dc9277fbb262bf5062d052f6c2ae6cb269e1 Mon Sep 17 00:00:00 2001 From: "tiago.kayaya" Date: Thu, 7 Apr 2022 16:22:33 +0100 Subject: [PATCH] save --- .../app/src/main/assets/capacitor.config.json | 3 -- src/app/pages/inactivity/inactivity.page.ts | 29 ++++++++++++++++--- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/android/app/src/main/assets/capacitor.config.json b/android/app/src/main/assets/capacitor.config.json index 4f2d5e665..2399c4927 100644 --- a/android/app/src/main/assets/capacitor.config.json +++ b/android/app/src/main/assets/capacitor.config.json @@ -16,8 +16,5 @@ "sound" ] } - }, - "server": { - "url": "http://192.168.0.69:8100" } } diff --git a/src/app/pages/inactivity/inactivity.page.ts b/src/app/pages/inactivity/inactivity.page.ts index 9802d08ac..9d3c2387d 100644 --- a/src/app/pages/inactivity/inactivity.page.ts +++ b/src/app/pages/inactivity/inactivity.page.ts @@ -203,9 +203,20 @@ export class InactivityPage implements OnInit { } else { setTimeout(()=>{ - this.router.navigate(['/home/events'], {replaceUrl: true}); + + if(this.p.userPermission(this.p.permissionList.Agenda.access) || this.p.userPermission(this.p.permissionList.Gabinete.access)){ + this.router.navigate(['/home/events'], {replaceUrl: true}); + } + else if(this.p.userPermission(this.p.permissionList.Chat.access) && this.p.userPermission(this.p.permissionList.Actions.access)){ + this.router.navigate(['/home/chat']); + } + else if(this.p.userPermission(this.p.permissionList.Actions.access)){ + this.router.navigate(['/home/publications']); + } + + }, 5000) - + } } @@ -215,8 +226,18 @@ export class InactivityPage implements OnInit { setTimeout(()=>{ const code = this.code.join(''); SessionStore.setPin(code); - this.router.navigate(['/home/events']); - }, 5000) + + if(this.p.userPermission(this.p.permissionList.Agenda.access) || this.p.userPermission(this.p.permissionList.Gabinete.access)){ + this.router.navigate(['/home/events']); + } + else if(this.p.userPermission(this.p.permissionList.Chat.access) && this.p.userPermission(this.p.permissionList.Actions.access)){ + this.router.navigate(['/home/chat']); + } + else if(this.p.userPermission(this.p.permissionList.Actions.access)){ + this.router.navigate(['/home/publications']); + } + + }, 5000) }