@Override public Result<PageInfo<HEvent>> selectEvent(Integer pageNo, Integer pageSize, String codeName, String startDate, String endDate, Integer dType, String eName){ long begin = System.currentTimeMillis(); pageNo = pageNo == null || pageNo < 1 ? 1 :pageNo; pageSize = pageSize == null || pageSize < 1 ? 10 :pageSize; PageHelper.startPage(pageNo, pageSize); List<HEvent> hdeList = hMapper.selectEventByPage(codeName, startDate, endDate, dType, eName); if(!hdeList.isEmpty()){ for(int i=0; i<hdeList.size(); i++){ HEvent h = hdeList.get(i); h.setDName(getTypeName((HashMap<Integer, String>) eTypeMap, h.getDType())); } } PageInfo<HEvent> pageInfo = new PageInfo<>(hdeList); log.info("耗时->{}ms", System.currentTimeMillis() - begin); return Result.build(pageInfo); }
分页展示
最新推荐文章于 2023-07-11 10:54:00 发布