From edf2bc6f41c9784e9cdccc9b569a7091a5a5a438 Mon Sep 17 00:00:00 2001 From: lidongdong <1459917685@qq.com> Date: 星期五, 23 九月 2022 16:10:07 +0800 Subject: [PATCH] Merge branch 'zigonggao_dev' of http://gitlab.nhys.cdnhxx.com/root/zhihuishequ into huacheng_test --- springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/CommunityApi.java | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/CommunityApi.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/CommunityApi.java index ac9462a..066bcf7 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/CommunityApi.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/CommunityApi.java @@ -18,6 +18,7 @@ import com.panzhihua.service_community.dao.ComActActEvaluateDAO; import com.panzhihua.service_community.model.dos.*; import com.panzhihua.service_community.service.*; +import org.springframework.amqp.rabbit.core.RabbitTemplate; import org.springframework.beans.BeanUtils; import org.springframework.transaction.annotation.Transactional; import org.springframework.util.ObjectUtils; @@ -151,6 +152,8 @@ private ComActActEvaluateDAO comActActEvaluateDAO; @Resource private ComActActivityInviteService comActActivityInviteService; + @Resource + private RabbitTemplate rabbitTemplate; /** * 新增社区活动 @@ -634,6 +637,10 @@ BeanUtils.copyProperties(comActDynVO, comActDynDO); boolean save = comActDynService.save(comActDynDO); if (save) { + if(comActDynVO.getCategory()!=null&&comActDynVO.getCategory()==4){ + comActDynVO.setId(comActDynDO.getId()); + rabbitTemplate.convertAndSend("huacheng.acid.message.exchange", "huacheng.acid.message.key", comActDynVO); + } // 最多只能设置三条置顶状态,后边设置会取消先前设置的置顶 Integer isTopping = comActDynVO.getIsTopping(); boolean b = isTopping.intValue() == 1; @@ -2334,7 +2341,7 @@ * @return 社区列表 */ @GetMapping("/eventgrid/community/westList") - public R getWestCommunityLists(@RequestParam("areaCode")String areaCode) { + public R getWestCommunityLists(@RequestParam(value = "areaCode",required = false)String areaCode) { return comActService.getWestCommunityLists(areaCode); } -- Gitblit v1.7.1