Browse Source

Merge remote-tracking branch 'origin/dev' into dev

visual
zhaoqiaobo 3 months ago
parent
commit
8976c81ddc
  1. 12
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataDriverArteryController.java
  2. 15
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataDriverArteryServiceImpl.java
  3. 4
      blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/controller/FactoryCommonController.java
  4. 2
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.java
  5. 7
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.xml
  6. 4
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceService.java
  7. 2
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java
  8. 4
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java

12
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataDriverArteryController.java

@ -38,6 +38,7 @@ import io.swagger.annotations.ApiParam;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.jetbrains.annotations.NotNull;
import org.springblade.common.exception.CustomerException;
import org.springblade.core.boot.ctrl.BladeController;
import org.springblade.core.excel.util.ExcelUtil;
import org.springblade.core.log.exception.ServiceException;
@ -292,9 +293,14 @@ public class BasicdataDriverArteryController extends BladeController {
@ApiOperation(value = "导入司机信息", notes = "传入excel")
public R importDriverArteryEntry(MultipartFile file) {
log.info("传入>>>>>>>{}", file);
BasicdataDriverArteryImporter basicdataDriverArteryImporter = new BasicdataDriverArteryImporter(basicdataDriverArteryService);
ExcelUtil.save(file, basicdataDriverArteryImporter, BasicdataDriverArteryImproterExcel.class);
return R.success("操作成功");
try {
BasicdataDriverArteryImporter basicdataDriverArteryImporter = new BasicdataDriverArteryImporter(basicdataDriverArteryService);
ExcelUtil.save(file, basicdataDriverArteryImporter, BasicdataDriverArteryImproterExcel.class);
return R.success("操作成功");
} catch (CustomerException e) {
log.error("导入失败", e);
return R.fail(e.getMessage());
}
}
/**

15
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataDriverArteryServiceImpl.java

@ -44,6 +44,7 @@ import org.springblade.common.constant.driver.DriverApprovedDrivingModelConstant
import org.springblade.common.constant.driver.DriverBankTypeConverter;
import org.springblade.common.constant.driver.DriverPositionTypeConstant;
import org.springblade.common.constant.driver.DriverTypeStatusConstant;
import org.springblade.common.exception.CustomerException;
import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springblade.core.secure.BladeUser;
@ -268,7 +269,7 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
// log.error("必填数据不能为空");
// continue;
throw new ServiceException("必填数据不能为空!");
throw new CustomerException("必填数据不能为空!");
}
if (!ObjectUtils.isEmpty(datum.getPhone())) {
String phone = datum.getPhone();
@ -281,7 +282,7 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
if (userR.getData() == null) {
// log.error("未找到用户");
// continue;
throw new ServiceException("未找到用户!");
throw new CustomerException("未找到用户!");
} else {
datum.setUserId(userR.getData().getId());
}
@ -293,7 +294,7 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
if (carListByName.isEmpty()) {
// log.error("未找到可绑定的车辆");
throw new ServiceException("未找到可绑定的车辆!");
throw new CustomerException("未找到可绑定的车辆!");
} else {
BasicdataDrivermiddleEntity basicdataDrivermiddleEntity = new BasicdataDrivermiddleEntity();
basicdataDrivermiddleEntity.setBrandId(carListByName.get(0).getId());
@ -308,7 +309,7 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
if (ObjectUtils.isEmpty(basicdataCarrierEntities)) {
// log.error("未找到承运商");
// continue;
throw new ServiceException("未找到承运商!");
throw new CustomerException("未找到承运商!");
} else {
datum.setCarrierId(basicdataCarrierEntities.get(0).getId());
}
@ -375,11 +376,11 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
basicdataDrivermiddleServiceImpl.save(basicdataDrivermiddleEntity);
}
} catch (DataAccessException e) {
throw new ServiceException("用户" + datum.getName() + "数据长度异常");
throw new CustomerException("用户" + datum.getName() + "数据长度异常");
} catch (ServiceException e) {
throw new ServiceException("用户" + datum.getName() + e.getMessage());
throw new CustomerException("用户" + datum.getName() + e.getMessage());
} catch (Exception e) {
throw new RuntimeException("用户" + datum.getName() + "数据错误" + e.getMessage());
throw new CustomerException("用户" + datum.getName() + "数据错误" + e.getMessage());
}
}

4
blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/controller/FactoryCommonController.java

@ -107,12 +107,12 @@ public class FactoryCommonController {
// 将消息携带绑定键值
rabbitTemplate.convertAndSend(RabbitConstant.ORDER_STATUS_EXCHANGE, RabbitConstant.ORDER_STATUS_ROUTING, map);
map.put("type", "DealWith");
if (StringUtil.equals(sendDataProperties.getPush(), "old")) {
// if (StringUtil.equals(sendDataProperties.getSend(), "old")) {
rabbitTemplate.convertAndSend(RabbitConstant.DEAL_WITH_EXCHANGE, RabbitConstant.DEAL_WITH_ROUTING, map, message -> {
message.getMessageProperties().setHeader("x-delay", 2000);
return message;
});
}
// }
// R r = factoryDataService.handleStatusData(orderStatusDTO);
return R.success("调用成功");

2
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.java

@ -46,7 +46,7 @@ public interface TrunklineAdvanceMapper extends BaseMapper<TrunklineAdvanceEntit
void deleteByWaybillNo(@Param("waybillNo") String waybillNo);
void clearWaybillInfoByWaybillId(@Param("waybillId") Long waybillId);
void clearWaybillInfoByWaybillNo(@Param("waybillNo") String waybillNo);
IPage<TrunklineAdvanceVO> advancePageListByBussiness(IPage<Object> page, @Param("param") AdvanceDTO advanceDTO);

7
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineAdvanceMapper.xml

@ -254,12 +254,11 @@
</select>
<update id="clearWaybillInfoByWaybillId">
<update id="clearWaybillInfoByWaybillNo">
update logpm_trunkline_advance
set waybill_id = null,
waybill_no = null,
set waybill_no = null,
waybill_status = '0'
where waybill_id = #{waybillId}
where waybill_no = #{waybillNo}
</update>
</mapper>

4
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineAdvanceService.java

@ -48,7 +48,7 @@ public interface ITrunklineAdvanceService extends BaseService<TrunklineAdvanceEn
void deleteByWaybillNo(String waybillNo);
void clearWaybillInfoByWaybillId(Long waybillId);
IPage<TrunklineAdvanceVO> advancePageListByBussiness(IPage<Object> page, AdvanceDTO advanceDTO);
void clearWaybillInfoByWaybillNo(String waybillNo);
}

2
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java

@ -3981,7 +3981,7 @@ public class OpenOrderServiceImpl implements IOpenOrderService {
Integer waybillType = waybillEntity.getWaybillType();
if(waybillType.equals(1)){
//订制品
advanceService.clearWaybillInfoByWaybillId(waybillId);
advanceService.clearWaybillInfoByWaybillNo(waybillNo);
advanceDetailService.clearWaybillInfoByWaybillId(waybillId);
trunklineWaybillOrderService.deleteByWaybillNo(waybillNo);

4
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java

@ -1926,7 +1926,7 @@ public class TrunklineAdvanceServiceImpl extends BaseServiceImpl<TrunklineAdvanc
}
@Override
public void clearWaybillInfoByWaybillId(Long waybillId) {
baseMapper.clearWaybillInfoByWaybillId(waybillId);
public void clearWaybillInfoByWaybillNo(String waybillNo) {
baseMapper.clearWaybillInfoByWaybillNo(waybillNo);
}
}

Loading…
Cancel
Save