This question is locked. New answers and comments are not allowed.
I want to be able to edit the detail grid. I have set up a master detail as follows, but I'm seeing some weird behaviour.
<% Html.Telerik().Grid <Event>(Model) .Name("grdEventConfig") .ClientEvents(events => events.OnError("Grid_onError") ) .Editable(editing => editing.Mode(GridEditMode.InCell)) .DataKeys(keys => { keys.Add(p => p.Id); }) .ToolBar(commands => { commands.Insert(); commands.SubmitChanges(); }) .DataBinding(dataBinding => dataBinding.Ajax() .Select("_SelectBatchEditing", "Event") .Update("_SaveBatchEditing", "Event") ) .Columns(columns => { columns.Bound(o => o.Id); columns.Bound(o => o.Name); columns.Bound(o => o.Description); columns.Bound(o => o.OkOutputValue); columns.Bound(o => o.FailOutputValue); columns.Command(commands => commands.Delete()).Width(80).Title("Delete"); }) .DetailView(detailView => detailView.ClientTemplate( Html.Telerik().Grid<EventParameter>() .Name("EventParameter_<#= Id #>") .Editable(editing => editing.Mode(GridEditMode.InCell)) .Columns(columns => { columns.Bound(ep => ep.Id); columns.Bound(ep => ep.FieldName); columns.Bound(ep => ep.FieldValue); }) .DataKeys(dataKeys => dataKeys.Add(ep => ep.Id)) .DataBinding(db => db.Ajax().Select("_SelectEventParameter","Event", new {eventId = "<#= Id #>"}).Update("_UpdateEventParameter","Event")).ToHtmlString()) ).Render();%>
When I expand the Detail, I get an input box rather than a grid. When I press 'Cancel changes' and expand the detail again, the Detail grid appears. I can't edit the Master or the Detail. Am I missing something?
Thanks for the help.