Hello,
I am trying to implement the Grid / Checkbox selection feature in a grid which is inside a ClientDetailTemplate.
But I am in face of a disturbing issue since the selection is always done in the grid which belongs to the first detail template.
To be clear suppose that we have 2 master grids and 2 childs in their own detail template. Expand both the details of the 2 master grids. Then try to select all the rows of the 2nd nested grid by checking the header. The result is not the expected one because all the rows of the 1st nested grid are selected.
Hereafter my shortened view code:
@(Html.Kendo().Grid<SellerViewModel>()
.Name("SellersGrid")
.Columns(columns =>
{
columns.Bound(p => p.SellerId).Hidden();
columns.Bound(e => e.Name);
)
.Events(e => { e.DataBound("onHostSellersDataBound"); }) .Filterable() .Pageable(pager => pager.ButtonCount(3)) .Editable(editable => editable.Mode(GridEditMode.InCell)) .Sortable(sortable => sortable .AllowUnsort(true) .SortMode(GridSortMode.MultipleColumn)) .ClientDetailTemplateId("marketplaces_template") .DataSource(dataSource => dataSource .Ajax() .Read(read => read.Action("GetHostSellers", "CompetitorGroup", new { competitorGroupId = Model.CompetitorGroupId })) .Sort(sort => sort.Add("IsSelected").Descending()) .PageSize(25) .Model(model => { model.Id(p => p.UniqueId); model.Field(p => p.SellerId).Editable(false); model.Field(p => p.IsSelected).Editable(true); model.Field(p => p.Name).Editable(false); model.Field(p => p.IsActive).Editable(false); }) .ServerOperation(false)) )