mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 13:26:08 +00:00
Merge branch 'develop_bitOut' into consoleCle
This commit is contained in:
@@ -16,6 +16,7 @@ import { RochetChatConnectorService } from 'src/app/services/chat/rochet-chat-co
|
||||
import { ChatSystemService } from 'src/app/services/chat/chat-system.service';
|
||||
import { ChatService } from 'src/app/services/chat.service';
|
||||
import { Platform } from '@ionic/angular';
|
||||
import { SqliteService } from 'src/app/services/sqlite.service';
|
||||
|
||||
|
||||
|
||||
@@ -53,6 +54,7 @@ export class LoginPage implements OnInit {
|
||||
public ChatSystemService: ChatSystemService,
|
||||
private ChatService: ChatService,
|
||||
private platform: Platform,
|
||||
private sqliteservice: SqliteService,
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -141,6 +143,7 @@ export class LoginPage implements OnInit {
|
||||
|
||||
} else {
|
||||
|
||||
this.sqliteservice.deleteAllTables();
|
||||
this.RochetChatConnectorService.logout();
|
||||
this.clearStoreService.clear();
|
||||
this.ChatSystemService.clearChat();
|
||||
@@ -163,7 +166,12 @@ export class LoginPage implements OnInit {
|
||||
this.getToken();
|
||||
|
||||
if(!this.platform.is('desktop') && !this.platform.is('mobileweb')) {
|
||||
this.router.navigateByUrl('/pin', { replaceUrl: true });
|
||||
if(this.sessionStore.hasPin) {
|
||||
this.router.navigateByUrl('/home/events');
|
||||
} else {
|
||||
this.router.navigateByUrl('/pin', { replaceUrl: true });
|
||||
}
|
||||
|
||||
} else {
|
||||
this.router.navigateByUrl('/home/events');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user