I want my grid column menu filters to have default operands based on the column type: for dates gte and lte, for texts contains etc. I have tried to do this by following the example in http://demos.telerik.com/kendo-ui/grid/filter-menu-customization, however it seems the operands tend to switch to default operand eq - first one in the dropdown list - if a value to filter by is not picked and applied.
var columnMenu = function(e) { var $filterMenu = e.container.find(".k-filter-menu"); var $firstValueDropDown = $filterMenu.find("select:eq(0)"); var firstValueDropDown = $firstValueDropDown.data("kendoDropDownList"); if (!firstValueDropDown.dataSource.view().length) { $firstValueDropDown.closest(".k-widget").hide(); } if (($filterMenu.find(".k-datepicker").length) || ($filterMenu.find(".k-datetimepicker").length)) { firstValueDropDown.value("gte"); firstValueDropDown.trigger("change"); var logicDropDown = $filterMenu.find("select:eq(1)").data("kendoDropDownList"); logicDropDown.value("and"); logicDropDown.trigger("change"); var secondValueDropDown = $filterMenu.find("select:eq(2)").data("kendoDropDownList"); secondValueDropDown.value("lte"); secondValueDropDown.trigger("change"); } };