Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lohithgn/237337bdb004e3e0c0f3c3c60105689f to your computer and use it in GitHub Desktop.
Save lohithgn/237337bdb004e3e0c0f3c3c60105689f to your computer and use it in GitHub Desktop.
@(Html.Kendo().Grid<Order>()
.Name("grid")
@*...*@
.Filterable(filterable => filterable.Operators(operators =>
{
operators.ForDate(options =>
{
options.Clear();
options.IsGreaterThanOrEqualTo("From Date");
options.IsLessThanOrEqualTo("To Date");
});
}))
.Columns(columns =>
{
columns.Bound(c => c.OrderID).Title("Order").Filterable(false);
columns.Bound(c => c.CustomerID).Title("Customer").Filterable(false);
columns.Bound(c => c.ShipName).Title("Shipper").Filterable(false);
columns.Bound(c => c.ShipCity).Title("City").Filterable(false);
columns.Bound(c => c.ShipCountry).Title("Country").Filterable(false);
columns.Bound(c => c.OrderDate).Title("Ordered").Format("{0:MMM dd yyyy}");
columns.Bound(c => c.RequiredDate).Title("Required").Filterable(false).Format("{0:MMM dd yyyy}");
columns.Bound(c => c.ShippedDate).Title("Shipped").Filterable(false).Format("{0:MMM dd yyyy}");
})
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment