Problems with Grid

6 posts, 0 answers
  1. Rene
    Rene avatar
    65 posts
    Member since:
    Nov 2010

    Posted 01 Apr 2013 Link to this post

    I have just updated to the latest build this morning.

    2 issues with the grid:

    a) when I click insert (toolbar) - it works the first time - the 2nd time - i have to refresh the browser.

    b) when on the 2nd or higher page of a grid, clicking the insert does not have the popup appear.  By the looks of it, the shadow record is added to the grid on insert ... and since it's on another grid page - causes the grid to refresh and the popup edit window does not appear.

    Update:  It seems like the edit popup edit window will open the first time (editing grid row) - but after that - the attached image shows what's breaking.
  2. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2194 posts

    Posted 02 Apr 2013 Link to this post

    Hi Rene,

     
    Please find the answers of your questions below:

    1. This an known issue - more information can be found in this forum post.
    2. This is expected behavior when the ServerOperation configuration option is disabled - I would suggest to either enable the server operations or clear the current grid sort and filter before adding the new record. 

    e.g.:

    Add Toolbar template for add new records:
    .ToolBar(toolBar => toolBar.Template("<a class=\"k-button k-button-icontext k-grid-add\" href=\"javascript:void(0)\"><span class=\"k-icon k-add\"></span>Add new item</a>"))

    Manually clear the grid sort and filter before inserting new record:
    $(function () {
        $("a.k-grid-add").bind("mousedown", function (e) {
            e.preventDefault();
            var grid = $("#Grid").data("kendoGrid");
            grid.dataSource.sort({});
            grid.dataSource.filter({});
            //optionally go to page 1
            //grid.dataSource.page(1);
            grid.addRow();
        })
    })

    Kind Regards,
    Vladimir Iliev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Rene
    Rene avatar
    65 posts
    Member since:
    Nov 2010

    Posted 02 Apr 2013 Link to this post

    Thanks Vladimir.

    The ServerOperation(true) fixes problem b - thanks!

    For the problem a - I did follow the topic below, but do not see the internal build 2013.1.327 when logged in - I only see 2013.1.319 as per: 

    The suggested resolutions when using the MVC Extensions are:
    Use the Latest Internal Build version 2013.1.327
    Change the response of the Update/Destroy actions from just serializing the ModelState to:
    return Json(ModelState.IsValid ? new object(): ModelState.ToDataSourceResult());   // Did this.


  4. Rene
    Rene avatar
    65 posts
    Member since:
    Nov 2010
  5. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2194 posts

    Posted 04 Apr 2013 Link to this post

    Hi Rene,

     
    For convenience I created small screencast to show how to find the latest internal builds from your account at telerik.com.

    Kind Regards,
    Vladimir Iliev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  6. Rene
    Rene avatar
    65 posts
    Member since:
    Nov 2010

    Posted 04 Apr 2013 Link to this post

    Thanks Vladimir
Back to Top