fix agenda and publication

This commit is contained in:
Peter Maquiran
2024-05-24 11:29:53 +01:00
parent fcb6727f4e
commit 3eecefcfa6
38 changed files with 651 additions and 216 deletions
+56 -21
View File
@@ -886,7 +886,7 @@ export class EventsService {
return this.http.put<Event>(`${puturl}`, event, options)
}
editEvent(event: Event, conflictResolutionMode: number, sendInvitationsOrCancellationsMode: number, CalendarId? ): Observable<Event> {
editEvent(event: Event, conflictResolutionMode: number, sendInvitationsOrCancellationsMode: number, CalendarId ): Observable<Event> {
let arrayReq = [];
arrayReq.push(event);
const puturl = environment.apiURL + 'calendar/PutEvent';
@@ -917,18 +917,35 @@ export class EventsService {
this.headers = this.headersPrOficial;
} else {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const header = headers.find((header)=> {
return header?.get('CalendarId')?.includes(CalendarId)
})
if(CalendarId) {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const calendar = this.DetectCalendars(CalendarId)
const header = this.makeHeader(calendar)
this.headers = header
} else {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const header = headers.find((header)=> {
return header?.get('CalendarId')?.includes(CalendarId)
})
this.headers = header
}
this.headers = header
}
}
else {
@@ -939,18 +956,36 @@ export class EventsService {
this.headers = this.headersPrPessoal;
}
else {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const header = headers.find((header)=> {
return header?.get('CalendarId')?.includes(CalendarId)
})
this.headers = header
if(CalendarId) {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const calendar = this.DetectCalendars(CalendarId)
const header = this.makeHeader(calendar)
this.headers = header
} else {
const headers = [
this.headerSharedOficial,
this.headerSharedPessoal,
this.headerOwnPessoal,
this.headerOwnOficial
]
const header = headers.find((header)=> {
return header?.get('CalendarId')?.includes(CalendarId)
})
this.headers = header
}
}
}