adding Telerik MVC DropDownList in TreeView Template -
i want add telerik mvc dropdownlist in treeview template, not working in way: can tell me whats problem?
<script id="treetemplate" type="text/kendo-tmpl"> <p>#: item.text #</p> <p>#=item.id#</p> <p> @(html.kendo() .dropdownlist() .name("permission_#:item.id#") .bindto(permissionable.getpermissiontitles()) .datatextfield("title") .datavaluefield("permission") .toclienttemplate() ) </p>
@(html.kendo().treeview() .name("pables") .templateid("treetemplate") .htmlattributes(new { @class = "tree tree-selectable" }) .bindto(model.permissionables, mapping => mapping .for<permissionable>(binding => binding .children(c => c.childs) .itemdatabound((item, c) => { item.text = c.title ?? c.name; item.id = c.id.tostring(); } ) ) ))
Comments
Post a Comment