mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
Improve segment for agenda
This commit is contained in:
@@ -538,8 +538,8 @@ export class AgendaPage implements OnInit {
|
||||
//this.eventSource=[];
|
||||
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR' ) {
|
||||
this.eventService.getAllMdEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).subscribe(
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR' ) {
|
||||
this.eventService.getAllMdEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).subscribe(
|
||||
response => {
|
||||
|
||||
// calendar
|
||||
@@ -576,7 +576,7 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
});
|
||||
});
|
||||
|
||||
}
|
||||
else {
|
||||
@@ -627,7 +627,7 @@ export class AgendaPage implements OnInit {
|
||||
case "Pessoal":
|
||||
//Inicializa o array eventSource
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR') {
|
||||
this.eventService.getAllMdEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).subscribe(response => {
|
||||
|
||||
this.eventSource=[];
|
||||
@@ -703,7 +703,7 @@ export class AgendaPage implements OnInit {
|
||||
//Inicializa o array eventSource
|
||||
this.eventsListOficial = [];
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR') {
|
||||
this.eventService.getAllMdEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).subscribe(res => {
|
||||
this.eventSource=[];
|
||||
this.eventsListOficial = res.filter(data => data.CalendarName == "Oficial");
|
||||
|
||||
Reference in New Issue
Block a user