|
@@ -466,6 +466,7 @@ public class CommunityArticleController extends BaseController {
|
|
|
wrapper.ne("is_delete", 1).or().isNull("is_delete");
|
|
|
}));
|
|
|
|
|
|
+ //获取圈子的IDS
|
|
|
List<Long> circleIds = new ArrayList<>();
|
|
|
for (CommunityUserCircle communityUserCircle : communityUserCircles) {
|
|
|
circleIds.add(communityUserCircle.getCircleId());
|
|
@@ -476,6 +477,18 @@ public class CommunityArticleController extends BaseController {
|
|
|
.in("id", circleIds)
|
|
|
.like("circle_name", circleName));
|
|
|
}
|
|
|
+
|
|
|
+ for (CommunityCircle communityCircle : communityCircles) {
|
|
|
+ Long id = communityCircle.getId();
|
|
|
+ Long size = communityUserCircleMapper.selectCount(new QueryWrapper<CommunityUserCircle>()
|
|
|
+ .eq("circle_id", id)
|
|
|
+ .and((wrapper) -> {
|
|
|
+ wrapper.ne("is_delete", 1).or().isNull("is_delete");
|
|
|
+ }));
|
|
|
+ communityCircle.setHeat(size);
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
} catch (Exception e) {
|
|
|
throw new ProjectException();
|
|
|
}
|