liujunchi преди 3 години
родител
ревизия
92bbaf79fe
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      cooleshow-mall/mall-portal/src/main/java/com/yonge/cooleshow/portal/service/impl/OmsCartItemServiceImpl.java

+ 1 - 1
cooleshow-mall/mall-portal/src/main/java/com/yonge/cooleshow/portal/service/impl/OmsCartItemServiceImpl.java

@@ -91,7 +91,7 @@ public class OmsCartItemServiceImpl implements OmsCartItemService {
                 throw new BizException("库存不足");
             }
             cartItem.setModifyDate(new Date());
-            existCartItem.setQuantity(existCartItem.getQuantity() + cartItem.getQuantity());
+            existCartItem.setQuantity(cartItem.getQuantity());
             cartItemMapper.updateByPrimaryKey(existCartItem);
         }
         return existCartItem;