Save & restore visited page of grid

4 posts, 0 answers
  1. Grzegorz
    Grzegorz avatar
    1 posts
    Member since:
    Nov 2013

    Posted 25 May 2014 Link to this post

    Hi,


    I have a kendo mvc grid on Razor View, which is collecting data by AJAX request to Controller.

    I Would like to save page visited by user and when that user comes back grid automatically would load last visited page.

    View code:

    @(Html.Kendo().Grid<OrderListItemModel>()
        .Name("orders")
        .Columns(columns =>
        {
    ....
     .DataSource(dataSource => dataSource
            .Ajax()
            .Model(model => model.Id(order => order.Id))
            .PageSize(10)
            .Read(read => read.Action(Mvc.Crud.AjaxFilter,...

    any my AjaxFilterMethod:

    public virtual ActionResult AjaxFilter([DataSourceRequest]DataSourceRequest request, FilterModel filter)
            {
                var model = GetListItems(filter);
                var result = model.ToDataSourceResult(request);
                return Json(result);
            }

    any suggestions how i can achieve this?

    Best Regards
  2. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2203 posts

    Posted 28 May 2014 Link to this post

    Hi,

    If you need to preserve the Grid state across the pages in your application you can check the following CodeLibrary demos which shows two different approaches of achieving this:

    Regards,
    Vladimir Iliev
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. DAN
    DAN avatar
    14 posts
    Member since:
    Aug 2012

    Posted 12 Nov 2014 in reply to Vladimir Iliev Link to this post

    The "Save Grid state in session on server side" link above was almost what I needed. Do you have the code for a Telerik grid (not Kendo)? Apparently, the differences in Telerik vs Kendo components is substantial.
  4. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2203 posts

    Posted 13 Nov 2014 Link to this post

    Hi,

    Please note that as of June 2013, Telerik Extensions for ASP.NET MVC has reached its official End of Life (EOL), with no additional fixes or enhancements expected in the future. I would strongly suggest to upgrade to Telerik UI for ASP.NET MVC as we no longer provide support for the Telerik Extensions.

    Regards,
    Vladimir Iliev
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top