How to disable events in the Kendo UI Scheduler? I just want to do it read-only

How to disable event in kendo user interface scheduler? I’m studying an example from the official examples of the website and I see that in the entire cell in the event there is a double-click event to create and delete other events, but now I just use it to show the result, and how to prevent all creation, deletion, and editing events?

+4
source share
2 answers

Use option editable:

$("#scheduler").kendoScheduler({
  date: new Date("2013/6/6"),
  dataSource: [
    {
      start: new Date("2013/6/6 08:00 AM"),
      end: new Date("2013/6/6 09:00 AM"),
      title: "Brunch"
    }
  ],
  editable: false
});

or if you use MVC wrappers:

.Editable(false)

If you want to disable certain events, see this answer .

+7

, , .

, , , (isReadOnly , ):

var saveAndDelete = $(".k-scheduler-update, .k-scheduler-delete");

if (e.event.isReadOnly === true )
    saveAndDelete.hide();
else
    saveAndDelete.show();
+2

Source: https://habr.com/ru/post/1537214/


All Articles