mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
change events agenda
This commit is contained in:
@@ -25,6 +25,7 @@ export class EditEventPage implements OnInit {
|
||||
isRecurring:string;
|
||||
isEventEdited: boolean;
|
||||
loadedEvent: Event;
|
||||
initCalendarName: string;
|
||||
eventBody: EventBody;
|
||||
segment:string = "true";
|
||||
eventAttendees: EventPerson[];
|
||||
@@ -157,19 +158,16 @@ export class EditEventPage implements OnInit {
|
||||
|
||||
this.showLoader = true
|
||||
await this.eventsService.editEvent(this.postEvent, 2, 3).subscribe(async () => {
|
||||
this.showLoader = false
|
||||
|
||||
const alert = await this.alertController.create({
|
||||
cssClass: 'my-custom-class',
|
||||
header: 'Evento actualizado',
|
||||
buttons: ['OK']
|
||||
});
|
||||
|
||||
if(this.initCalendarName != this.postEvent.CalendarName){
|
||||
let body = {
|
||||
"EventId": this.postEvent.EventId,
|
||||
"CalendarDestinationName": this.postEvent.CalendarName,
|
||||
}
|
||||
console.log(body);
|
||||
await this.eventsService.changeAgenda(body).toPromise();
|
||||
}
|
||||
this.showLoader = false;
|
||||
this.toastService.successMessage()
|
||||
setTimeout(()=>{
|
||||
alert.dismiss();
|
||||
}, 1500);
|
||||
|
||||
},
|
||||
error => {
|
||||
this.showLoader = false
|
||||
|
||||
Reference in New Issue
Block a user