Hi
Kolokouris,
Based
on your requirement, we prepared an Angular Schedule with context menu sample.
To select multiple events use ctrl + single click and mouse right click to
select the Delete option in context menu to delete all selected appointments.
Refer to the shared sample for your reference. Kindly try it out.
[app.component.html]
|
<ejs-schedule
#scheduleObj
height="650px"
[selectedDate]="selectedDate"
[allowResizing]="allowResizing"
[allowDragAndDrop]="allowDragDrop"
[eventSettings]="eventSettings"
(eventClick)="eventClick($event)"
>
</ejs-schedule>
<ejs-contextmenu
#menuObj
cssClass="schedule-context-menu"
target=".e-schedule"
[items]="menuItems"
(beforeOpen)="onContextMenuBeforeOpen($event)"
(select)='onMenuItemSelect($event)'></ejs-contextmenu
>
|
[app.component.ts]
|
public eventClick(args: any) {
this.multiselectEvents.push(this.scheduleObj.getEventDetails(args.element));
}
public onMenuItemSelect(args: MenuEventArgs): void {
case 'Delete':
this.multiselectEvents.forEach((eventObj) => {
this.scheduleObj.deleteEvent(eventObj);
this.multiselectEvents = [];
});
break;
}
}
|
Sample
link: delete multiple event using context menu (forked) -
StackBlitz
Please
get back to us if you need any further assistance.
Regards,
Vijay