|
@@ -253,4 +253,29 @@ public class EnvRegularCallFeedingServiceImpl extends ServiceImpl<EnvRegularCall
|
|
|
return new Result(ResultCode.SUCCESS, feedingMapper.listAll(page, queryWrapper));
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public Result listByChiNum(HttpServletRequest httpServletRequest, Map<String, String> paramsMap) {
|
|
|
+ String farmId = paramsMap.get("farmId");
|
|
|
+ String chiNum = paramsMap.get("chiNum");
|
|
|
+ String pageNum = paramsMap.get("pageNum");
|
|
|
+ String pageSize = paramsMap.get("pageSize");
|
|
|
+ if (pageNum == null || "".equals(pageNum)) {
|
|
|
+ pageNum = "1";
|
|
|
+ }
|
|
|
+ if (pageSize == null || "".equals(pageSize)) {
|
|
|
+ pageSize = "10";
|
|
|
+ }
|
|
|
+ Date timesMonthmorning = DataUill.getTimesmorning();
|
|
|
+ Page<EnvRegularCallFeeding> page = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize));
|
|
|
+ IPage<EnvRegularCallFeeding> regularCallFeedingIPage = feedingMapper.listSelect2(page, timesMonthmorning, farmId, chiNum);
|
|
|
+ List<EnvRegularCallFeeding> records = regularCallFeedingIPage.getRecords();
|
|
|
+ for (int i = 0; i < records.size(); i++) {
|
|
|
+ if ("".equals(records.get(i).getCallCode()) || null == records.get(i).getCallCode()) {
|
|
|
+ records.remove(i);
|
|
|
+ regularCallFeedingIPage.setTotal(regularCallFeedingIPage.getTotal()-1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return new Result(ResultCode.SUCCESS, regularCallFeedingIPage);
|
|
|
+ }
|
|
|
+
|
|
|
}
|