kendo ui mvc grid refresh jQuery

kendo ui mvc grid refresh jQuery

kendo ui mvc grid refresh jQuery / Kendo UI Grid MVC Refresh JQuery


    @(Html.Kendo().Grid<Entities.Model.Orders>()
        .Name("GridOrders")
        .Columns(columns =>
        {
            columns.Bound(p => p.OrderNumber).Title("Order Detail").Filterable(true);
        })
        .ClientRowTemplate(Html.Partial("_OrderTabs").ToHtmlString())
        .DataSource(ds => ds
            .Ajax()
            .Sort(srt => srt.Add(e => e.IDEPOrderID).Descending())
            .Read(read => read.Action("GetOrders", "Orders"))
            .PageSize(PageSize)
        )
       .Events(e => e.DataBound("onDataBoundOrders"))
        .Pageable()
        .Sortable()
        .Resizable(e => e.Columns(true))
            .Pageable(pager => pager
                .Refresh(true)
            )
        .Filterable(filterable => filterable
            .Extra(false)
            .Operators(operators => operators
                .ForString(str => str.Clear()
                    .StartsWith("Starts with")
                    .EndsWith("Ends with")
                    .Contains("Contains")
                    .DoesNotContain("Not contains")
                    )
                )
       )
)

JQuery / JavaScript Code for Refresh after UI Actions.

function refreshKendoUiGrid() {
        //THE BELOW CODE IS USED FOR REFRESH THE DATA.
        var grid = $("#GridOrders").data("kendoGrid");
        if (grid != null) {
            grid.dataSource.read();
        }
}


ANIL SINGH

Hey! I'm Anil Singh. I author this blog. I'm Active Blogger, Programmer. I love learning new technologies, programming, blogging and participating the forum discussions more...
My Blogs - http://www.code-sample.com and http://www.code-sample.xyz
My Books - Google Amazon and Flipkart Book Store!

You Might Also Like
Post a Comment
www.code-sample.com/. Powered by Blogger.
ASK Questions
SQL Server NodeJs TypeScript JavaScript Angular SQL Server My Book