소스 검색

no message

FengChaoYu 2 주 전
부모
커밋
22b31953bc
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      mall-server-api/src/main/java/com/gree/mall/manager/logic/goods/GoodsLogic.java

+ 1 - 1
mall-server-api/src/main/java/com/gree/mall/manager/logic/goods/GoodsLogic.java

@@ -210,7 +210,7 @@ public class GoodsLogic {
      */
     public GoodsSpecBean detail(String goodsId, Boolean allStorageSpec) throws RemoteServiceException {
         Goods goods = goodsService.getById(goodsId);
-        final GoodsDetail goodsDetail = goodsDetailService.getById(goodsId);
+        final GoodsDetail goodsDetail = !allStorageSpec ? goodsDetailService.getById(goodsId) : null;
         List<GoodsSpec> goodsSpecs = goodsSpecService.lambdaQuery()
                 .eq(GoodsSpec::getGoodsId, goodsId)
                 .eq(GoodsSpec::getDel, false)