This question is locked. New answers and comments are not allowed.
I have a grid which is Ajax bound. One of the columns is an ActionLink.
I am not able to page (it just hangs). The first page renders fine. may paging works if I remove this column.
View:
<%= Html.Telerik().Grid(DataHelper.GetSearchList(ViewData))
.Name("SearchList")
.Columns(columns =>
{
columns.Add(o => o.Id).Format(Html.ActionLink("{0}", "View", "SearchGUI", new { Id = "{0}" }, null).ToString()).Encoded(false).Title("Id");
columns.Add(o => o.AddedBy);
})
.Ajax(ajax => ajax.Action("AjexBinding", "Search"))
.Pageable(pager => pager.PageSize(30).Style(GridPagerStyles.Numeric))
Controller:
[GridAction]
public virtual ActionResult AjexBinding()
{
IEnumerable<TItem> dataItems = Session[ListSessionKey] as IEnumerable<TItem>;
if (dataItems == null)
{
dataItems = new TItem[0];
}
return View(new GridModel<TItem> { Data = dataItems });
}
I am not able to page (it just hangs). The first page renders fine. may paging works if I remove this column.
View:
<%= Html.Telerik().Grid(DataHelper.GetSearchList(ViewData))
.Name("SearchList")
.Columns(columns =>
{
columns.Add(o => o.Id).Format(Html.ActionLink("{0}", "View", "SearchGUI", new { Id = "{0}" }, null).ToString()).Encoded(false).Title("Id");
columns.Add(o => o.AddedBy);
})
.Ajax(ajax => ajax.Action("AjexBinding", "Search"))
.Pageable(pager => pager.PageSize(30).Style(GridPagerStyles.Numeric))
Controller:
[GridAction]
public virtual ActionResult AjexBinding()
{
IEnumerable<TItem> dataItems = Session[ListSessionKey] as IEnumerable<TItem>;
if (dataItems == null)
{
dataItems = new TItem[0];
}
return View(new GridModel<TItem> { Data = dataItems });
}