Refresh button for grid?

11 posts, 1 answers
  1. Jason
    Jason avatar
    5 posts
    Member since:
    Jul 2009

    Posted 29 Oct 2012 Link to this post

    I just migrated from the ASP.NET MVC controls, and would like to have the refresh button show on the bottom of the grid like it did in the old controls, is this possible with kendo?

    Thanks
  2. Answer
    Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2595 posts

    Posted 29 Oct 2012 Link to this post

    Hi Jason,

    The refresh button in Kendo UI Grid for ASP.NET MVC is not enabled by default, however it can be displayed using the following configuration: 
    .Pageable(pager => pager     
       .Refresh(true)
    )

    Regards,

    Iliana Nikolova
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. UI for ASP.NET MVC is VS 2017 Ready
  4. Jason
    Jason avatar
    5 posts
    Member since:
    Jul 2009

    Posted 29 Oct 2012 Link to this post

    Appreciate the answer, one thing that might be nice is the ability to turn on refresh but not paging...
  5. Josh
    Josh avatar
    50 posts
    Member since:
    Jul 2009

    Posted 16 Jan 2014 Link to this post

    +1 on the request, refreshing and paging should not be so tightly coupled
  6. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2595 posts

    Posted 20 Jan 2014 Link to this post

    Hello guys,

    We will appreciate it if you submit this idea as a feature request at Kendo UI UserVoice page - this way the community would be to evaluate it and if the suggestion gains popularity we will consider its implementation for future releases. 

    Regards,
    Iliana Nikolova
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  7. Carl
    Carl avatar
    195 posts
    Member since:
    Oct 2012

    Posted 03 May 2014 Link to this post

    Please add your comments and votes for a refresh button on the grid.  Here's the feedback link:

    http://kendoui-feedback.telerik.com/forums/127393-telerik-kendo-ui-feedback/suggestions/5751154-grid-refresh-should-independent-from-pageable-buil
  8. Ezequiel
    Ezequiel avatar
    36 posts
    Member since:
    Oct 2011

    Posted 26 Sep 2014 in reply to Iliana Nikolova Link to this post

    Is already available an option to have the footer with refresh button, but no paging?

    I want to display a grid with a defined height, with option to refresh, total number of rows but I don't want paging.
  9. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2595 posts

    Posted 29 Sep 2014 Link to this post

    Hi Ezequiel,

    In order to achieve this you should configure the pageable object. For your convenience here is a dojo example.

    Regards,
    Iliana Nikolova
    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.

     
  10. Ezequiel
    Ezequiel avatar
    36 posts
    Member since:
    Oct 2011

    Posted 29 Sep 2014 in reply to Iliana Nikolova Link to this post

    Iliana, but in this example, if you set info to true, you can see that it's displaying 20 of 91.

    I want to display all 91 rows in one page, but add the refresh button.

  11. Ezequiel
    Ezequiel avatar
    36 posts
    Member since:
    Oct 2011

    Posted 01 Oct 2014 Link to this post

    Here is an issue that I have, here is my Detail Grid:
    <%: this.Html.Kendo().Grid<EditableContainer>()
                                        .Name("GridContainers_#=Group#")
                                        .DataSource(ds => ds.Ajax().ServerOperation(true)
                                                            .Read("ReadContainer", "CadastrarCargaContainer", new { embarqueId = "#=EmbarqueId#", depositoId = "#=DepositoId#", transportadorId = "#=TransportadorId#", tipoContainerCodigo = "#=TipoContainerCodigo#", dataPrevisao = "#=DataPrevisaoParam #" })
                                                            .Update("UpdateContainer", "CadastrarCargaContainer", new { embarqueId = "#=EmbarqueId#", depositoId = "#=DepositoId#", transportadorId = "#=TransportadorId#", tipoContainerCodigo = "#=TipoContainerCodigo#", dataPrevisao = "#=DataPrevisaoParam #" })
                                                            .Model(m =>
                                                            {
                                                                m.Id(f => f.Id);
                                                            })
                                                            .Events(ev => ev.Error("error_handler.bind({WidgetID: 'GridContainers_#=Group#'})")))
                                        .Columns(columns =>
                                        {
                                            columns.Bound(c => c.Id).Hidden(true);
                                            columns.Bound(c => c.NumeroContainer).Width("120px");
                                            columns.Bound(c => c.Tara).Format("{0:N}").Width("25px");
                                            columns.Bound(c => c.PesoBrutoVolumes).Format("{0:N}").Width("75px");
                                            columns.Bound(c => c.NomeMotorista).Width("125px");
                                            columns.Bound(c => c.NumeroIdentidade).Width("75px");
                                            columns.Bound(c => c.Veiculo).Width("75px");
                                            columns.Command(command =>
                                            {
                                                command.Edit();
                                            }).Width("155px");
                                        })
                                        .Events(ev => ev.Save("SaveContainer"))
                                        .Pageable(page => page.Refresh(true).Input(false).PreviousNext(false).Numeric(false).Info(true))
                                        .Editable(edit => edit.Mode(Kendo.Mvc.UI.GridEditMode.InLine))
                                        .ToClientTemplate()
                %>


    Attached is the result.
    You see that I have 13, but it's only displayed 1-10.

    Thanks.
  12. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2595 posts

    Posted 02 Oct 2014 Link to this post

    Hi Ezequiel,

    For this scenario you should get the total of records and set it to as PageSize. As an example: 
    var dataSource = $("#grid").data("kendoGrid").dataSource,
       totalItems = dataSource.total();
     
       dataSource.pageSize(totalItems);

    Regards,
    Iliana Nikolova
    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
UI for ASP.NET MVC is VS 2017 Ready