From 66e6e417d69c5ccebc61082519e4e65eff81b490 Mon Sep 17 00:00:00 2001
From: huanghongfa <huanghongfa123456>
Date: 星期二, 27 四月 2021 13:32:03 +0800
Subject: [PATCH] 社区后台实有人口详情增加家庭成员信息以及电子档信息

---
 springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java |   23 ++++++++++++++++++++++-
 1 files changed, 22 insertions(+), 1 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
index afb2618..5df49bf 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
@@ -127,7 +127,7 @@
     public R detailPopulation(Long populationId) {
         ComMngPopulationDO comMngPopulationDO = populationDAO.selectById(populationId);
         if (ObjectUtils.isEmpty(comMngPopulationDO)) {
-            return R.fail();
+            return R.fail("用户信息不存在");
         }
         ComMngPopulationVO comMngPopulationVO = new ComMngPopulationVO();
         BeanUtils.copyProperties(comMngPopulationDO, comMngPopulationVO);
@@ -469,4 +469,25 @@
             return R.fail();
         }
     }
+
+    /**
+     * 查询实有人口电子档信息
+     * @param populationId  实有人口id
+     * @return  实有人口电子档信息
+     */
+    @Override
+    public R electronicArchivesPopulation(Long populationId){
+        ComMngPopulationDO comMngPopulationDO = populationDAO.selectById(populationId);
+        if (ObjectUtils.isEmpty(comMngPopulationDO)) {
+            return R.fail("用户信息不存在");
+        }
+        //查询当前用户电子档信息
+        if(!StringUtils.isEmpty(comMngPopulationDO.getCardNo())){
+            UserElectronicFileVO electronicFileVO = populationDAO.getSysUserElectronicFile(comMngPopulationDO.getCardNo());
+            if(electronicFileVO != null){
+                return R.ok(electronicFileVO);
+            }
+        }
+        return R.ok();
+    }
 }

--
Gitblit v1.7.1