From f5743e0a3dbef68cc2f095519f118a9ab2817777 Mon Sep 17 00:00:00 2001
From: yanghui <2536613402@qq.com>
Date: 星期二, 29 十一月 2022 11:13:17 +0800
Subject: [PATCH] Merge branch 'local_20221104' into huacheng_test
---
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActNeighborCircleServiceImpl.java | 24 ++++++++++++++++++------
1 files changed, 18 insertions(+), 6 deletions(-)
diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActNeighborCircleServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActNeighborCircleServiceImpl.java
index 003f0db..59c943d 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActNeighborCircleServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActNeighborCircleServiceImpl.java
@@ -1,5 +1,7 @@
package com.panzhihua.service_community.service.impl;
+import cn.hutool.core.collection.ListUtil;
+import cn.hutool.core.util.PageUtil;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.collection.ListUtil;
import cn.hutool.core.util.PageUtil;
@@ -99,6 +101,15 @@
// }
// }
// }
+ Long communityId = neighborCircleAppDTO.getCommunityId();
+ if(null != communityId){
+ List<Long> communityIds = comActDAO.selectIds(communityId);
+ if (CollUtil.isEmpty(communityIds)) {
+ communityIds = new ArrayList<>();
+ communityIds.add(communityId);
+ }
+ neighborCircleAppDTO.setCommunityIds(communityIds);
+ }
Page userPage = new Page(neighborCircleAppDTO.getPageNum(), neighborCircleAppDTO.getPageSize());
IPage<ComActNeighborCircleAppVO> doPager = this.baseMapper.pageNeighborByApp(userPage, neighborCircleAppDTO);
if (!doPager.getRecords().isEmpty()) {
@@ -334,13 +345,14 @@
@Override
public R pageNeighborByAdmin(ComActNeighborCircleAdminDTO neighborCircleAdminDTO) {
Long communityId = neighborCircleAdminDTO.getCommunityId();
- List<Long> communityIds = comActDAO.selectIds(communityId);
- if (CollUtil.isEmpty(communityIds)) {
- communityIds = new ArrayList<>();
- communityIds.add(communityId);
+ if(null != communityId){
+ List<Long> communityIds = comActDAO.selectIds(communityId);
+ if (CollUtil.isEmpty(communityIds)) {
+ communityIds = new ArrayList<>();
+ communityIds.add(communityId);
+ }
+ neighborCircleAdminDTO.setCommunityIds(communityIds);
}
- neighborCircleAdminDTO.setCommunityIds(communityIds);
-
Page page = new Page(neighborCircleAdminDTO.getPageNum(), neighborCircleAdminDTO.getPageSize());
IPage<ComActNeighborCircleAdminVO> doPager = this.baseMapper.pageNeighborByAdmin(page, neighborCircleAdminDTO);
doPager.getRecords().forEach(data -> {
--
Gitblit v1.7.1