Merge with developer branch

This commit is contained in:
Eudes Inácio
2021-12-17 10:48:36 +01:00
71 changed files with 864 additions and 417 deletions
+12 -8
View File
@@ -7,7 +7,7 @@ import {
ComponentFactoryResolver,
ComponentRef,
ComponentFactory,
Output
Output,
} from '@angular/core';
import { ModalController, Platform } from '@ionic/angular';
import { AuthService } from 'src/app/services/auth.service';
@@ -17,7 +17,6 @@ import { ContactsPage } from './messages/contacts/contacts.page';
import { MessagesPage } from './messages/messages.page';
import { NewGroupPage } from './new-group/new-group.page';
import { Storage } from '@ionic/storage';
import { AlertService } from 'src/app/services/alert.service';
import { EditGroupPage } from 'src/app/shared/chat/edit-group/edit-group.page';
import * as Rx from "rxjs/Rx";
import { Message } from 'src/app/models/message.model';
@@ -138,6 +137,7 @@ export class ChatPage implements OnInit {
}
ngOnInit() {
console.log(this.loggedUserChat);
this.segment = "Contactos";
@@ -168,19 +168,23 @@ export class ChatPage implements OnInit {
this.router.events.forEach((event) => {
if (event instanceof NavigationStart && event.url.startsWith('/home/chat')) {
if (window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/chat')) {
//alert('OIII')
} else {
if (this.dataService.get("newGroup")) {
this.openNewGroupPage();
}
if (this.dataService.get("newGroup")) {
this.openNewGroupPage();
}
else{
this.closeAllDesktopComponents();
this.showEmptyComponent = true;
}
}
else{
this.dataService.set("newGroup", false);
}
});
}
ngOnDestroy() {
this.setStatus('offline');
this.dataService.set("newGroup", false);
console.log('On Destroy')
}