Browse Source

大屏居民信息接口提交

feature/screenDataPush
songyunpeng 4 years ago
parent
commit
3fb031b5c4
  1. 10
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/controller/PopulationInformationController.java
  2. 14
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/dao/PopulationInformationDao.java
  3. 32
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/service/PopulationInformationService.java
  4. 7
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/service/impl/PopulationInformationServiceImpl.java
  5. 37
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/resources/mapper/PopulationInformationDao.xml

10
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/controller/PopulationInformationController.java

@ -48,7 +48,7 @@ import java.util.*;
/**
* 人口信息表
* 人口信息表
*
* @author qu qu@elink-cn.com
* @since v1.0.0 2020-08-19
@ -56,7 +56,7 @@ import java.util.*;
@RestController
@RequestMapping("populationinformation")
public class PopulationInformationController {
@Autowired
private PopulationInformationService populationInformationService;
@ -202,6 +202,10 @@ public class PopulationInformationController {
public PopulationInfoOverviewDTO getPopulationInfoOverview() {
return populationInformationService.getPopulationInfoOverview();
}
@GetMapping("getPopulationInfoOverviewForScreen/{communityId}")
public PopulationInfoOverviewDTO getPopulationInfoOverviewForScreen(@PathVariable("communityId")String communityId) {
return populationInformationService.getPopulationInfoOverviewForScreen(communityId);
}
/**
* @Description 以城找人
@ -232,4 +236,4 @@ public class PopulationInformationController {
}
}
}

14
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/dao/PopulationInformationDao.java

@ -30,7 +30,7 @@ import java.util.List;
import java.util.Map;
/**
* 人口信息表
* 人口信息表
*
* @author qu qu@elink-cn.com
* @since v1.0.0 2020-08-19
@ -38,7 +38,7 @@ import java.util.Map;
@Mapper
public interface PopulationInformationDao extends BaseDao<PopulationInformationEntity> {
/**
* @Description 根据身份证信息获取人口信息
* @Description 根据身份证信息获取人口信息
* @Author songyunpeng
* @Date 2020/8/21
* @Param [residentsIdentityNo]
@ -86,6 +86,14 @@ public interface PopulationInformationDao extends BaseDao<PopulationInformationE
* @return com.elink.esua.epdc.dto.PopulationInfoOverviewDTO
**/
PopulationInfoOverviewDTO getPopulationInfoOverview();
/**
* @Description 获取居民信息采集总览数据 - 大屏
* @Author songyunpeng
* @Date 2020/8/27
* @Param []
* @return com.elink.esua.epdc.dto.PopulationInfoOverviewDTO
**/
PopulationInfoOverviewDTO getPopulationInfoOverviewForScreen(@Param("communityId")String communityId);
/**
* @Description 清空入党时间
* @Author songyunpeng
@ -197,4 +205,4 @@ public interface PopulationInformationDao extends BaseDao<PopulationInformationE
* @return java.util.List<com.elink.esua.epdc.dto.epdc.result.EpdcScreenResidentInfoByCurrentAddressResultDTO>
**/
List<EpdcScreenResidentInfoByCurrentAddressResultDTO> selectPeopleByCurrentAddressExportList(Map<String, Object> params);
}
}

32
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/service/PopulationInformationService.java

@ -30,7 +30,7 @@ import java.util.List;
import java.util.Map;
/**
* 人口信息表
* 人口信息表
*
* @author qu qu@elink-cn.com
* @since v1.0.0 2020-08-19
@ -97,7 +97,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
*/
void delete(String[] ids);
/**
* @Description 根据房屋ID获取户主信息
* @Description 根据房屋ID获取户主信息
* @Author songyunpeng
* @Date 2020/8/21
* @Param [id]
@ -121,7 +121,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
PageData<PopulationInformationDTO> listPage(Map<String, Object> params);
/**
* @Description 获取机动车列表信息
* @Description 获取机动车列表信息
* @Author songyunpeng
* @Date 2020/8/26
* @Param [params]
@ -138,7 +138,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
List<PopulationInformationDTO> motorVehicleList(Map<String, Object> params);
/**
* @Description 获取居民信息采集总览数据
* @Description 获取居民信息采集总览数据
* @Author songyunpeng
* @Date 2020/8/28
* @Param []
@ -146,7 +146,15 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
PopulationInfoOverviewDTO getPopulationInfoOverview();
/**
* @Description 清空入党时间
* @Description 获取居民信息采集总览
* @Author songyunpeng
* @Date 2021/6/23
* @Param [communityId]
* @return com.elink.esua.epdc.dto.PopulationInfoOverviewDTO
**/
PopulationInfoOverviewDTO getPopulationInfoOverviewForScreen(String communityId);
/**
* @Description 清空入党时间
* @Author songyunpeng
* @Date 2020/9/4
* @Param [id]
@ -154,7 +162,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
void setJionTimeToNull(String id);
/**
* @Description 清空失业登记时间
* @Description 清空失业登记时间
* @Author songyunpeng
* @Date 2020/9/4
* @Param [id]
@ -162,7 +170,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
void setUnemploymentRegisterTimeToNull(String id);
/**
* @Description 大屏找人接口
* @Description 大屏找人接口
* @Author songyunpeng
* @Date 2020/9/14
* @Param [epdcScreenSelectPeopleFormDTO]
@ -170,7 +178,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
PageData<EpdcScreenSelectPeopleResultDTO> selectPeople(EpdcScreenSelectPeopleFormDTO epdcScreenSelectPeopleFormDTO);
/**
* @Description 大屏找人详情接口
* @Description 大屏找人详情接口
* @Author songyunpeng
* @Date 2020/9/14
* @Param [dto]
@ -178,7 +186,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
Result<EpdcScreenSelectPeopleDetailResultDTO> selectPeopleDetail(EpdcScreenSelectPeopleDetailFormDTO dto);
/**
* @Description 房屋用途数据接口
* @Description 房屋用途数据接口
* @Author songyunpeng
* @Date 2020/9/15
* @Param []
@ -186,7 +194,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
Result<EpdcScreenHouseUseResultDTO> housingUse();
/**
* @Description 网格排名
* @Description 网格排名
* @Author songyunpeng
* @Date 2020/9/15
* @Param [dto]
@ -202,7 +210,7 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
**/
PageData<EpdcScreenHouseInfoByPeopleResultDTO> selectHouseByPeople(EpdcScreenHouseInfoByPeopleFormDTO dto);
/**
* @Description 以房找人接口
* @Description 以房找人接口
* @Author songyunpeng
* @Date 2020/9/19
* @Param [dto]
@ -243,4 +251,4 @@ public interface PopulationInformationService extends BaseService<PopulationInfo
* @return java.util.List<com.elink.esua.epdc.dto.epdc.result.EpdcScreenResidentInfoByCurrentAddressResultDTO>
**/
Integer selectCountPeopleByCurrentAddressForPc(Map<String, Object> params);
}
}

7
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/service/impl/PopulationInformationServiceImpl.java

@ -302,6 +302,11 @@ public class PopulationInformationServiceImpl extends BaseServiceImpl<Population
return baseDao.getPopulationInfoOverview();
}
@Override
public PopulationInfoOverviewDTO getPopulationInfoOverviewForScreen(String communityId) {
return baseDao.getPopulationInfoOverviewForScreen(communityId);
}
@Override
public void setJionTimeToNull(String id) {
baseDao.setJionTimeToNull(id);
@ -575,4 +580,4 @@ public class PopulationInformationServiceImpl extends BaseServiceImpl<Population
break;
}
}
}
}

37
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/resources/mapper/PopulationInformationDao.xml

@ -175,6 +175,41 @@
from epdc_population_information where DEL_FLAG = 0 and RESIDENTS_IDENTITY_NO is not null and RESIDENTS_IDENTITY_NO != '')a on 1=1
where t.DEL_FLAG ='0';
</select>
<select id="getPopulationInfoOverviewForScreen" resultType="com.elink.esua.epdc.dto.PopulationInfoOverviewDTO">
select count(EMPLOYMENT_STATUS = '0' or null) as employment,
count(EMPLOYMENT_STATUS = '1' or null) as unemployment,
(select count(a.ID)
+
(select a.residentNum
from (
SELECT hi.PARENT_DEPT_IDS,
SUM(t2.num1) as residentNum
FROM `epdc_housing_information` hi
LEFT JOIN(
SELECT hr1.`HOUSE_ID`, SUM(t.num) as num1
FROM `epdc_house_resident` hr1
LEFT JOIN(
SELECT hr.`HOUSE_HEAD_ID`, COUNT(hr.`ID`) AS num
FROM `epdc_house_resident` hr
WHERE hr.`DEL_FLAG` = '0'
AND `IS_HOUSE_HEAD` = '0'
GROUP BY hr.`HOUSE_HEAD_ID`
ORDER BY COUNT(hr.`ID`) DESC) t on t.HOUSE_HEAD_ID = hr1.`RESIDENT_ID`
WHERE hr1.`DEL_FLAG` = '0'
AND hr1.`IS_HOUSE_HEAD` = '1'
GROUP BY hr1.`HOUSE_ID`) t2 on t2.HOUSE_ID = hi.`ID`
AND hi.`DEL_FLAG` = '0'
GROUP BY hi.`PARENT_DEPT_NAMES`) a
where find_in_set(#{communityId}, a.PARENT_DEPT_IDS))) as populationNum,
sum(MOTOR_VEHICLE_NUM) as motorVehicleNum,
count(POLITICS_STATUS = '1' or null) as partyMemberNum
from epdc_population_information a
left join epdc_house_resident b on a.ID = b.RESIDENT_ID and b.DEL_FLAG = '0'
left join epdc_housing_information c on c.ID = b.HOUSE_ID
where a.DEL_FLAG = 0
and b.IS_HOUSE_HEAD = 1
and find_in_set(#{communityId}, c.PARENT_DEPT_IDS)
</select>
<select id="selectListPeople"
resultType="com.elink.esua.epdc.dto.epdc.result.EpdcScreenSelectPeopleResultDTO">
select data.name,data.gridName,data.identityFlag,data.houseId,data.populationId,data.identity,data.CREATED_TIME,data.identity as identityName from (
@ -552,4 +587,4 @@
</select>
</mapper>
</mapper>

Loading…
Cancel
Save