|
@@ -54,4 +54,15 @@ public class EnvWarningInfoServiceImpl extends ServiceImpl<EnvWarningInfoMapper,
|
|
List<EnvWarningDto> envWarningDtoList = envWarningInfoMapper.listTop(farmId);
|
|
List<EnvWarningDto> envWarningDtoList = envWarningInfoMapper.listTop(farmId);
|
|
return new Result(ResultCode.SUCCESS,envWarningDtoList);
|
|
return new Result(ResultCode.SUCCESS,envWarningDtoList);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public Result listScreen(HttpServletRequest httpServletRequest, Map<String, String> paramsMap) {
|
|
|
|
+ String farmId = paramsMap.get("farmId");
|
|
|
|
+ QueryWrapper<EnvWarningInfo> wrapper = new QueryWrapper<>();
|
|
|
|
+ wrapper.eq("farm_id",farmId);
|
|
|
|
+ wrapper.orderByDesc("id");
|
|
|
|
+ wrapper.isNotNull("unit_id");
|
|
|
|
+ wrapper.last("limit 5");
|
|
|
|
+ return new Result(ResultCode.SUCCESS, this.list(wrapper));
|
|
|
|
+ }
|
|
}
|
|
}
|