Question

I've noticed that the scheduler widget does things a bit differently from other widgets. In fact, I read in the documentation that the DS is a different one:

"http://docs.kendoui.com/api/framework/schedulerdatasource"

Anyways, on to my two questions.

  1. when i was doing a template for the day cells, i noticed that if i used value called 'date' it would automatically use the correct date value for that day cell. But i never created this date variable, not did i include it in my datasource. So where did it come from? if its provided through framework, what other values similar to this one are available to me? where can i find some documentation on this?

  2. For kendo widgets, when you apply a datasource and a template, it automatically maps each datasource item to one item in the widget (e.g. one row in the grid, one item in the list view etc.). its a one to one correlation. But this is not the case for the scheduler datasource since, like i stated above, it is a different type of datasource (its a schedulerdatasource). The scheduler datasource mandates that each item in the datasource have a start date and an end date so it can map it to the corresponding cell. hence, this destroys the one-to-one relationship of datasource item to day [template]. How can i revert to the behavior of the datasource with other widgets? do i have to somehow configure it to overwrite the schedulerdatasource to the original datasource? i want to preserve the correlation behavior of 1-to-1 between my datasource and my day template.

just to give a generic example of what i am trying to accomplish with this, imagine that instead of doing entrys with time slots, i want to instead have my scheduler display daily summaries of how many hours i worked out, how many calories i ate, amount of hours i slept etc. But i do not want to associate those amounts with hours in the day.

-- Sorry that was technically more than two questions. But thanks in advance! -B

Was it helpful?

Solution

Straight to your questions:

  1. The options available in the eventTemplate are listed in the documentation.
  2. The SchedulerDataSource does one thing more than the regular DataSource - it expands recurring events. This means that for one event which says repeats two days the SchedulerDataSource creates two data items - one for each day. If you don't have any recurring events then you would have the one-to-one mapping. The scheduler can only be bound to a SchedulerDataSource instance (it will throw an exception otherwise).

It looks that the scheduler may not be the widget you are looking for. If you just want to display a list of items the ListView or Grid widgets may be a better fit.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top