1、JEECG默认不带模糊查询的,但实际开发中会经常用到模糊查询,因此要适当修改(在相应的查询处)。

JEECG实现模糊查询-LMLPHP
  @RequestMapping(params = "datagrid")
public void datagrid(BaseDevice device, HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) { String devicecode = device.getDevicecode();
String devicename = device.getDevicename();
String status = device.getStatus(); CriteriaQuery cq = new CriteriaQuery(BaseDevice.class,dataGrid);
if(StringUtils.isNotEmpty(devicecode)){
cq.add(Restrictions.sqlRestriction("devicecode like '%" + devicecode + "%'"));
}
if(StringUtils.isNotEmpty(devicename)){
cq.add(Restrictions.sqlRestriction("devicename like '%" + devicename + "%'"));
}
if(StringUtils.isNotEmpty(status)){
cq.add(Restrictions.sqlRestriction("status like '%" + status + "%'"));
} this.systemService.getDataGridReturn(cq, true);
TagUtil.datagrid(response, dataGrid);
}
JEECG实现模糊查询-LMLPHP

2、JEECG引用的解决办法:

http://blog.csdn.net/zhangdaiscott/article/details/74980298

05-11 20:47