From 64568846bb4fb27f3a31f3bb37f84b57a9457784 Mon Sep 17 00:00:00 2001
From: yanghui <2536613402@qq.com>
Date: 星期一, 05 十二月 2022 10:17:53 +0800
Subject: [PATCH] #feat 修复bug
---
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActSocialProjectPublicityServiceImpl.java | 17 +++++++++++++++++
1 files changed, 17 insertions(+), 0 deletions(-)
diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActSocialProjectPublicityServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActSocialProjectPublicityServiceImpl.java
index b944b4f..bb6d38a 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActSocialProjectPublicityServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActSocialProjectPublicityServiceImpl.java
@@ -4,13 +4,17 @@
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.panzhihua.common.model.dtos.property.CommonPage;
import com.panzhihua.common.model.vos.R;
+import com.panzhihua.service_community.dao.ComActDAO;
import com.panzhihua.service_community.entity.ComActSocialProjectPublicity;
import com.panzhihua.service_community.dao.ComActSocialProjectPublicityDao;
+import com.panzhihua.service_community.model.dos.ComActDO;
import com.panzhihua.service_community.service.ComActSocialProjectPublicityService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
+
+import static java.util.Objects.nonNull;
/**
* 项目宣传表(ComActSocialProjectPublicity)表服务实现类
@@ -24,8 +28,21 @@
@Resource
private ComActSocialProjectPublicityDao comActSocialProjectPublicityDao;
+ @Resource
+ private ComActDAO comActDAO;
@Override
public R pageList(CommonPage commonPage) {
+ if (nonNull(commonPage.getCommunityId())) {
+ ComActDO comActDO = comActDAO.selectById(commonPage.getCommunityId());
+ if (nonNull(comActDO)) {
+ commonPage.setStreetId(comActDO.getStreetId());
+ }
+ }
return R.ok(comActSocialProjectPublicityDao.pageList(new Page(commonPage.getPage(),commonPage.getSize()),commonPage));
}
+
+ @Override
+ public R selectOne(Long id) {
+ return R.ok(comActSocialProjectPublicityDao.selectOne(id));
+ }
}
--
Gitblit v1.7.1