KendoUI Grid MVC4 hide delete button in the list if there is depent records
.CellAction(cell=>{
if (cell.Column.Title == "Delete" && cell.DataItem.ChildRecords.Count > 0)
{
cell.HtmlAttributes["style"] = "visibility:hidden";
}
})
alternatively:
columns.Template(
@
).Title("Delete");
No comments:
Post a Comment