mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 13:02:56 +00:00
performance
This commit is contained in:
@@ -17,6 +17,7 @@ import { EventsService } from './events.service';
|
||||
import { SortService } from './functions/sort.service';
|
||||
import { customTask } from '../models/dailyworktask.model';
|
||||
import { Router } from '@angular/router';
|
||||
import { v4 as uuidv4 } from 'uuid'
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
@@ -75,10 +76,21 @@ export class TaskService {
|
||||
this.updateAllProcess();
|
||||
this.updateCount()
|
||||
this.runCallback();
|
||||
|
||||
document.addEventListener('resume', function () {
|
||||
this.loadAllTask();
|
||||
});
|
||||
}
|
||||
|
||||
registerCallback({funx, id}) {
|
||||
registerCallback({funx, id = uuidv4()}) {
|
||||
|
||||
this.callbacks[id] = { funx, id}
|
||||
|
||||
return {
|
||||
delete: ()=> {
|
||||
delete this.callbacks[id]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
runCallback() {
|
||||
|
||||
Reference in New Issue
Block a user