From 7519f0ab05159b6dfbcdf4a87f1e0da91725eb1e Mon Sep 17 00:00:00 2001 From: weizhiqiang <598748873@qq.com> Date: Thu, 5 Jan 2023 23:50:50 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E5=93=81=E9=87=87=E8=B4=AD=E6=95=B4?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../skyeye/attr/service/impl/AttrTransformServiceImpl.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/skyeye-promote/skyeye-common/src/main/java/com/skyeye/attr/service/impl/AttrTransformServiceImpl.java b/skyeye-promote/skyeye-common/src/main/java/com/skyeye/attr/service/impl/AttrTransformServiceImpl.java index 41714d33..15fd32c2 100644 --- a/skyeye-promote/skyeye-common/src/main/java/com/skyeye/attr/service/impl/AttrTransformServiceImpl.java +++ b/skyeye-promote/skyeye-common/src/main/java/com/skyeye/attr/service/impl/AttrTransformServiceImpl.java @@ -25,6 +25,7 @@ import com.skyeye.common.util.mybatisplus.MybatisPlusUtil; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.stream.Collectors; @@ -64,6 +65,9 @@ public class AttrTransformServiceImpl extends SkyeyeBusinessServiceImpl attrTransformList = list(queryWrapper); + if (CollectionUtil.isEmpty(attrTransformList)) { + return new ArrayList<>(); + } // 获取属性的基本信息 List attrKeyList = attrTransformList.stream().map(AttrTransform::getAttrKey).collect(Collectors.toList()); Map attrDefinitionMap = attrDefinitionService.queryAttrDefinitionMap(className, attrKeyList);