【发布时间】:2018-01-30 11:08:10
【问题描述】:
我想通过在 TreeList 中使用自定义命令在 Kendo Grid 等一个字段中使用 2 个或更多按钮,但我不能这样做。有人有解决办法吗?
【问题讨论】:
我想通过在 TreeList 中使用自定义命令在 Kendo Grid 等一个字段中使用 2 个或更多按钮,但我不能这样做。有人有解决办法吗?
【问题讨论】:
您只需将一组按钮添加到列命令属性:
$("#treeList").kendoTreeList({
columns: [
{ field: "name" },
{
command: [
{
name: "Cust1",
text: "Custom1",
click: function(e) {
alert("Custom1");
}
},
{
name: "Cust2",
text: "Custom2",
click: function(e) {
alert("Custom2");
}
},
]
}
],
editable: true,
dataSource: dataSource
});
【讨论】: