mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 13:02:56 +00:00
Fix
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, NavigationEnd, NavigationExtras, Router } from '@angular/router';
|
||||
import { ActivatedRoute, NavigationEnd, NavigationExtras, NavigationStart, Router } from '@angular/router';
|
||||
import { DailyWorkTask, tasksList } from '../../../models/dailyworktask.model';
|
||||
import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { ModalController, NavParams } from '@ionic/angular';
|
||||
@@ -32,21 +32,22 @@ constructor(
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
// update list
|
||||
this.LoadList();
|
||||
// update list
|
||||
const location = window.location
|
||||
const pathname = location.pathname + location.search
|
||||
|
||||
setTimeout(()=>{
|
||||
// update list
|
||||
const location = window.location
|
||||
const pathname = location.pathname + location.search
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if (event instanceof NavigationEnd && event.url.startsWith(pathname)) {
|
||||
this.LoadList();
|
||||
this.router.events.forEach((event) => {
|
||||
if (event instanceof NavigationStart && '/home/gabinete-digital?diplomas=true'.startsWith(event.url)) {
|
||||
if(window.location.pathname.split('/').length >= 4 && window.location.pathname.startsWith('/home/gabinete-digital')) {
|
||||
this.refreshing()
|
||||
} else {
|
||||
this.LoadList()
|
||||
}
|
||||
});
|
||||
}, 10)
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -150,7 +151,7 @@ constructor(
|
||||
async refreshing() {
|
||||
setTimeout(() => {
|
||||
this.LoadList();
|
||||
}, 1500);
|
||||
}, 1000);
|
||||
}
|
||||
|
||||
doRefresh() {
|
||||
|
||||
Reference in New Issue
Block a user