editTask

Opens the popup window to edit the GanttTask object which is received from the call.

Parameters

task kendo.data.GanttTask

A kendo.data.GanttTask object which represents the currently selected task.

Example - Edit the items from the Task GanttList.

<div id="gantt"></div>
<script>
$("#gantt").kendoGantt({
  dataSource: {
    transport: {
      read: {
        url: "https://demos.telerik.com/kendo-ui/service/gantttasks",
        dataType: "jsonp"
      }
    },
    schema: {
      model: {
        id: "id",
        fields: {
          id: { from: "ID", type: "number" },
          orderId: { from: "OrderID", type: "number", validation: { required: true } },
          parentId: { from: "ParentID", type: "number", nullable: true },
          start: { from: "Start", type: "date" },
          end: { from: "End", type: "date" },
          title: { from: "Title", defaultValue: "", type: "string" },
          percentComplete: { from: "PercentComplete", type: "number" },
          summary: { from: "Summary" },
          expanded: { from: "Expanded" }
        }
      }
    }
  }
});
$(".k-gantt").delegate(".k-gantt-treelist .k-grid-content tr", "click", function(e) {
  var gantt = $("#gantt").data("kendoGantt");
  var task = gantt.dataItem(this);
  gantt.editTask(task);
});
</script>
In this article