소스 검색

Merge branch 'sit' into uat

# Conflicts:
#	alien-entity/src/main/java/shop/alien/entity/store/vo/AiApproveStoreInfo.java
yindp 2 주 전
부모
커밋
9341e439a5

+ 34 - 0
alien-entity/src/main/java/shop/alien/entity/store/vo/AiApproveStoreInfo.java

@@ -0,0 +1,34 @@
+package shop.alien.entity.store.vo;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.util.List;
+
+/**
+ * 店铺审核 - AI 服务请求体
+ */
+@Data
+public class AiApproveStoreInfo {
+
+    @ApiModelProperty(value = "用户id")
+    private String userId;
+
+    @ApiModelProperty(value = "商户名称(公司/门店名称)")
+    private String merchant_name;
+
+    @ApiModelProperty(value = "经营范围 / 业务描述")
+    private String business_scope;
+
+    @ApiModelProperty(value = "联系人姓名")
+    private String contact_name;
+
+    @ApiModelProperty(value = "联系人手机号")
+    private String contact_phone;
+
+    @ApiModelProperty(value = "联系人邮箱")
+    private String contact_email;
+
+    @ApiModelProperty(value = "证照/资质门头照片列表")
+    private List<String> license_images;
+}

+ 7 - 1
alien-store/src/main/java/shop/alien/store/service/impl/StoreInfoServiceImpl.java

@@ -4107,7 +4107,13 @@ public class StoreInfoServiceImpl extends ServiceImpl<StoreInfoMapper, StoreInfo
 
         // 注意:需要将store_id转换为String类型,与后续containsKey判断保持一致
         avgScoreMap = storeEvaluationMapper.allStoreAvgScore().stream().collect(Collectors.groupingBy(o -> o.get("store_id").toString()));
-        commentMap = storeCommentMapper.selectList(new QueryWrapper<StoreComment>().eq("business_type", "5").eq("delete_flag", 0)).stream().collect(Collectors.groupingBy(StoreComment::getStoreId));
+        List<StoreComment> storeComments = storeCommentMapper.selectList(
+                new QueryWrapper<StoreComment>()
+                        .eq("business_type", "5")
+                        .eq("delete_flag", 0));
+        commentMap = storeComments.stream()
+                .filter(comment -> comment.getStoreId() != null) // 过滤无店铺ID的评论,避免 groupingBy NPE
+                .collect(Collectors.groupingBy(StoreComment::getStoreId));
 
 
         // 查询入口头图