I have a pretty basic data model that I'm trying to bind to a grid but I get stuck on the implementation on how to bind this specific object because it's primary key is a composite of two different columns. I'm using the Kendo UI MVC Beta at the moment. Any suggestions on how this is done? I haven't had much look searching so far.
My two columns I need for the Id are ContactNumber and ClientNumber. Below I have ContactNumber only so far.
Edit: Crap, I just noticed there are dedicated forums for the MVC version of Kendo UI. I don't suppose a moderator could move this for me?
My two columns I need for the Id are ContactNumber and ClientNumber. Below I have ContactNumber only so far.
Edit: Crap, I just noticed there are dedicated forums for the MVC version of Kendo UI. I don't suppose a moderator could move this for me?
@(Html.Kendo().Grid(Model) .Name("Grid") .Columns(columns => { columns.AutoGenerate(true); columns.Command(command => { command.Edit(); command.Destroy(); }); }) .ToolBar(toolbar => toolbar.Create()) .Editable(editable => editable.Mode(GridEditMode.PopUp)) .DataSource(dataSource => dataSource .Server() .Model(model => model.Id(p => p.ContactNumber)) .Read(read => read.Action("Index", "ContactRep")) .Update(update => update.Action("Edit", "ContactRep")) .Create(update => update.Action("Create", "ContactRep")) .Destroy(update => update.Action("Delete", "ContactRep"))) .Pageable() .Sortable() .Filterable() .Groupable())