Commit 6f2057cd by wqc

修改社会残疾统计sql

parent 4145e704
......@@ -39,7 +39,7 @@ public interface CjStatsDao {
List<StatsVo> getYearSevereDisabledStats(StatsReqVo vo);
/**
* 获取区域下的残疾人统计
* 获取区域下的重度残疾人统计
*
* @param vo
* @return
......@@ -47,6 +47,14 @@ public interface CjStatsDao {
StatsVo getSeverePeopleNumStats(StatsReqVo vo);
/**
* 获取区域下的困难残疾人统计
*
* @param vo
* @return
*/
StatsVo getDifficultPeopleNumStats(StatsReqVo vo);
/**
* 获取区域发放统计
*
* @return
......
......@@ -236,6 +236,7 @@ public class CjStatsService {
data.put("areaName", area.getName());
data.put("areaCode",severeAreaIssueStat.getCode());
data.put("severePeopleNum", cjStatsDao.getSeverePeopleNumStats(vo).getNum());
data.put("difficultPeopleNum",cjStatsDao.getDifficultPeopleNumStats(vo).getNum());
data.put("issueNum", severeAreaIssueStat.getNum());
data.put("issueAmount", severeAreaIssueStat.getAmount());
areaPeopleNumList.add(data);
......
......@@ -65,6 +65,22 @@
</if>
</select>
<select id="getDifficultPeopleNumStats" resultType="com.zq.portal.vo.StatsVo">
SELECT
COUNT( 1 ) 'num'
FROM
`cjrjz_proposer`
WHERE
ENSURE_LEVEL_ID IS NOT NULL
AND ENSURE_LEVEL_ID IN (3,4)
<if test="subAreaCode != null and subAreaCode != ''">
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
<if test="year != null">
AND LEFT(CREATE_DATE, 4) = #{year}
</if>
</select>
<select id="getAreaIssueStats" resultType="com.zq.portal.vo.StatsVo">
SELECT LEFT(UNIT_ID, #{size}) 'code', APPLY_TYPE_ID 'type', GRANT_YEAR 'year', COUNT_PEOPLE 'num', SUM_MONEY
'amount'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment