Turning grouping on and off

2 posts, 0 answers
  1. Jens
    Jens avatar
    1 posts
    Member since:
    Nov 2013

    Posted 27 Nov 2013 Link to this post

    Hi!
    I have a basic scheduler working in MVC4. However I have a question as to how I enable or disable grouping on the fly.
    I'm hoping to create a button either in the UI or as a separate javascript button that I can use to turn the resource grouping on or off.

    Is this possible?
    Thank you.

  2. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2172 posts

    Posted 29 Nov 2013 Link to this post

    Hi Jens,

    Basically changing the grouping after initialization currently is not supported out of the box, however you can try to modify the "group" option of the Scheduler and refresh the current view:

    scheduler = $(scheduler).data("kendoScheduler");
    //remove one of the groups:
    scheduler.options.group.resources.splice(0,1);
    //refresh the view
    scheduler.view(scheduler.view().name);
     
    //add new group:
    scheduler.options.group.resources.push("Rooms");
    //refresh the view
    scheduler.view(scheduler.view().name);

    Regards,
    Vladimir Iliev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. UI for ASP.NET MVC is VS 2017 Ready
Back to Top