The onDataBound() code seems the same from this article
Hide edit and delete button based on the status of each record. - Grid - Kendo UI Forum[
^] ...quoting the source is always good
function onDataBound(e) {
}
For this code to work, you need to add isEditable and isDeletable or similarly named properties to your model Ex:
public class MyGridModel
{
public int ID { get; set; }
public bool isEditable { get; set; }
public bool isDeletable { get; set; }
...
}