https://blog.csdn.net/bigtree_3721/article/details/71479667
https://www.jb51.net/article/130922.htm
https://blog.csdn.net/gao454917848/article/details/46355877
第二种 :
serviceWorkOrderList.search = function () {var queryData = {};queryData['workOrderNo'] = $("#workOrderNo").val().replace(/(^\s*)|(\s*$)/g, "");queryData['shopCondition'] = $("#shopCondition").val().replace(/(^\s*)|(\s*$)/g, "");queryData['buyerCondition'] = $("#buyerCondition").val().replace(/(^\s*)|(\s*$)/g, "");queryData['serviceCondition'] = $("#serviceCondition").val().replace(/(^\s*)|(\s*$)/g, "");queryData['status'] = $("#status").val()==0 ? "":$("#status").val();queryData['identity'] = $("#identity").val()==0 ? "":$("#identity").val();/*queryData['province'] = $("#province").val().replace(/(^\s*)|(\s*$)/g, "");if ($("#city").val() != null && $("#province").val() != null) {queryData['city'] = $("#city").val().replace(/(^\s*)|(\s*$)/g, "");}else{queryData['city'] = "";}if ($("#region").val() != null && $("#city").val() != null && $("#province").val() != null) {queryData['region'] = $("#region").val().replace(/(^\s*)|(\s*$)/g, "");}else{queryData['region'] = "";}*/var regionArr=[];$(".isCan strong").each(function(){regionArr.push(this.id);});queryData['regionArr'] = regionArr.toString();queryData['startTime'] = $("#startTime").val()==undefined ? "":$("#startTime").val();queryData['endTime'] = $("#endTime").val()==undefined ? "":$("#endTime").val();queryData['exceptionStatus'] = $("#exceptionStatus").val()==undefined || $("#exceptionStatus").val()=="0"? "":$("#exceptionStatus").val();serviceWorkOrderList.table.refresh({query: queryData});
};@RequestMapping(value = "/listPage")@ResponseBodypublic Object listPage(@RequestParam(required = false) String workOrderNo,@RequestParam(required = false) String shopCondition,@RequestParam(required = false) String buyerCondition,@RequestParam(required = false) String serviceCondition,@RequestParam(required = false) String province, @RequestParam(required = false) String city,@RequestParam(required = false) String region, @RequestParam(required = false) List<Integer> regionArr,@RequestParam(required = false) String identity,@RequestParam(required = false) String status, @RequestParam(required = false) String startTime,@RequestParam(required = false) String endTime, @RequestParam(required = false) String exceptionStatus,HttpSession session) {}