feat(订单): 为模式3订单添加格口名称显示和退货通知优化

在订单模式3下,商品名称现在显示为"柜子名称+格口号"
退货审核通知根据订单模式区分显示"退还格口"或"退还商品"
This commit is contained in:
dzq 2025-12-15 10:08:55 +08:00
parent 7b6a2246a4
commit bb9b35fb7a
2 changed files with 7 additions and 1 deletions

View File

@ -861,7 +861,11 @@ public class ReturnApprovalApplicationService {
List<NewsArticle> articles = new ArrayList<>(); List<NewsArticle> articles = new ArrayList<>();
NewsArticle article = new NewsArticle(); NewsArticle article = new NewsArticle();
article.setTitle("退货审核通知"); article.setTitle("退货审核通知");
if (orderGoods.getMode() != null && orderGoods.getMode().equals(3)) {
article.setDescription("退还格口:" + orderGoods.getGoodsName());
} else {
article.setDescription("退还商品:" + orderGoods.getGoodsName()); article.setDescription("退还商品:" + orderGoods.getGoodsName());
}
article.setPicurl(orderGoods.getCoverImg()); article.setPicurl(orderGoods.getCoverImg());
String serverHost = CacheCenter.configCache.get(ConfigKeyEnum.SERVER_HOST.getValue()); String serverHost = CacheCenter.configCache.get(ConfigKeyEnum.SERVER_HOST.getValue());
article.setUrl(serverHost + UrlConstants.WECHAT_AUTH_URL + "?corpid=" + command.getCorpid()); article.setUrl(serverHost + UrlConstants.WECHAT_AUTH_URL + "?corpid=" + command.getCorpid());

View File

@ -403,10 +403,12 @@ public class OrderApplicationService {
goodsModel.setDeleted(false); goodsModel.setDeleted(false);
CabinetCellEntity cabinetCellEntity = cabinetCellService.getById(goodsModel.getCellId()); CabinetCellEntity cabinetCellEntity = cabinetCellService.getById(goodsModel.getCellId());
SmartCabinetEntity cabinetEntity = smartCabinetService.getById(cabinetCellEntity.getCabinetId());
if (orderModel.getMode() != null && orderModel.getMode().equals(3)) { if (orderModel.getMode() != null && orderModel.getMode().equals(3)) {
goodsModel.setPrice(cabinetCellEntity.getCellPrice()); goodsModel.setPrice(cabinetCellEntity.getCellPrice());
goodsModel.setTotalAmount(cabinetCellEntity.getCellPrice()); goodsModel.setTotalAmount(cabinetCellEntity.getCellPrice());
goodsModel.setGoodsName(cabinetEntity.getCabinetName() + "格口" + cabinetCellEntity.getCellNo());
} else { } else {
// 计算商品金额并验证库存 // 计算商品金额并验证库存
goodsModel.calculateTotal(); goodsModel.calculateTotal();