mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
fix
This commit is contained in:
@@ -115,65 +115,6 @@ export class EventListPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
getEventToAproveFromDB() {
|
||||
|
||||
|
||||
|
||||
if (this.platform.is('desktop') || this.platform.is('mobileweb')) {
|
||||
this.storage.get('event-to-aproveMD').then((events = []) => {
|
||||
this.eventsMDGPRList = events
|
||||
})
|
||||
|
||||
this.storage.get('event-to-aprovePR').then((events = []) => {
|
||||
this.eventsPRList = events
|
||||
})
|
||||
} else {
|
||||
this.platform.ready().then(() => {
|
||||
|
||||
this.sqliteservice.getListOfEventAprove('Agenda Oficial MDGPR', 'Agenda Pessoal MDGPR').then((event: any[] = []) => {
|
||||
|
||||
this.eventsMDGPRList = this.sortService.sortDate(this.transformaDataDB(event), 'taskStartDate')
|
||||
|
||||
})
|
||||
|
||||
this.sqliteservice.getListOfEventAprove('Agenda Oficial PR', 'Agenda Pessoal PR').then((event: any[] = []) => {
|
||||
this.eventsPRList = this.sortService.sortDate(this.transformaDataDB(event), 'taskStartDate')
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
transformaDataDB(events = []) {
|
||||
let MdEventsArray = [];
|
||||
for (let i of events) {
|
||||
let eventMD = {
|
||||
Documents: i.Documents,
|
||||
actions: i.actions,
|
||||
activityInstanceName: i.activityInstanceName,
|
||||
formURL: i.formURL,
|
||||
interveners: i.interveners,
|
||||
originator: i.originator,
|
||||
serialNumber: i.serialNumber,
|
||||
taskStartDate: i.taskStartDate,
|
||||
totalDocuments: i.totalDocuments,
|
||||
workflowDisplayName: i.workflowDisplayName,
|
||||
workflowID: i.workflowID,
|
||||
workflowInstanceDataFields: JSON.parse(i.workflowInstanceDataFields),
|
||||
workflowInstanceFolio: i.workflowInstanceFolio,
|
||||
workflowInstanceID: i.workflowInstanceID,
|
||||
workflowName: i.workflowName,
|
||||
}
|
||||
|
||||
MdEventsArray.push(eventMD);
|
||||
}
|
||||
return MdEventsArray;
|
||||
}
|
||||
|
||||
segmentChanged(ev: any) {
|
||||
this.LoadToApproveEvents();
|
||||
}
|
||||
@@ -211,7 +152,6 @@ export class EventListPage implements OnInit {
|
||||
this.eventsList = []
|
||||
}
|
||||
|
||||
this.eventsList = this.eventsList
|
||||
this.eventsList = this.eventsList
|
||||
this.showLoader = false;
|
||||
this.eventoaprovacaostore.save(segment.OwnerUserId, this.eventsList)
|
||||
@@ -268,8 +208,8 @@ export class EventListPage implements OnInit {
|
||||
setTimeout(() => {
|
||||
this.LoadToApproveEvents();
|
||||
try {
|
||||
event?.target?.complete();
|
||||
} catch(error) {}
|
||||
event?.target?.complete();
|
||||
} catch(error) {}
|
||||
}, 1000);
|
||||
}
|
||||
|
||||
@@ -277,13 +217,6 @@ export class EventListPage implements OnInit {
|
||||
this.modalController.dismiss(null);
|
||||
}
|
||||
goBack() {
|
||||
// if(this.router.url == '/home/agenda/event-list') {
|
||||
// this.router.navigate(['/home/agenda']);
|
||||
// }
|
||||
// else if(this.router.url == '/home/gabinete-digital/event-list'){
|
||||
// this.router.navigate(['/home/gabinete-digital']);
|
||||
// }
|
||||
|
||||
this.RouteService.goBack()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user