I have a Grid with Ajax binding. One of the columns uses a client template with a ListView. Looks like that list view does not get initialized and bound, the grid cell where the ListView should be is rendered empty. The code for ListView is there it just does not get executed apparently. It does work with server-bound grid.
@(
Html.Kendo().Grid<
CollegeAnnouncement
>().Name("ItemsList2")
.Columns(col =>
{
col.Bound(i => i).ClientTemplate("<
input
type
=
'checkbox'
#if(Active){#
checked
=
'checked'
#}# />").Title("Active?");
col.Bound(i => i.Heading).Encoded(false);
col.Bound(i => i.StartDate).Format("{0:MM/dd/yyyy}");
col.Bound(i => i.EndDate).Format("{0:MM/dd/yyyy}");
col.Bound(i => i).ClientTemplate(Html.Kendo().ListView<
string
>()
.Name("ItemRoles#=CollegeAnnouncementID#")
.TagName("div")
.HtmlAttributes(new { @class = "itemRolesList" })
.DataSource(ds => ds.Read(read => read.Action("ItemRolesGet", "CollegeAnnouncements")
.Data("{itemID: #=CollegeAnnouncementID#}"))).ClientTemplateId("roleItemTemplate")
.ToClientTemplate().ToHtmlString());
col.Bound(i => i).ClientTemplate("<
a
href
=
'" + Url.Action("ItemDelete", new { itemID = "#=CollegeAnnouncementID#" }) + "'
>Delete</
a
>");
})
.DataSource(ds => ds.Ajax().Read(read => read.Action("CollegeAnnouncementsList", "CollegeAnnouncements")).Model(m => m.Id("CollegeAnnouncementID")))
.Pageable()
)