new route on notificatiwon serice

This commit is contained in:
Eudes Inácio
2023-06-11 13:54:53 +01:00
3 changed files with 17 additions and 10 deletions
@@ -1,7 +1,7 @@
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';
import { ProcessesService } from 'src/app/services/processes.service';
import { ModalController } from '@ionic/angular';
import {NavigationEnd, NavigationExtras, Router } from '@angular/router';
import {NavigationEnd, NavigationExtras, Router, NavigationStart } from '@angular/router';
import { LoginUserRespose } from 'src/app/models/user.model';
import { ExpedientsPage } from 'src/app/shared/gabinete-digital/expedients/expedients.page';
@@ -242,9 +242,9 @@ export class GabineteDigitalPage implements OnInit {
this.LoadCounts();
this.checkFilter();
const pathname = window.location.pathname
const pathname = '/home/gabinete-digital'
this.router.events.forEach((event) => {
if (event instanceof NavigationEnd && event.url == pathname) {
if (event instanceof NavigationEnd && event.url.includes(pathname)) {
this.waitForDomService.selector({
selector: 'app-gabinete-digital ion-content .aside-wrapper',
callback: () => {
@@ -389,6 +389,7 @@ export class GabineteDigitalPage implements OnInit {
// console.log(this.router.url, this.router.url.includes('processes=true'))
// alert('hello')
console.log(this.router.url, this.router.url)
if (this.router.url.includes('processes=true')) {
this.openAllProcessesPage();
this.checkUser()
@@ -510,7 +511,7 @@ export class GabineteDigitalPage implements OnInit {
this.closeAllDesktopComponents();
let navigationExtras: NavigationExtras = { queryParams: { "processes": true, } };
if (window.innerWidth < 701) {
this.router.navigate(['/home/gabinete-digital']);
// this.router.navigate(['/home/gabinete-digital']);
}
else {
// this.router.navigate(['/home/gabinete-digital'], navigationExtras);
@@ -276,6 +276,12 @@ export class NotificationsService {
this.zone.run(() => this.router.navigate(['/home/gabinete-digital/diplomas-assinar', notification.notification.data.IdObject, 'gabinete-digital']));
}
else if (notification.notification.data.Service === "gabinete-digital" && notification.notification.data.Object === "diploma-revisao") {
this.zone.run(() => this.router.navigate(['/home/gabinete-digital/diplomas', notification.notification.data.IdObject, 'gabinete-digital']));
}
else if (notification.notification.data.Service === "gabinete-digital" && notification.notification.data.Object === "expedientes-pr") {
this.zone.run(() => this.router.navigate(['/home/gabinete-digital/expedientes-pr', notification.notification.data.IdObject, 'gabinete-digital']));
} else if (notification.notification.data.Service === "chat") {
+6 -6
View File
@@ -1,12 +1,12 @@
export let versionData = {
"shortSHA": "6334142ab",
"SHA": "6334142ab9027310ea080e64e7d1b0dfd6a63ac9",
"shortSHA": "1a64e616a",
"SHA": "1a64e616a34824029b032a69c1fd1145a6567d3b",
"branch": "feature/gabinete-search",
"lastCommitAuthor": "'Eudes Inácio'",
"lastCommitTime": "'Sun Jun 11 11:37:44 2023 +0100'",
"lastCommitMessage": "Peter bug solved",
"lastCommitNumber": "4988",
"lastCommitTime": "'Sun Jun 11 12:23:21 2023 +0100'",
"lastCommitMessage": "solved",
"lastCommitNumber": "4991",
"change": "",
"changeStatus": "On branch feature/gabinete-search\nYour branch and 'origin/feature/gabinete-search' have diverged,\nand have 18 and 3 different commits each, respectively.\n (use \"git pull\" to merge the remote branch into yours)\n\nAll conflicts fixed but you are still merging.\n (use \"git commit\" to conclude merge)\n\nChanges to be committed:\n\tmodified: .gitignore\n\tmodified: src/app/models/dailyworktask.model.ts\n\tmodified: src/app/pages/gabinete-digital/gabinete-digital.page.html\n\tmodified: src/app/shared/popover/opts-expediente/opts-expediente.page.ts",
"changeStatus": "On branch feature/gabinete-search\nYour branch and 'origin/feature/gabinete-search' have diverged,\nand have 19 and 1 different commits each, respectively.\n (use \"git pull\" to merge the remote branch into yours)\n\nAll conflicts fixed but you are still merging.\n (use \"git commit\" to conclude merge)\n\nChanges to be committed:\n\tmodified: src/app/pages/gabinete-digital/gabinete-digital.page.ts\n\tmodified: src/app/services/notifications.service.ts",
"changeAuthor": "eudes.inacio"
}