Managing tasks in the left part of the Gantt.

4 posts, 0 answers
  1. Dmitry
    Dmitry avatar
    17 posts
    Member since:
    Oct 2014

    Posted 10 Apr 2015 Link to this post

    Hello,
    I want to manage events in the left (table) part of the Gantt. How can I do the following:

    1) Disable drag&drop (moving to new parent or to new position) tasks in the left part? Should I remove some piece of code to disable such behaviour or manipulation with some attributes should help?

    2) I want to color tasks in different colors (background and foreground). For instance one part of tasks should be green, other part should be red, another part should be yellow in the left part of the Gantt. Is it possible? 

     

  2. Bozhidar
    Admin
    Bozhidar avatar
    1103 posts

    Posted 13 Apr 2015 Link to this post

    Hi,

    You can disable the reorder functionality by adding the following code after the widget initialization:
    gantt.list._reorderDraggable.destroy();

    Here's a sample demonstrating this:
    http://dojo.telerik.com/IdoNo/2

    As for colowing the different cells, you can use CSS. For instance:
    .k-treelist .k-grid-content table td:first-child{
        background-color: yellow;
    }
    .k-treelist .k-grid-content table td:nth-child(2){
        background-color: green;
    }

    And here's the sample for that as well:
    http://dojo.telerik.com/IdoNo

    Regards,
    Bozhidar
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
  4. Dmitry
    Dmitry avatar
    17 posts
    Member since:
    Oct 2014

    Posted 13 Apr 2015 in reply to Bozhidar Link to this post

    Hello,

    Destroying _reorderDraggable was helpful. Thank you.

    Regarding coloring tasks. I want to color tasks in rows in the left Gantt part. I do not want to color columns.

    Color of task depends on some task properties. Is there any way to color tasks in the left Gantt part using java-script, like in "dataBound" event?

  5. Bozhidar
    Admin
    Bozhidar avatar
    1103 posts

    Posted 13 Apr 2015 Link to this post

    Hi,

    Thank you for clarifying. Here's an updated sample, where the tasks are colored depending on their status:
    http://dojo.telerik.com/ADaB/7

    Regards,
    Bozhidar
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
Back to Top
Kendo UI is VS 2017 Ready