KendoUI调度程序事件颜色

时间:2017-01-05 06:02:03

标签: javascript angularjs kendo-ui kendo-scheduler

我的resources: []数组中有以下代码,用于设置事件的颜色。在我的情况下,实际的事件图块不会改变颜色,但在事件的color下拉列表中,我看到了三个预期的选项,因为它们没有效果。

                {
                    field: 'color',
                    dataColorField: 'color',
                    dataValueField: 'color',
                    dataSource: [
                        { text: 'blue', color: 'blue' },
                        { text: 'red', color: 'red' },
                        { text: 'green', color: 'green' }
                    ]
                }

As you can see, there are options to change the edited tile to blue, green, or red, but none of them have any effect.

1 个答案:

答案 0 :(得分:0)

在您的dataSource资源字段中,“value”字段缺失。因此显示默认颜色。如果在resources数组的dataSource中添加value属性,您将看到不同颜色的不同资源事件。