|
@@ -629,7 +629,7 @@ public class OrderGoodsServiceImpl extends ServiceImpl<OrderGoodsMapper, OrderGo
|
|
|
if (nowTime < goods.getValidityStartTime() || nowTime > goods.getValidityEndTime()){
|
|
|
throw new CustomException("存在过期商品,请检查!");
|
|
|
}
|
|
|
- if (bo.getIsCart() == 1){
|
|
|
+ if (ObjectUtils.isNotNull(bo.getIsCart()) && bo.getIsCart() == 1){
|
|
|
//购物车校验
|
|
|
if(checkUnique(item,bo.getUserId())){
|
|
|
throw new CustomException("存在购物车已有商品,请检查!");
|