Commit 397140c3 authored by honghy's avatar honghy Committed by wux

英文、法语版的空运订单入仓异常通知

parent fcee34fc
......@@ -9,7 +9,6 @@ import cn.hutool.core.util.StrUtil;
import cn.iocoder.yudao.framework.apollo.core.event.Order.OrderApprovalTypeCheckEvent;
import cn.iocoder.yudao.framework.apollo.core.event.QueryChannelInfoEvent;
import cn.iocoder.yudao.framework.apollo.core.event.box.BoxCheckOrderSchedulingEvent;
import cn.iocoder.yudao.framework.apollo.core.event.box.BoxOrderRevokeWarehouseCheckEvent;
import cn.iocoder.yudao.framework.apollo.core.event.box.BoxOrderShipmentWarehouseInEvent;
import cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
......@@ -1398,6 +1397,8 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
.last("limit 1"));
orderDO = orderService.getById(orderId);
String exceptionContent = null;
String exceptionContentEn = null;
String exceptionContentFr = null;
if (exceptionNum == 0) {
Date appendInTime = new Date();
if (CollectionUtil.isNotEmpty(orderWarehouseInDOList)) {
......@@ -1410,9 +1411,11 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
warehouseInSendSms(orderDO, finishReqVO.getIsAppend(), appendInTime);
} else {
exceptionContent = orderUnProcessExceptionList.stream().map(ex -> OrderExceptionEnum.getEnumByKey(ex.getOrderExceptionType()).getZhValueDesc()).collect(Collectors.joining(StrUtil.COMMA));
exceptionContentEn = orderUnProcessExceptionList.stream().map(ex -> OrderExceptionEnum.getEnumByKey(ex.getOrderExceptionType()).getEnValueDesc()).collect(Collectors.joining(StrUtil.COMMA));
exceptionContentFr = orderUnProcessExceptionList.stream().map(ex -> OrderExceptionEnum.getEnumByKey(ex.getOrderExceptionType()).getFrValueDesc()).collect(Collectors.joining(StrUtil.COMMA));
}
// 发送站内信
warehouseInSendInternalMessage(finishReqVO, orderDO, orderConsignorDO2, exceptionContent);
warehouseInSendInternalMessage(finishReqVO, orderDO, orderConsignorDO2, exceptionContent, exceptionContentEn, exceptionContentFr);
}
// 完成入仓后更新客户状态(拆单子订单不需要更新)
......@@ -2624,7 +2627,8 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
// smsSendApi.sendSingleSmsToAdminV2(reqDTO);
// }
private void warehouseInSendInternalMessage(OrderWarehouseInFinishReqVO finishReqVO, OrderDO orderDO, OrderConsignorDO orderConsignorDO, String exceptionContent) {
private void warehouseInSendInternalMessage(OrderWarehouseInFinishReqVO finishReqVO, OrderDO orderDO, OrderConsignorDO orderConsignorDO, String exceptionContent
, String exceptionContentEn, String exceptionContentFr) {
if (orderDO.getHasSendWarehouseInNotice()) {
log.info("warehouseInSendNotice入仓已发送过,不需要再次发送通知, orderId={}, orderNo={}", orderDO.getOrderId(), orderDO.getOrderNo());
return;
......@@ -2713,9 +2717,9 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
content = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.ZH.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
contentEn = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.EN.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContentEn);
contentFr = String.format(I18nMessage.getMessage("app.message.air.exception.warehousein.content", LangEnum.FR.getLang()),
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContent);
orderDO.getOrderNo(), orderDO.getMarks(), exceptionContentFr);
} else {
// 空运无异常入仓
title = String.format(I18nMessage.getMessage("app.message.air.warehousein.title"), orderDO.getOrderNo(), LangEnum.ZH.getLang());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment