|
@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
import com.google.common.collect.Lists;
|
|
import com.google.common.collect.Lists;
|
|
|
import com.google.common.collect.Maps;
|
|
import com.google.common.collect.Maps;
|
|
|
import com.sckw.core.model.enums.AddressTypeEnum;
|
|
import com.sckw.core.model.enums.AddressTypeEnum;
|
|
|
|
|
+import com.sckw.core.utils.DateUtils;
|
|
|
import com.sckw.core.web.response.BaseIotResult;
|
|
import com.sckw.core.web.response.BaseIotResult;
|
|
|
import com.sckw.core.web.response.result.PageDataResult;
|
|
import com.sckw.core.web.response.result.PageDataResult;
|
|
|
import com.sckw.transport.api.feign.VehicleTraceClient;
|
|
import com.sckw.transport.api.feign.VehicleTraceClient;
|
|
@@ -61,6 +62,14 @@ public class VehicleExceptionService {
|
|
|
*/
|
|
*/
|
|
|
public PageDataResult<VehicleExceptionVo> queryExceptionList(VehicleExceptionQueryReq req) {
|
|
public PageDataResult<VehicleExceptionVo> queryExceptionList(VehicleExceptionQueryReq req) {
|
|
|
log.info("分页查询车辆异常信息,参数:{}", JSON.toJSONString( req));
|
|
log.info("分页查询车辆异常信息,参数:{}", JSON.toJSONString( req));
|
|
|
|
|
+ if (StringUtils.isBlank( req.getStartDate())){
|
|
|
|
|
+ String startDate = DateUtils.format(DateUtils.getStartOfDay(new Date()), DateUtils.DATE_TIME_PATTERN);
|
|
|
|
|
+ req.setStartDate(startDate);
|
|
|
|
|
+ }
|
|
|
|
|
+ if (StringUtils.isBlank( req.getEndDate())){
|
|
|
|
|
+ String endDate = DateUtils.format(DateUtils.getEndOfDay(new Date()), DateUtils.DATE_TIME_PATTERN);
|
|
|
|
|
+ req.setEndDate(endDate);
|
|
|
|
|
+ }
|
|
|
// 分页查询异常图片数据
|
|
// 分页查询异常图片数据
|
|
|
IPage<KwtVehicleException> page = exceptionImageRepository.queryExceptionImagePage(
|
|
IPage<KwtVehicleException> page = exceptionImageRepository.queryExceptionImagePage(
|
|
|
req.getEntId(),
|
|
req.getEntId(),
|
|
@@ -257,11 +266,21 @@ public class VehicleExceptionService {
|
|
|
*/
|
|
*/
|
|
|
public PageDataResult<VehicleExceptionVo> exceptionJkList(VehicleExceptionQueryReq req) {
|
|
public PageDataResult<VehicleExceptionVo> exceptionJkList(VehicleExceptionQueryReq req) {
|
|
|
log.info("分页查询车辆异常监控列表, req: {}", JSON.toJSONString( req));
|
|
log.info("分页查询车辆异常监控列表, req: {}", JSON.toJSONString( req));
|
|
|
|
|
+ if (StringUtils.isBlank( req.getStartDate())){
|
|
|
|
|
+ String startDate = DateUtils.format(DateUtils.getStartOfDay(new Date()), DateUtils.DATE_TIME_PATTERN);
|
|
|
|
|
+ req.setStartDate(startDate);
|
|
|
|
|
+ }
|
|
|
|
|
+ if (StringUtils.isBlank( req.getEndDate())){
|
|
|
|
|
+ String endDate = DateUtils.format(DateUtils.getEndOfDay(new Date()), DateUtils.DATE_TIME_PATTERN);
|
|
|
|
|
+ req.setEndDate(endDate);
|
|
|
|
|
+ }
|
|
|
// 分页查询异常图片数据
|
|
// 分页查询异常图片数据
|
|
|
IPage<KwtVehicleException> page = exceptionImageRepository.queryExceptionImagePage1(
|
|
IPage<KwtVehicleException> page = exceptionImageRepository.queryExceptionImagePage1(
|
|
|
req.getEntId(),
|
|
req.getEntId(),
|
|
|
req.getExceptionType(),
|
|
req.getExceptionType(),
|
|
|
req.getTruckNo(),
|
|
req.getTruckNo(),
|
|
|
|
|
+ req.getStartDate(),
|
|
|
|
|
+ req.getEndDate(),
|
|
|
req.getPageNum(),
|
|
req.getPageNum(),
|
|
|
req.getPageSize()
|
|
req.getPageSize()
|
|
|
);
|
|
);
|