views.yearHeaderTemplate String|Function

The template used to render the year slots in "year" view.

Example

<div id="gantt"></div>
<script>
$("#gantt").kendoGantt({
  dataSource: [{
    id: 1,
    orderId: 0,
    parentId: null,
    title: "Task1",
    start: new Date("2014/6/17 9:00"),
    end: new Date("2014/7/01 11:00")
  }],
  views: [
    { type: "day"},
    { type: "week"},
    { type: "month"},
    {
      type: "year",
      yearHeaderTemplate: "#=kendo.toString(start, 'yyyy')#",
      selected: true
    }
  ]
});
</script>
In this article
Not finding the help you need? Improve this article