From 205bfcfe6d20948222a66fffccb595c78ccec7f3 Mon Sep 17 00:00:00 2001 From: "liang.chao" <1360241448@qq.com> Date: Mon, 2 Dec 2024 15:33:38 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E7=A4=BA=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../bonus/material/order/service/impl/OrderServiceImpl.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bonus-modules/bonus-material-mall/src/main/java/com/bonus/material/order/service/impl/OrderServiceImpl.java b/bonus-modules/bonus-material-mall/src/main/java/com/bonus/material/order/service/impl/OrderServiceImpl.java index d18da54..b7a08d7 100644 --- a/bonus-modules/bonus-material-mall/src/main/java/com/bonus/material/order/service/impl/OrderServiceImpl.java +++ b/bonus-modules/bonus-material-mall/src/main/java/com/bonus/material/order/service/impl/OrderServiceImpl.java @@ -38,9 +38,9 @@ public class OrderServiceImpl implements OrderService { // 查询库存是否为0,是的话让它下架 orderDetailDto.setMaStatus("1"); orderMapper.updateDeviceStatus(orderDetailDto); - throw new RuntimeException(devInfo.getDeviceName() + "库存不足"); + throw new RuntimeException(devInfo.getDeviceName() + "已下架,无法下单"); }else if (devInfo.getDeviceCount() < orderDetailDto.getNum()) { - throw new RuntimeException(devInfo.getDeviceName() + "库存不足"); + throw new RuntimeException(devInfo.getDeviceName() + "库存不足,无法下单"); } else { // 改库存 orderMapper.updateDevCount(orderDetailDto);