fix, agenda list box not showing

This commit is contained in:
Peter Maquiran
2022-07-04 19:13:28 +01:00
parent e625fbfeb2
commit 744883bd6a
4 changed files with 28 additions and 10 deletions
+16 -5
View File
@@ -42,6 +42,8 @@ export class EventsService {
calendarIds = []
usersCalendarIds = []
hasSharedOficial: boolean = false;
hasSharedPessoal: boolean = false;
hasOwnOficial: boolean = false;
@@ -122,7 +124,7 @@ export class EventsService {
this.userCalendarNameOwnOficial = '';
this.userCalendarNameOwnPessoal = '';
this.calendarIds = [];
this.usersCalendarIds = [];
this.calendarNames = {}
this.calendarNamesAry = []
@@ -200,9 +202,14 @@ export class EventsService {
this.loggeduser.OwnerCalendars.forEach(calendar => {
if(!this.calendarIds.includes(calendar.OwnerUserId)) {
this.calendarIds.push(calendar.OwnerUserId)
if(!this.usersCalendarIds.includes(calendar.OwnerUserId)) {
this.usersCalendarIds.push(calendar.OwnerUserId)
}
if(!this.calendarIds.includes(calendar.CalendarId)) {
this.calendarIds.push(calendar.CalendarId)
}
this.hasOwnCalendar = true
if (calendar.CalendarName == 'Oficial') {
@@ -228,8 +235,12 @@ export class EventsService {
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
if(!this.calendarIds.includes(sharedCalendar.OwnerUserId)) {
this.calendarIds.push(sharedCalendar.OwnerUserId)
if(!this.usersCalendarIds.includes(sharedCalendar.OwnerUserId)) {
this.usersCalendarIds.push(sharedCalendar.OwnerUserId)
}
if(!this.calendarIds.includes(sharedCalendar.CalendarId)) {
this.calendarIds.push(sharedCalendar.CalendarId)
}
this.hasSharedCalendar = true