diff --git a/blade-service-api/logpm-aftersales-api/src/main/java/com/logpm/aftersales/vo/AftersalesOvertimeFineVO.java b/blade-service-api/logpm-aftersales-api/src/main/java/com/logpm/aftersales/vo/AftersalesOvertimeFineVO.java index 79026ce33..a457b7399 100644 --- a/blade-service-api/logpm-aftersales-api/src/main/java/com/logpm/aftersales/vo/AftersalesOvertimeFineVO.java +++ b/blade-service-api/logpm-aftersales-api/src/main/java/com/logpm/aftersales/vo/AftersalesOvertimeFineVO.java @@ -37,6 +37,8 @@ public class AftersalesOvertimeFineVO extends AftersalesOvertimeFineEntity { private String workOrderNumber; //工单异常类型 private String workOrderType; + //异常工单ID + private Long workOrderId; //工单异常类型名称 private String workOrderTypeName; //发现节点 diff --git a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesOvertimeFineController.java b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesOvertimeFineController.java index dd9f556eb..9e1996c02 100644 --- a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesOvertimeFineController.java +++ b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesOvertimeFineController.java @@ -16,6 +16,7 @@ */ package com.logpm.aftersales.controller; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; @@ -24,6 +25,7 @@ import lombok.AllArgsConstructor; import javax.validation.Valid; import lombok.extern.slf4j.Slf4j; +import org.springblade.core.log.exception.ServiceException; import org.springblade.core.secure.BladeUser; import org.springblade.core.mp.support.Condition; import org.springblade.core.mp.support.Query; @@ -122,8 +124,18 @@ public class AftersalesOvertimeFineController extends BladeController { @ApiOperation(value = "修改", notes = "传入aftersalesOvertimeFine") public R update(@Valid @RequestBody AftersalesOvertimeFineEntity aftersalesOvertimeFine) { log.info("超时修改参数》》》》{}",aftersalesOvertimeFine); + if(ObjectUtils.isNull(aftersalesOvertimeFine.getId())){ + throw new ServiceException("超时记录ID不能为空!!!"); + } + try{ + return R.status(aftersalesOvertimeFineService.updateById(aftersalesOvertimeFine)); + }catch(ServiceException s){ + return R.fail(s.getMessage()); + } + catch(Exception e){ + return R.fail("系统异常!!!"); + } - return R.status(aftersalesOvertimeFineService.updateById(aftersalesOvertimeFine)); } /** diff --git a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesWorkOrderController.java b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesWorkOrderController.java index 30ac7da2e..dca22f61c 100644 --- a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesWorkOrderController.java +++ b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/controller/AftersalesWorkOrderController.java @@ -643,6 +643,7 @@ public class AftersalesWorkOrderController extends BladeController { BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse(); if(ObjectUtils.isNotNull(myCurrentWarehouse)){ aftersalesWorkOrder.setWarehouseId(myCurrentWarehouse.getId()); + } try { IPage list= aftersalesWorkOrderService.getPendingWorkOrder(aftersalesWorkOrder,Condition.getPage(query)); diff --git a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/mapper/AftersalesOvertimeFineMapper.xml b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/mapper/AftersalesOvertimeFineMapper.xml index 4b8213f6e..5a0923c24 100644 --- a/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/mapper/AftersalesOvertimeFineMapper.xml +++ b/blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/mapper/AftersalesOvertimeFineMapper.xml @@ -26,7 +26,7 @@