Be able to bind the DataSource to data without a separate controller and AJAX fetch for use with Razor Pages.
The use case is a shared data source that drives multiple components on a page for example a chart and grid filtered with an auto complete box.
In a grid I can do this:
@(Html.Kendo().Grid(Model.Data)
.Name("Grid")
.Columns(columns =>
{
columns.Bound(p => p.Description).Title("Description");
columns.Bound(p => p.RecordCount).Title("Number Sold").Width(130);
columns.Bound(p => p.TotalValue).Title("Total Value").Width(130);
columns.Bound(p => p.AverageValue).Title("Average Value").Width(130);
columns.Bound(p => p.Rank).Title("Rank").Width(130);
columns.Bound(p => p.RankMax).Title("Bananas").Width(130);
columns.Bound(p => p.LowerQuartile).Title("LowerQuartile").Width(130);
columns.Bound(p => p.Median).Title("Median").Width(130);
columns.Bound(p => p.UpperQuartile).Title("UpperQuartile").Width(130);
})
.Sortable()
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(20)
.ServerOperation(false)
)
)
Would want to be able to do same with the DataSource like:
@(Html.Kendo().DataSource(Model.Data)
.Name("dataSource1")
.Ajax(dataSource => dataSource
.ServerOperation(false)
)
)