Articles in this section
Category / Section

How to allows the user to perform only edit action in Scheduler?

1 min read

This knowledge base article allows the user to perform only edit action in Scheduler.

 

Step 1: Create a JS Scheduler by referring the following User Guide link.

https://ej2.syncfusion.com/javascript/documentation/schedule/getting-started/#initialize-the-scheduler

Step 2: Bind popupOpen event to prevent the editor window for adding new event and to disable the delete button in event editor window as shown in the following code example.

popupOpen: function (args) {
                    if (args.target.classList.contains("e-work-cells")) {
                        args.cancel = true;
                        return;
                    }
                    var buttonElement = (args.type === "QuickInfo") ? ".e-event-popup .e-delete" : ".e-schedule-dialog .e-event-delete";
                    var deleteButton = document.querySelector(buttonElement);
                    deleteButton.ej2_instances[0].disabled = true;
                }

Step 3: Run the sample, clicking the event will display the quick popup with disabled delete button and clicking the cell will prevent the quick popup as shown below. o/p

 Figure 1: Scheduler with only Edit action.

Please refer the example from the following GitHub link.

Example – Scheduler with only Edit action

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments
Please  to leave a comment
Access denied
Access denied