标签: kendo-dropdown
我为kendo下拉列表设置了数据属性,如下所示。
.HtmlAttributes(new {style =“width:100%”,required =“required”,data_id = item.Id})
我试过这个
$(本)。数据( “ID”);
但它给出了“未定义”。我如何在更改事件中获取此数据属性值
答案 0 :(得分:1)
我使用如下,它适用于我
this.element.attr('data-id');