public PageView query(PageView pageView, Log log) { Map<String, Object> map = new HashMap<String, Object>(); map.put("paging", pageView); map.put("t", log); List<Log> list = logMapper.query(map); pageView.setRecords(list); return pageView; }
@ResponseBody @RequestMapping("findByPage") public PageView findByPage(String pageNow, String pageSize, String column, String sort) throws Exception { LogFormMap logFormMap = getFormMap(LogFormMap.class); String order = ""; if (Common.isNotEmpty(column)) { order = " order by " + column + " " + sort; } else { order = " order by id asc"; } logFormMap.put("$orderby", order); logFormMap = toFormMap(logFormMap, pageNow, pageSize, logFormMap.getStr("orderby")); pageView.setRecords(logMapper.findByPage(logFormMap)); return pageView; }
public List<Log> queryAll(Log log) { return logMapper.queryAll(log); }
public void update(Log log) throws Exception { logMapper.update(log); }
public Log getById(String id) { return logMapper.getById(id); }
public void delete(String id) throws Exception { logMapper.delete(id); }
public void add(Log log) throws Exception { logMapper.add(log); }