mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-21 05:45:50 +00:00
git version
This commit is contained in:
@@ -16,7 +16,7 @@ import { MessagesPage } from './messages/messages.page';
|
||||
import { NewGroupPage } from './new-group/new-group.page';
|
||||
import { EditGroupPage } from 'src/app/shared/chat/edit-group/edit-group.page';
|
||||
import { Subject } from "rxjs/Rx";
|
||||
import { NavigationStart, Router, NavigationEnd } from '@angular/router';
|
||||
import { NavigationStart, Router, NavigationEnd, ActivatedRoute } from '@angular/router';
|
||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
||||
import { removeDuplicate } from 'src/plugin/removeDuplicate.js'
|
||||
import { environment } from 'src/environments/environment';
|
||||
@@ -113,6 +113,7 @@ export class ChatPage implements OnInit {
|
||||
private platform: Platform,
|
||||
private storageservice: StorageService,
|
||||
public ChatSystemService: ChatSystemService,
|
||||
private activatedRoute: ActivatedRoute,
|
||||
) {
|
||||
|
||||
this.headers = new HttpHeaders();
|
||||
@@ -141,14 +142,39 @@ export class ChatPage implements OnInit {
|
||||
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
|
||||
if (event instanceof NavigationEnd && event.url == '/home/chat' ||
|
||||
event instanceof NavigationEnd && event.url == "/home/chat?gbCreateGroup=true") {
|
||||
this.checkCreateGroup();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if (event instanceof NavigationEnd && event.url.startsWith('/home/chat')) {
|
||||
this.routeCheck()
|
||||
}
|
||||
});
|
||||
|
||||
this.routeCheck()
|
||||
}
|
||||
|
||||
routeCheck() {
|
||||
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const roomId = urlParams.get('roomId');
|
||||
|
||||
if(roomId) {
|
||||
const room = this.ChatSystemService.getRoomById(roomId);
|
||||
|
||||
if(room.isGroup) {
|
||||
this.segment = 'Grupos'
|
||||
this.openGroupMessagesPage(roomId)
|
||||
} else {
|
||||
this.segment = 'Contactos'
|
||||
this.openMessagesPage(roomId)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
checkCreateGroup() {
|
||||
|
||||
@@ -334,8 +334,6 @@ export class MessagesPage implements OnInit, AfterViewInit, OnDestroy {
|
||||
}
|
||||
|
||||
async goToEvent(event: any) {
|
||||
|
||||
// console.log(event)
|
||||
|
||||
let classs;
|
||||
if (window.innerWidth < 701) {
|
||||
|
||||
+1
-1
@@ -99,7 +99,7 @@
|
||||
<div *ngIf="p.userPermission([p.permissionList.Gabinete.md_tasks])" class="option-desc"> <div>Outras opções</div> </div>
|
||||
<button (click)="openExpedientActionsModal('0',fulltask)" class="btn-cancel" shape="round" >Efetuar Despacho</button>
|
||||
<button (click)="openExpedientActionsModal('1',fulltask)" class="btn-cancel" shape="round" >Solicitar Parecer</button>
|
||||
<button (click)="openExpedientActionsModal('2',fulltask)" class="btn-cancel" shape="round" >Pedido de Deferimento</button>
|
||||
<button *ngIf="!p.userPermission([p.permissionList.Gabinete.pr_tasks])" (click)="openExpedientActionsModal('2',fulltask)" class="btn-cancel" shape="round" >Pedido de Deferimento</button>
|
||||
<button *ngIf="p.userPermission([p.permissionList.Agenda.access])" (click)="openBookMeetingModal(task)" class="btn-cancel" shape="round" >Marcar Reunião</button>
|
||||
<button *ngIf="p.userPermission([p.permissionList.Gabinete.md_tasks])" (click)="attachDocument()" class="btn-cancel" shape="round" >Anexar Documentos</button>
|
||||
<button (click)="distartExpedientModal('descartar')" class="btn-cancel" shape="round" >Descartar</button>
|
||||
|
||||
@@ -166,8 +166,8 @@ export class GabineteDigitalPage implements OnInit {
|
||||
}
|
||||
|
||||
const pathname = window.location.pathname
|
||||
//this.router.events.forEach((event) => {
|
||||
//if (event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.router.events.forEach((event) => {
|
||||
if (event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.waitForDomService.selector({
|
||||
selector: 'app-gabinete-digital ion-content .aside-wrapper',
|
||||
callback: () => {
|
||||
@@ -180,8 +180,8 @@ export class GabineteDigitalPage implements OnInit {
|
||||
}
|
||||
}
|
||||
})
|
||||
//}
|
||||
//});
|
||||
}
|
||||
});
|
||||
|
||||
this.hideRefreshButton();
|
||||
|
||||
@@ -637,7 +637,6 @@ export class GabineteDigitalPage implements OnInit {
|
||||
|
||||
expedientes = expedientes.map((element) => this.expedienteTaskPipe.transform(element));
|
||||
|
||||
this.expedientegbstore.count = expedientes.length;
|
||||
this.expedientegbstore.reset(expedientes);
|
||||
this.updateAllProcess()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user