<script type="text/javascript"> $(function () { $("#Grid").ejGrid({ // the datasource "window.gridData" is referred from jsondata.min.js dataSource: window.gridData, allowPaging: true, allowFiltering: true, enableHeaderHover: true, actionComplete:"actioncomplete", filterSettings: { filterType: "excel" }, columns: [ { field: "OrderID", isPrimaryKey: true, headerText: "Order ID", textAlign: ej.TextAlign.Right, width: 75 }, { field: "CustomerID", headerText: "Customer ID", width: 120 }, { field: "EmployeeID", headerText: "Employee ID", textAlign: ej.TextAlign.Right, width: 130 }, { field: "Freight", headerText: "Freight", textAlign: ej.TextAlign.Right,format: "{0:C2}", width: 80 }, {field:"OrderDate",headerText:"OrderDate", format: "{0:yyyy/MM/dd HH:mm:ss}", type: "datetime", width: 140}, { field: "ShipCity", headerText: "Ship City", width: 90 }, { field: "Verified", headerText: "Verified", width: 90 } ] }); $("#filtermenu").ejDropDownList({ "change": "selectChange", width: "120px", selectedItemIndex: 0 }) $("#sampleProperties").ejPropertiesPanel(); }); function selectChange(args) { $("#Grid").ejGrid("option", { "filterSettings": { "filterType": this.getSelectedValue() } }); } function actioncomplete(args){ if(args.requestType=="filterafteropen") this.element.find(".e-searchcontainer:visible").hide(); } |
Query 1 does not work