Old events should not be able to be editted.

2 posts, 1 answers
  1. Kenny
    Kenny avatar
    11 posts
    Member since:
    Apr 2014

    Posted 12 Feb 2015 Link to this post


    Our users shouldn't be able to edit events which are in the past.

    I've come up with the solution I added below which will give an alert. However I'm looking for a cleaner solution ... one that would make such events unclickable or would for example give a small stop sign OnHover. 

    Could anyone point me in the right direction as to how I would locate these events with JQuery?

    Thanks in advance.

    Kind regards,

    function scheduler_OnEdit(e) {
            var now = new Date();

            if (e.event.TaskID > 0 && e.event.end < now) {
                alert("Events in the past cannot be changed.");
  2. Answer
    Georgi Krustev
    Georgi Krustev avatar
    3747 posts

    Posted 16 Feb 2015 Link to this post

    Hello Kenny,

    In general, the given solution is the one that you should use. Edit prevention is done in the edit event handler of the widget. If you would like to show some visual sign that will notify the end users, then you can use a custom eventTemplate that can render the special sign. This implementation depends entirely on your preferences.

    Best regards,
    Georgi Krustev
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top