Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
civil-bigdata
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
civil
civil-bigdata
Commits
7873c0aa
Commit
7873c0aa
authored
May 05, 2023
by
wqc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整app数据接口
parent
024c8fae
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
1019 additions
and
808 deletions
+1019
-808
api-server/src/main/java/com/zq/api/feign/PortalFeign.java
+85
-79
api-server/src/main/java/com/zq/api/service/IApiLogic.java
+126
-120
api-server/src/main/java/com/zq/api/service/impl/ApiV100Logic.java
+207
-197
portal-server/src/main/java/com/zq/portal/controller/app/CjStatsController.java
+6
-0
portal-server/src/main/java/com/zq/portal/controller/app/ShjzStatsController.java
+6
-1
portal-server/src/main/java/com/zq/portal/dao/CjStatsDao.java
+4
-0
portal-server/src/main/java/com/zq/portal/dao/ShjzStatsDao.java
+5
-0
portal-server/src/main/java/com/zq/portal/entity/AppData.java
+37
-0
portal-server/src/main/java/com/zq/portal/service/CjStatsService.java
+50
-3
portal-server/src/main/java/com/zq/portal/service/ShjzStatsService.java
+40
-7
portal-server/src/main/resources/mapper/CjStatsMapper.xml
+188
-159
portal-server/src/main/resources/mapper/ShjzStatsDao.xml
+265
-242
No files found.
api-server/src/main/java/com/zq/api/feign/PortalFeign.java
View file @
7873c0aa
package
com
.
zq
.
api
.
feign
;
package
com
.
zq
.
api
.
feign
;
import
com.zq.api.config.FeignConfig
;
import
com.zq.api.config.FeignConfig
;
import
com.zq.common.vo.ResultVo
;
import
com.zq.common.vo.ResultVo
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.Map
;
import
java.util.Map
;
@FeignClient
(
name
=
"PORTAL-SERVER"
,
configuration
=
FeignConfig
.
class
)
//指定调用哪个微服务
@FeignClient
(
name
=
"PORTAL-SERVER"
,
configuration
=
FeignConfig
.
class
)
//指定调用哪个微服务
@RequestMapping
(
"/portal/app"
)
@RequestMapping
(
"/portal/app"
)
public
interface
PortalFeign
{
public
interface
PortalFeign
{
@GetMapping
(
"/area/getChildAreaList"
)
@GetMapping
(
"/area/getChildAreaList"
)
ResultVo
getChildAreaList
(
@RequestParam
String
areaCode
);
ResultVo
getChildAreaList
(
@RequestParam
String
areaCode
);
@PostMapping
(
"/stats/getMarriageStats"
)
@PostMapping
(
"/stats/getMarriageStats"
)
ResultVo
getMarriageStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getMarriageStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getYearMarriedCouple"
)
@PostMapping
(
"/stats/getYearMarriedCouple"
)
ResultVo
getYearMarriedCouple
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getYearMarriedCouple
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAreaUnderMarriageStatsList"
)
@PostMapping
(
"/stats/getAreaUnderMarriageStatsList"
)
ResultVo
getAreaUnderMarriageStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAreaUnderMarriageStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getFivesYearMarriageLine"
)
@PostMapping
(
"/stats/getFivesYearMarriageLine"
)
ResultVo
getFivesYearMarriageLine
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getFivesYearMarriageLine
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAreaDisabledIssueStats"
)
@PostMapping
(
"/stats/getAreaDisabledIssueStats"
)
ResultVo
getAreaDisabledIssueStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAreaDisabledIssueStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getYearDisabledIssueStats"
)
@PostMapping
(
"/stats/getYearDisabledIssueStats"
)
ResultVo
getYearDisabledIssueStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getYearDisabledIssueStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAreaShjzStats"
)
@PostMapping
(
"/stats/getAreaShjzStats"
)
ResultVo
getAreaShjzStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAreaShjzStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getFivesYearShjzAchieveStats"
)
@PostMapping
(
"/stats/getAppShjzData"
)
ResultVo
getFivesYearShjzAchieveStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAppShjzData
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getFivesYearShjzProvideStats"
)
@PostMapping
(
"/stats/getAppEnjoyData"
)
ResultVo
getFivesYearShjzProvideStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAppEnjoyData
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getSoorganStats"
)
@PostMapping
(
"/stats/getFivesYearShjzAchieveStats"
)
ResultVo
getSoorganStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getFivesYearShjzAchieveStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAreaUnderSoorganStatsList"
)
@PostMapping
(
"/stats/getFivesYearShjzProvideStats"
)
ResultVo
getAreaUnderSoorganStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getFivesYearShjzProvideStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAppMapStats"
)
@PostMapping
(
"/stats/getSoorganStats"
)
ResultVo
getAppMapStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getSoorganStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/gatherSearch"
)
@PostMapping
(
"/stats/getAreaUnderSoorganStatsList"
)
ResultVo
gatherSearch
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAreaUnderSoorganStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAgencyChildStats"
)
@PostMapping
(
"/stats/getAppMapStats"
)
ResultVo
getAgencyChildStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAppMapStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAgencyChildStatsList"
)
@PostMapping
(
"/stats/gatherSearch"
)
ResultVo
getAgencyChildStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
gatherSearch
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getCremationStats"
)
@PostMapping
(
"/stats/getAgencyChildStats"
)
ResultVo
getCremationStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAgencyChildStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getCremationStatsList"
)
@PostMapping
(
"/stats/getAgencyChildStatsList"
)
ResultVo
getCremationStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAgencyChildStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getCremationStatsById"
)
@PostMapping
(
"/stats/getCremationStats"
)
ResultVo
getCremationStatsById
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getCremationStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getAreaUnderNumStats"
)
@PostMapping
(
"/stats/getCremationStatsList"
)
ResultVo
getAreaUnderNumStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getCremationStatsList
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getEnjoySubsidyStats"
)
@PostMapping
(
"/stats/getCremationStatsById"
)
ResultVo
getEnjoySubsidyStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getCremationStatsById
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getEnjoySumStatsData"
)
@PostMapping
(
"/stats/getAreaUnderNumStats"
)
ResultVo
getEnjoySumStatsData
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
ResultVo
getAreaUnderNumStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
}
@PostMapping
(
"/stats/getEnjoySubsidyStats"
)
ResultVo
getEnjoySubsidyStats
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
@PostMapping
(
"/stats/getEnjoySumStatsData"
)
ResultVo
getEnjoySumStatsData
(
@RequestBody
Map
<
String
,
Object
>
paramsMap
);
}
api-server/src/main/java/com/zq/api/service/IApiLogic.java
View file @
7873c0aa
package
com
.
zq
.
api
.
service
;
package
com
.
zq
.
api
.
service
;
import
com.zq.api.constant.ApiMethod
;
import
com.zq.api.constant.ApiMethod
;
import
com.zq.api.form.ApiForm
;
import
com.zq.api.form.ApiForm
;
import
com.zq.api.form.ApiResp
;
import
com.zq.api.form.ApiResp
;
/**
/**
* api实现接口
* api实现接口
* <p>
* <p>
* 2016年9月29日 上午11:45:08
* 2016年9月29日 上午11:45:08
*/
*/
public
interface
IApiLogic
extends
IApiCommon
{
public
interface
IApiLogic
extends
IApiCommon
{
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓SYS APP接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓SYS APP接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
@ApiMethod
(
name
=
"获取用户信息"
,
service
=
"SYS-SERVER"
)
@ApiMethod
(
name
=
"获取用户信息"
,
service
=
"SYS-SERVER"
)
ApiResp
getUserInfo
(
ApiForm
form
);
ApiResp
getUserInfo
(
ApiForm
form
);
@ApiMethod
(
name
=
"发送验证码"
,
service
=
"SYS-SERVER"
)
@ApiMethod
(
name
=
"发送验证码"
,
service
=
"SYS-SERVER"
)
ApiResp
sendCode
(
ApiForm
form
);
ApiResp
sendCode
(
ApiForm
form
);
@ApiMethod
(
name
=
"重置密码"
,
service
=
"SYS-SERVER"
)
@ApiMethod
(
name
=
"重置密码"
,
service
=
"SYS-SERVER"
)
ApiResp
resetPassword
(
ApiForm
form
);
ApiResp
resetPassword
(
ApiForm
form
);
@ApiMethod
(
name
=
"用户手机号登录"
,
service
=
"SYS-SERVER"
)
@ApiMethod
(
name
=
"用户手机号登录"
,
service
=
"SYS-SERVER"
)
ApiResp
phoneLogin
(
ApiForm
form
);
ApiResp
phoneLogin
(
ApiForm
form
);
@ApiMethod
(
name
=
"密码登录"
,
service
=
"SYS-SERVER"
)
@ApiMethod
(
name
=
"密码登录"
,
service
=
"SYS-SERVER"
)
ApiResp
passwdLogin
(
ApiForm
form
);
ApiResp
passwdLogin
(
ApiForm
form
);
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓门户接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓门户接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
@ApiMethod
(
name
=
"获取婚姻统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取婚姻统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getMarriageStats
(
ApiForm
form
);
ApiResp
getMarriageStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取1年结婚离婚对数"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取1年结婚离婚对数"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getYearMarriedCouple
(
ApiForm
form
);
ApiResp
getYearMarriedCouple
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取区域下的婚姻统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取区域下的婚姻统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAreaUnderMarriageStatsList
(
ApiForm
form
);
ApiResp
getAreaUnderMarriageStatsList
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取近5年婚姻走势"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取近5年婚姻走势"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getFivesYearMarriageLine
(
ApiForm
form
);
ApiResp
getFivesYearMarriageLine
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取区域残疾发放统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取区域残疾发放统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAreaDisabledIssueStats
(
ApiForm
form
);
ApiResp
getAreaDisabledIssueStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"近五年发放人数和金额统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"近五年发放人数和金额统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getYearDisabledIssueStats
(
ApiForm
form
);
ApiResp
getYearDisabledIssueStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取在享补贴统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取在享补贴统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getEnjoySubsidyStats
(
ApiForm
form
);
ApiResp
getEnjoySubsidyStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取区域统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取区域统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAreaShjzStats
(
ApiForm
form
);
ApiResp
getAreaShjzStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取区域社会救助统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取app统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAreaUnderNumStats
(
ApiForm
form
);
ApiResp
getAppShjzData
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取近五年城市农村低保发放人数统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"区域在享发放统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getFivesYearShjzAchieveStats
(
ApiForm
form
);
ApiResp
getAppEnjoyData
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取近五年城市农村低保发放金额统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取区域社会救助统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getFivesYearShjzProvideStats
(
ApiForm
form
);
ApiResp
getAreaUnderNumStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"修改登录密码"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取近五年城市农村低保发放人数统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
modifyPasswd
(
ApiForm
form
);
ApiResp
getFivesYearShjzAchieveStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取App最新版本"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取近五年城市农村低保发放金额统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAppVersion
(
ApiForm
form
);
ApiResp
getFivesYearShjzProvideStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取子区域列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"修改登录密码"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getChildAreaList
(
ApiForm
form
);
ApiResp
modifyPasswd
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取社会机构统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取App最新版本"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getSoorganStats
(
ApiForm
form
);
ApiResp
getAppVersion
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取地区下面社会机构统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取子区域列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAreaUnderSoorganStatsList
(
ApiForm
form
);
ApiResp
getChildAreaList
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取App首页地图数据"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取社会机构统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAppMapStats
(
ApiForm
form
);
ApiResp
getSoorganStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"汇总搜索"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取地区下面社会机构统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
gatherSearch
(
ApiForm
form
);
ApiResp
getAreaUnderSoorganStatsList
(
ApiForm
form
);
@ApiMethod
(
name
=
"指定区域下的儿童福利数据统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"获取App首页地图数据"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAgencyChildStats
(
ApiForm
form
);
ApiResp
getAppMapStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"指定区域下级区域的儿童福利数据统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"汇总搜索"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getAgencyChildStatsList
(
ApiForm
form
);
ApiResp
gatherSearch
(
ApiForm
form
);
@ApiMethod
(
name
=
"火化量统计"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"指定区域下的儿童福利数据统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getCremationStats
(
ApiForm
form
);
ApiResp
getAgencyChildStats
(
ApiForm
form
);
@ApiMethod
(
name
=
"火化量统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"指定区域下级区域的儿童福利数据统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getCremationStatsList
(
ApiForm
form
);
ApiResp
getAgencyChildStatsList
(
ApiForm
form
);
@ApiMethod
(
name
=
"殡仪馆火化量统计列表"
,
service
=
"PORTAL-SERVER"
)
@ApiMethod
(
name
=
"火化量统计"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getCremationStatsById
(
ApiForm
form
);
ApiResp
getCremationStats
(
ApiForm
form
);
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓SYS单点登录接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
@ApiMethod
(
name
=
"火化量统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getCremationStatsList
(
ApiForm
form
);
@ApiMethod
(
name
=
"获取单点登录用户信息"
,
service
=
"SYS-SERVER"
)
ApiResp
getSsoUserInfo
(
ApiForm
form
);
@ApiMethod
(
name
=
"殡仪馆火化量统计列表"
,
service
=
"PORTAL-SERVER"
)
ApiResp
getCremationStatsById
(
ApiForm
form
);
@ApiMethod
(
name
=
"单点登出"
,
service
=
"SYS-SERVER"
)
ApiResp
ssoLogout
(
ApiForm
form
);
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓SYS单点登录接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓开放接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
@ApiMethod
(
name
=
"获取单点登录用户信息"
,
service
=
"SYS-SERVER"
)
ApiResp
getSsoUserInfo
(
ApiForm
form
);
@ApiMethod
(
name
=
"婚姻搜索接口"
,
service
=
"OPEN-SERVER"
)
@ApiMethod
(
name
=
"单点登出"
,
service
=
"SYS-SERVER"
)
ApiResp
marriageSearch
(
ApiForm
form
);
ApiResp
ssoLogout
(
ApiForm
form
);
@ApiMethod
(
name
=
"自然人搜索接口"
,
service
=
"OPEN-SERVER"
)
/*↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓开放接口↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓*/
ApiResp
naturalPersonSearch
(
ApiForm
form
);
@ApiMethod
(
name
=
"火化搜索接口"
,
service
=
"OPEN-SERVER"
)
@ApiMethod
(
name
=
"婚姻搜索接口"
,
service
=
"OPEN-SERVER"
)
ApiResp
cremationSearch
(
ApiForm
form
);
ApiResp
marriageSearch
(
ApiForm
form
);
}
@ApiMethod
(
name
=
"自然人搜索接口"
,
service
=
"OPEN-SERVER"
)
ApiResp
naturalPersonSearch
(
ApiForm
form
);
@ApiMethod
(
name
=
"火化搜索接口"
,
service
=
"OPEN-SERVER"
)
ApiResp
cremationSearch
(
ApiForm
form
);
}
api-server/src/main/java/com/zq/api/service/impl/ApiV100Logic.java
View file @
7873c0aa
package
com
.
zq
.
api
.
service
.
impl
;
package
com
.
zq
.
api
.
service
.
impl
;
import
com.zq.api.feign.OpenFeign
;
import
com.zq.api.feign.OpenFeign
;
import
com.zq.api.feign.PortalFeign
;
import
com.zq.api.feign.PortalFeign
;
import
com.zq.api.feign.SysFeign
;
import
com.zq.api.feign.SysFeign
;
import
com.zq.api.form.ApiForm
;
import
com.zq.api.form.ApiForm
;
import
com.zq.api.form.ApiResp
;
import
com.zq.api.form.ApiResp
;
import
com.zq.api.service.IApiLogic
;
import
com.zq.api.service.IApiLogic
;
import
com.zq.api.utils.ApiUtils
;
import
com.zq.api.utils.ApiUtils
;
import
com.zq.common.config.security.ApiTokenUtils
;
import
com.zq.common.config.security.ApiTokenUtils
;
import
com.zq.common.vo.ApiTokenVo
;
import
com.zq.common.vo.ApiTokenVo
;
import
com.zq.common.vo.ResultVo
;
import
com.zq.common.vo.ResultVo
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
import
java.util.Map
;
import
java.util.Map
;
@Component
@Component
public
class
ApiV100Logic
extends
BaseApiLogic
implements
IApiLogic
{
public
class
ApiV100Logic
extends
BaseApiLogic
implements
IApiLogic
{
@Autowired
@Autowired
private
SysFeign
sysFeign
;
private
SysFeign
sysFeign
;
@Autowired
@Autowired
private
PortalFeign
portalFeign
;
private
PortalFeign
portalFeign
;
@Autowired
@Autowired
private
OpenFeign
openFeign
;
private
OpenFeign
openFeign
;
@Override
@Override
public
ApiResp
getUserInfo
(
ApiForm
form
)
{
public
ApiResp
getUserInfo
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
ResultVo
.
success
(
ApiTokenUtils
.
getAppTokenVo
(
form
.
getToken
())));
return
ApiUtils
.
toApiResp
(
form
,
ResultVo
.
success
(
ApiTokenUtils
.
getAppTokenVo
(
form
.
getToken
())));
}
}
@Override
@Override
public
ApiResp
sendCode
(
ApiForm
form
)
{
public
ApiResp
sendCode
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
sendCode
(
form
.
getString
(
"phone"
)));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
sendCode
(
form
.
getString
(
"phone"
)));
}
}
@Override
@Override
public
ApiResp
resetPassword
(
ApiForm
form
)
{
public
ApiResp
resetPassword
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
resetPassword
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
resetPassword
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
phoneLogin
(
ApiForm
form
)
{
public
ApiResp
phoneLogin
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
phoneLogin
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
phoneLogin
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
passwdLogin
(
ApiForm
form
)
{
public
ApiResp
passwdLogin
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
passwdLogin
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
passwdLogin
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
modifyPasswd
(
ApiForm
form
)
{
public
ApiResp
modifyPasswd
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
modifyPasswd
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
modifyPasswd
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAppVersion
(
ApiForm
form
)
{
public
ApiResp
getAppVersion
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
getAppVersion
(
form
.
getString
(
"appName"
)));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
getAppVersion
(
form
.
getString
(
"appName"
)));
}
}
@Override
@Override
public
ApiResp
getChildAreaList
(
ApiForm
form
)
{
public
ApiResp
getChildAreaList
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getChildAreaList
(
form
.
getString
(
"areaCode"
)));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getChildAreaList
(
form
.
getString
(
"areaCode"
)));
}
}
@Override
@Override
public
ApiResp
getMarriageStats
(
ApiForm
form
)
{
public
ApiResp
getMarriageStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getMarriageStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getMarriageStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getYearMarriedCouple
(
ApiForm
form
)
{
public
ApiResp
getYearMarriedCouple
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getYearMarriedCouple
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getYearMarriedCouple
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAreaUnderMarriageStatsList
(
ApiForm
form
)
{
public
ApiResp
getAreaUnderMarriageStatsList
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderMarriageStatsList
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderMarriageStatsList
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getFivesYearMarriageLine
(
ApiForm
form
)
{
public
ApiResp
getFivesYearMarriageLine
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearMarriageLine
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearMarriageLine
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAreaDisabledIssueStats
(
ApiForm
form
)
{
public
ApiResp
getAreaDisabledIssueStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaDisabledIssueStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaDisabledIssueStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getYearDisabledIssueStats
(
ApiForm
form
)
{
public
ApiResp
getYearDisabledIssueStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getYearDisabledIssueStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getYearDisabledIssueStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getEnjoySubsidyStats
(
ApiForm
form
)
{
public
ApiResp
getEnjoySubsidyStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getEnjoySubsidyStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getEnjoySubsidyStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAreaShjzStats
(
ApiForm
form
)
{
public
ApiResp
getAreaShjzStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaShjzStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaShjzStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAreaUnderNumStats
(
ApiForm
form
)
{
public
ApiResp
getAppShjzData
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderNumStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAppShjzData
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getFivesYearShjzAchieveStats
(
ApiForm
form
)
{
public
ApiResp
getAppEnjoyData
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearShjzAchieveStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAppEnjoyData
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getFivesYearShjzProvideStats
(
ApiForm
form
)
{
public
ApiResp
getAreaUnderNumStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearShjzProvideStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderNumStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getSoorganStats
(
ApiForm
form
)
{
public
ApiResp
getFivesYearShjzAchieveStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getSoorganStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearShjzAchieveStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAreaUnderSoorganStatsList
(
ApiForm
form
)
{
public
ApiResp
getFivesYearShjzProvideStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderSoorganStatsList
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getFivesYearShjzProvideStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAppMapStats
(
ApiForm
form
)
{
public
ApiResp
getSoorganStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAppMapStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getSoorganStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
gatherSearch
(
ApiForm
form
)
{
public
ApiResp
getAreaUnderSoorganStatsList
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
gatherSearch
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAreaUnderSoorganStatsList
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAgencyChildStats
(
ApiForm
form
)
{
public
ApiResp
getAppMapStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAgencyChildStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAppMapStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getAgencyChildStatsList
(
ApiForm
form
)
{
public
ApiResp
gatherSearch
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAgencyChildStatsList
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
gatherSearch
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getCremationStats
(
ApiForm
form
)
{
public
ApiResp
getAgencyChildStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStats
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAgencyChildStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getCremationStatsList
(
ApiForm
form
)
{
public
ApiResp
getAgencyChildStatsList
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStatsList
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getAgencyChildStatsList
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getCremationStatsById
(
ApiForm
form
)
{
public
ApiResp
getCremationStats
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStatsById
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStats
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
getSsoUserInfo
(
ApiForm
form
)
{
public
ApiResp
getCremationStatsList
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
getSsoUserInfo
(
form
.
getAppId
()));
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStatsList
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
ssoLogout
(
ApiForm
form
)
{
public
ApiResp
getCremationStatsById
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
ssoLogout
());
return
ApiUtils
.
toApiResp
(
form
,
portalFeign
.
getCremationStatsById
(
form
.
getParamsMap
()));
}
}
@Override
@Override
public
ApiResp
marriageSearch
(
ApiForm
form
)
{
public
ApiResp
getSsoUserInfo
(
ApiForm
form
)
{
Map
<
String
,
Object
>
paramsMap
=
form
.
getParamsMap
();
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
getSsoUserInfo
(
form
.
getAppId
()));
ApiTokenVo
apiTokenVo
=
form
.
getApiTokenVo
();
}
if
(
apiTokenVo
!=
null
&&
apiTokenVo
.
getRoleLevel
()
==
1
)
{
paramsMap
.
put
(
"queryType"
,
1
);
@Override
}
public
ApiResp
ssoLogout
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
marriageSearch
(
paramsMap
));
return
ApiUtils
.
toApiResp
(
form
,
sysFeign
.
ssoLogout
());
}
}
@Override
@Override
public
ApiResp
naturalPersonSearch
(
ApiForm
form
)
{
public
ApiResp
marriageSearch
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
naturalPersonSearch
(
form
.
getParamsMap
()));
Map
<
String
,
Object
>
paramsMap
=
form
.
getParamsMap
();
}
ApiTokenVo
apiTokenVo
=
form
.
getApiTokenVo
();
if
(
apiTokenVo
!=
null
&&
apiTokenVo
.
getRoleLevel
()
==
1
)
{
@Override
paramsMap
.
put
(
"queryType"
,
1
);
public
ApiResp
cremationSearch
(
ApiForm
form
)
{
}
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
cremationSearch
(
form
.
getParamsMap
()));
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
marriageSearch
(
paramsMap
));
}
}
}
@Override
public
ApiResp
naturalPersonSearch
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
naturalPersonSearch
(
form
.
getParamsMap
()));
}
@Override
public
ApiResp
cremationSearch
(
ApiForm
form
)
{
return
ApiUtils
.
toApiResp
(
form
,
openFeign
.
cremationSearch
(
form
.
getParamsMap
()));
}
}
portal-server/src/main/java/com/zq/portal/controller/app/CjStatsController.java
View file @
7873c0aa
...
@@ -47,4 +47,10 @@ public class CjStatsController {
...
@@ -47,4 +47,10 @@ public class CjStatsController {
return
ResultVo
.
success
(
cjStatsService
.
getEnjoySubsidyStats
(
vo
));
return
ResultVo
.
success
(
cjStatsService
.
getEnjoySubsidyStats
(
vo
));
}
}
@ApiOperation
(
"区域在享发放统计"
)
@PostMapping
(
value
=
"/getAppEnjoyData"
)
public
ResultVo
getAppEnjoyData
(
@RequestBody
StatsReqVo
vo
)
{
return
ResultVo
.
success
(
cjStatsService
.
getAppEnjoyData
(
vo
));
}
}
}
portal-server/src/main/java/com/zq/portal/controller/app/ShjzStatsController.java
View file @
7873c0aa
...
@@ -65,8 +65,13 @@ public class ShjzStatsController {
...
@@ -65,8 +65,13 @@ public class ShjzStatsController {
@ApiOperation
(
"获取区域统计列表"
)
@ApiOperation
(
"获取区域统计列表"
)
@PostMapping
(
value
=
"/getAreaShjzStats"
)
@PostMapping
(
value
=
"/getAreaShjzStats"
)
public
ResultVo
getAreaShjzStats
(
@RequestBody
StatsReqVo
vo
)
{
public
ResultVo
getAreaShjzStats
(
@RequestBody
StatsReqVo
vo
)
{
// AssertUtils.notNull(vo.getYear(), "年份不能为空");
return
ResultVo
.
success
(
shjzStatsService
.
getCacheAreaShjzStats
(
vo
));
return
ResultVo
.
success
(
shjzStatsService
.
getCacheAreaShjzStats
(
vo
));
}
}
@ApiOperation
(
"获取app统计列表"
)
@PostMapping
(
value
=
"/getAppShjzData"
)
public
ResultVo
getAppShjzData
(
@RequestBody
StatsReqVo
vo
)
{
return
ResultVo
.
success
(
shjzStatsService
.
getAppShjzData
(
vo
));
}
}
}
portal-server/src/main/java/com/zq/portal/dao/CjStatsDao.java
View file @
7873c0aa
...
@@ -73,4 +73,8 @@ public interface CjStatsDao {
...
@@ -73,4 +73,8 @@ public interface CjStatsDao {
List
<
StatsVo
>
getAreaSubsidyStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAreaSubsidyStats
(
StatsReqVo
vo
);
StatsVo
getEnjoySumStats
(
StatsReqVo
vo
);
StatsVo
getEnjoySumStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAppEnjoyData
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAppEnjoyTotal
(
StatsReqVo
vo
);
}
}
portal-server/src/main/java/com/zq/portal/dao/ShjzStatsDao.java
View file @
7873c0aa
...
@@ -2,6 +2,7 @@ package com.zq.portal.dao;
...
@@ -2,6 +2,7 @@ package com.zq.portal.dao;
import
com.baomidou.dynamic.datasource.annotation.DS
;
import
com.baomidou.dynamic.datasource.annotation.DS
;
import
com.zq.common.constant.DBName
;
import
com.zq.common.constant.DBName
;
import
com.zq.portal.entity.AppData
;
import
com.zq.portal.vo.SearchReqVo
;
import
com.zq.portal.vo.SearchReqVo
;
import
com.zq.portal.vo.StatsReqVo
;
import
com.zq.portal.vo.StatsReqVo
;
import
com.zq.portal.vo.StatsVo
;
import
com.zq.portal.vo.StatsVo
;
...
@@ -79,4 +80,8 @@ public interface ShjzStatsDao {
...
@@ -79,4 +80,8 @@ public interface ShjzStatsDao {
List
<
StatsVo
>
getMonyNumStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getMonyNumStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAreaTotalNumStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAreaTotalNumStats
(
StatsReqVo
vo
);
List
<
StatsVo
>
getAppShjzData
(
StatsReqVo
vo
);
AppData
getAppData
();
}
}
portal-server/src/main/java/com/zq/portal/entity/AppData.java
0 → 100644
View file @
7873c0aa
package
com
.
zq
.
portal
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@TableName
(
value
=
"app_data"
)
public
class
AppData
{
/**
* id
*/
@TableId
(
type
=
IdType
.
AUTO
)
private
Long
id
;
/**
*
*/
@ApiModelProperty
(
"临时救助人数(来源救助系统查询)"
)
private
String
temporaryHelp
;
/**
*
*/
@ApiModelProperty
(
"支出型困难(来源救助系统查询)"
)
private
String
expensesHu
;
}
portal-server/src/main/java/com/zq/portal/service/CjStatsService.java
View file @
7873c0aa
...
@@ -180,7 +180,7 @@ public class CjStatsService {
...
@@ -180,7 +180,7 @@ public class CjStatsService {
issueStatsList
.
sort
(
Comparator
.
comparing
(
StatsVo:
:
getYear
));
issueStatsList
.
sort
(
Comparator
.
comparing
(
StatsVo:
:
getYear
));
for
(
StatsVo
difficultStats
:
issueStatsList
)
{
for
(
StatsVo
difficultStats
:
issueStatsList
)
{
numList
.
add
(
String
.
valueOf
(
difficultStats
.
getNum
()));
numList
.
add
(
String
.
valueOf
(
difficultStats
.
getNum
()));
amountList
.
add
(
difficultStats
.
getAmount
());
amountList
.
add
(
difficultStats
.
getAmount
()
.
toString
()
);
}
}
}
}
...
@@ -229,7 +229,7 @@ public class CjStatsService {
...
@@ -229,7 +229,7 @@ public class CjStatsService {
}
}
areaList
.
add
(
area
.
getName
());
areaList
.
add
(
area
.
getName
());
severeIssueNumList
.
add
(
String
.
valueOf
(
severeAreaIssueStat
.
getNum
()));
severeIssueNumList
.
add
(
String
.
valueOf
(
severeAreaIssueStat
.
getNum
()));
severeIssueAmountList
.
add
(
severeAreaIssueStat
.
getAmount
());
severeIssueAmountList
.
add
(
severeAreaIssueStat
.
getAmount
()
.
toString
()
);
vo
.
setSubAreaCode
(
severeAreaIssueStat
.
getCode
());
vo
.
setSubAreaCode
(
severeAreaIssueStat
.
getCode
());
Map
<
String
,
Object
>
data
=
new
HashMap
<>();
Map
<
String
,
Object
>
data
=
new
HashMap
<>();
...
@@ -250,7 +250,7 @@ public class CjStatsService {
...
@@ -250,7 +250,7 @@ public class CjStatsService {
Optional
<
Map
<
String
,
Object
>>
oData
=
areaPeopleNumList
.
stream
().
filter
(
m
->
m
.
get
(
"areaCode"
).
toString
().
equals
(
statsVo
.
getCode
())).
findFirst
();
Optional
<
Map
<
String
,
Object
>>
oData
=
areaPeopleNumList
.
stream
().
filter
(
m
->
m
.
get
(
"areaCode"
).
toString
().
equals
(
statsVo
.
getCode
())).
findFirst
();
oData
.
ifPresent
(
data
->
{
oData
.
ifPresent
(
data
->
{
difficultIssueNumList
.
add
(
String
.
valueOf
(
statsVo
.
getNum
()));
difficultIssueNumList
.
add
(
String
.
valueOf
(
statsVo
.
getNum
()));
difficultIssueAmountList
.
add
(
statsVo
.
getAmount
());
difficultIssueAmountList
.
add
(
statsVo
.
getAmount
()
.
toString
()
);
BigDecimal
issueNum
=
new
BigDecimal
(
data
.
get
(
"issueNum"
).
toString
()).
add
(
BigDecimal
.
valueOf
(
statsVo
.
getNum
()));
BigDecimal
issueNum
=
new
BigDecimal
(
data
.
get
(
"issueNum"
).
toString
()).
add
(
BigDecimal
.
valueOf
(
statsVo
.
getNum
()));
BigDecimal
issueAmount
=
new
BigDecimal
(
data
.
get
(
"issueAmount"
).
toString
()).
add
(
new
BigDecimal
(
statsVo
.
getAmount
()));
BigDecimal
issueAmount
=
new
BigDecimal
(
data
.
get
(
"issueAmount"
).
toString
()).
add
(
new
BigDecimal
(
statsVo
.
getAmount
()));
data
.
put
(
"issueNum"
,
issueNum
);
data
.
put
(
"issueNum"
,
issueNum
);
...
@@ -328,4 +328,51 @@ public class CjStatsService {
...
@@ -328,4 +328,51 @@ public class CjStatsService {
return
returnData
;
return
returnData
;
}
}
public
Object
getAppEnjoyData
(
StatsReqVo
vo
)
{
if
(
StringUtils
.
isBlank
(
vo
.
getAreaCode
()))
{
vo
.
setAreaCode
(
"450000000000"
);
}
SystemArea
systemArea
=
areaDao
.
selectById
(
vo
.
getAreaCode
());
vo
.
setSubAreaCode
(
systemArea
.
subAreaCode
());
vo
.
setSize
(
SystemArea
.
getNextLevelLength
(
systemArea
.
getType
()));
List
<
StatsVo
>
peopleNumStats
=
cjStatsDao
.
getAppEnjoyData
(
vo
);
List
<
StatsVo
>
stats
=
cjStatsDao
.
getAppEnjoyTotal
(
vo
);
Map
<
String
,
Object
>
totalData
=
new
HashMap
<>();
for
(
StatsVo
totalStat
:
stats
)
{
if
(
"1"
.
equals
(
totalStat
.
getType
()))
{
totalData
.
put
(
"severeTotal"
,
BigDecimal
.
valueOf
(
totalStat
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
}
else
{
totalData
.
put
(
"difficultTotal"
,
BigDecimal
.
valueOf
(
totalStat
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
}
}
Map
<
String
,
Map
<
String
,
Object
>>
map
=
new
HashMap
<>();
// 添加重度残疾人护理补贴人数
List
<
StatsVo
>
severeCjNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"1"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
severeCjNumStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"severeCjNum"
,
BigDecimal
.
valueOf
(
statsVo
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
// 添加困难残疾人生活补贴人数
List
<
StatsVo
>
difficultCjNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"2"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
difficultCjNumStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"difficultCjNum"
,
BigDecimal
.
valueOf
(
statsVo
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
List
<
Map
<
String
,
Object
>>
dataList
=
new
ArrayList
<>();
// map数据转成list,提示添加key为区域码
map
.
forEach
((
k
,
v
)
->
{
SystemArea
area
=
areaDao
.
selectById
(
SystemArea
.
patchZero
(
k
));
v
.
put
(
"areaCode"
,
k
);
v
.
put
(
"city"
,
area
!=
null
?
area
.
getName
():
""
);
dataList
.
add
(
v
);
});
List
<
Map
<
String
,
Object
>>
mapData
=
dataList
.
stream
().
sorted
(
Comparator
.
comparing
(
m
->
m
.
get
(
"areaCode"
).
toString
())).
collect
(
Collectors
.
toList
());
Map
<
String
,
Object
>
returnData
=
new
HashMap
<>();
returnData
.
put
(
"map"
,
mapData
);
returnData
.
put
(
"total"
,
totalData
);
return
mapData
;
}
}
}
portal-server/src/main/java/com/zq/portal/service/ShjzStatsService.java
View file @
7873c0aa
...
@@ -358,10 +358,10 @@ public class ShjzStatsService {
...
@@ -358,10 +358,10 @@ public class ShjzStatsService {
Map
<
String
,
Object
>
totalData
=
new
HashMap
<>();
Map
<
String
,
Object
>
totalData
=
new
HashMap
<>();
for
(
StatsVo
totalStat
:
stats
)
{
for
(
StatsVo
totalStat
:
stats
)
{
if
(
"
0
"
.
equals
(
totalStat
.
getType
()))
{
if
(
"
农村低保
"
.
equals
(
totalStat
.
getType
()))
{
totalData
.
put
(
"villageTotal"
,
totalStat
.
getNum
(
));
//农村低保
totalData
.
put
(
"villageTotal"
,
BigDecimal
.
valueOf
(
totalStat
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
//农村低保
}
else
{
}
else
{
totalData
.
put
(
"cityTotal"
,
totalStat
.
getNum
(
));
//城市低保
totalData
.
put
(
"cityTotal"
,
BigDecimal
.
valueOf
(
totalStat
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
//城市低保
}
}
}
}
...
@@ -370,25 +370,25 @@ public class ShjzStatsService {
...
@@ -370,25 +370,25 @@ public class ShjzStatsService {
List
<
StatsVo
>
cityPeopleNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"城市低保"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
List
<
StatsVo
>
cityPeopleNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"城市低保"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
cityPeopleNumStats
.
forEach
(
statsVo
->
{
cityPeopleNumStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"cityPeopleNum"
,
statsVo
.
getNum
(
));
data
.
put
(
"cityPeopleNum"
,
BigDecimal
.
valueOf
(
statsVo
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
});
// 添加农村低保人数
// 添加农村低保人数
List
<
StatsVo
>
villagePeopleNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"农村低保"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
List
<
StatsVo
>
villagePeopleNumStats
=
peopleNumStats
.
stream
().
filter
(
statsVo
->
"农村低保"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
villagePeopleNumStats
.
forEach
(
statsVo
->
{
villagePeopleNumStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"villagePeopleNum"
,
statsVo
.
getNum
(
));
data
.
put
(
"villagePeopleNum"
,
BigDecimal
.
valueOf
(
statsVo
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
});
// 添加城市发放金额
// 添加城市发放金额
List
<
StatsVo
>
cityMonyStats
=
monyStats
.
stream
().
filter
(
statsVo
->
"1"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
List
<
StatsVo
>
cityMonyStats
=
monyStats
.
stream
().
filter
(
statsVo
->
"1"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
cityMonyStats
.
forEach
(
statsVo
->
{
cityMonyStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"cityMoney"
,
statsVo
.
getAmount
(
));
data
.
put
(
"cityMoney"
,
BigDecimal
.
valueOf
(
statsVo
.
getAmount
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
});
// 添加农村发放金额
// 添加农村发放金额
List
<
StatsVo
>
villageMonyStats
=
monyStats
.
stream
().
filter
(
statsVo
->
"0"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
List
<
StatsVo
>
villageMonyStats
=
monyStats
.
stream
().
filter
(
statsVo
->
"0"
.
equals
(
statsVo
.
getType
())).
collect
(
Collectors
.
toList
());
villageMonyStats
.
forEach
(
statsVo
->
{
villageMonyStats
.
forEach
(
statsVo
->
{
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
Map
<
String
,
Object
>
data
=
map
.
computeIfAbsent
(
statsVo
.
getCode
(),
k
->
new
HashMap
<>());
data
.
put
(
"villageMoney"
,
statsVo
.
getAmount
(
));
data
.
put
(
"villageMoney"
,
BigDecimal
.
valueOf
(
statsVo
.
getAmount
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
});
});
List
<
Map
<
String
,
Object
>>
dataList
=
new
ArrayList
<>();
List
<
Map
<
String
,
Object
>>
dataList
=
new
ArrayList
<>();
...
@@ -741,4 +741,37 @@ public class ShjzStatsService {
...
@@ -741,4 +741,37 @@ public class ShjzStatsService {
return
returnData
;
return
returnData
;
}
}
public
Object
getAppShjzData
(
StatsReqVo
vo
)
{
// 人数
List
<
StatsVo
>
totalStat
=
shjzStatsDao
.
getAppShjzData
(
vo
);
Map
<
String
,
Object
>
totalData
=
new
HashMap
<>();
BigDecimal
country
=
null
;
BigDecimal
city
=
null
;
BigDecimal
nong
=
null
;
BigDecimal
cheng
=
null
;
for
(
StatsVo
stats
:
totalStat
)
{
if
(
"农村低保"
.
equals
(
stats
.
getType
()))
{
totalData
.
put
(
"villageTotal"
,
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
//农村低保
}
else
if
(
"城市低保"
.
equals
(
stats
.
getType
())){
totalData
.
put
(
"cityTotal"
,
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
));
//城市低保
}
else
if
(
"农村低收入"
.
equals
(
stats
.
getType
())){
country
=
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
);
}
else
if
(
"城市低收入"
.
equals
(
stats
.
getType
())){
city
=
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
);
}
else
if
(
"农村特困"
.
equals
(
stats
.
getType
())){
nong
=
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
);
}
else
if
(
"城市特困"
.
equals
(
stats
.
getType
())){
cheng
=
BigDecimal
.
valueOf
(
stats
.
getNum
()).
divide
(
BigDecimal
.
valueOf
(
10000
),
2
,
RoundingMode
.
HALF_UP
);
}
totalData
.
put
(
"lowTotal"
,
country
.
add
(
city
));
totalData
.
put
(
"destiTotal"
,
nong
.
add
(
cheng
));
}
Map
<
String
,
Object
>
returnData
=
new
HashMap
<>();
returnData
.
put
(
"totalData"
,
totalData
);
returnData
.
put
(
"temporaryHelp"
,
shjzStatsDao
.
getAppData
().
getTemporaryHelp
());
returnData
.
put
(
"expensesHu"
,
shjzStatsDao
.
getAppData
().
getExpensesHu
());
return
returnData
;
}
}
}
portal-server/src/main/resources/mapper/CjStatsMapper.xml
View file @
7873c0aa
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.zq.portal.dao.CjStatsDao"
>
<mapper
namespace=
"com.zq.portal.dao.CjStatsDao"
>
<select
id=
"getPeopleAmountStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getPeopleAmountStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT COUNT(1) 'num', SUM( SUBSIDY_STANDARD_MONEY ) 'amount', `YEAR` 'year'
SELECT COUNT(1) 'num', SUM( SUBSIDY_STANDARD_MONEY ) 'amount', `YEAR` 'year'
FROM `cjrjz_application`
FROM `cjrjz_application`
WHERE CHECK_STATUS = 1
WHERE CHECK_STATUS = 1
AND `STATUS` = 0
AND `STATUS` = 0
AND APPROVE_DATE IS NOT NULL
AND APPROVE_DATE IS NOT NULL
GROUP BY `YEAR`
GROUP BY `YEAR`
ORDER BY `YEAR` DESC LIMIT 5
ORDER BY `YEAR` DESC LIMIT 5
</select>
</select>
<select
id=
"getDisabledLevelStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getDisabledLevelStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT ENSURE_LEVEL_ID 'type', COUNT( 1 ) 'num'
SELECT ENSURE_LEVEL_ID 'type', COUNT( 1 ) 'num'
FROM `cjrjz_proposer`
FROM `cjrjz_proposer`
WHERE ENSURE_LEVEL_ID IS NOT NULL
WHERE ENSURE_LEVEL_ID IS NOT NULL
<if
test=
"type != null"
>
<if
test=
"type != null"
>
AND ENSURE_LEVEL_ID = #{type}
AND ENSURE_LEVEL_ID = #{type}
</if>
</if>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<if
test=
"year != null"
>
<if
test=
"year != null"
>
AND LEFT(CREATE_DATE, 4) = #{year}
AND LEFT(CREATE_DATE, 4) = #{year}
</if>
</if>
GROUP BY ENSURE_LEVEL_ID
GROUP BY ENSURE_LEVEL_ID
</select>
</select>
<!--获取近年重度残疾人数-->
<!--获取近年重度残疾人数-->
<select
id=
"getYearSevereDisabledStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getYearSevereDisabledStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
LEFT ( CREATE_DATE, 4 ) 'year',
LEFT ( CREATE_DATE, 4 ) 'year',
COUNT( 1 ) 'num'
COUNT( 1 ) 'num'
FROM
FROM
`cjrjz_proposer`
`cjrjz_proposer`
WHERE
WHERE
ENSURE_LEVEL_ID IS NOT NULL
ENSURE_LEVEL_ID IS NOT NULL
AND ENSURE_LEVEL_ID IN (1,2)
AND ENSURE_LEVEL_ID IN (1,2)
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<if
test=
"year != null"
>
<if
test=
"year != null"
>
AND LEFT(CREATE_DATE, 4) = #{year}
AND LEFT(CREATE_DATE, 4) = #{year}
</if>
</if>
GROUP BY LEFT ( CREATE_DATE, 4 )
GROUP BY LEFT ( CREATE_DATE, 4 )
ORDER BY LEFT ( CREATE_DATE, 4 ) DESC
ORDER BY LEFT ( CREATE_DATE, 4 ) DESC
LIMIT #{size}
LIMIT #{size}
</select>
</select>
<select
id=
"getSeverePeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getSeverePeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
COUNT( 1 ) 'num'
COUNT( 1 ) 'num'
FROM
FROM
`cjrjz_proposer`
`cjrjz_proposer`
WHERE
WHERE
ENSURE_LEVEL_ID IS NOT NULL
ENSURE_LEVEL_ID IS NOT NULL
AND ENSURE_LEVEL_ID IN (1,2)
AND ENSURE_LEVEL_ID IN (1,2)
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<if
test=
"year != null"
>
<if
test=
"year != null"
>
AND LEFT(CREATE_DATE, 4) = #{year}
AND LEFT(CREATE_DATE, 4) = #{year}
</if>
</if>
</select>
</select>
<select
id=
"getDifficultPeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getDifficultPeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
COUNT( 1 ) 'num'
COUNT( 1 ) 'num'
FROM
FROM
`cjrjz_proposer`
`cjrjz_proposer`
WHERE
WHERE
ENSURE_LEVEL_ID IS NOT NULL
ENSURE_LEVEL_ID IS NOT NULL
AND ENSURE_LEVEL_ID IN (3,4)
AND ENSURE_LEVEL_ID IN (3,4)
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<if
test=
"year != null"
>
<if
test=
"year != null"
>
AND LEFT(CREATE_DATE, 4) = #{year}
AND LEFT(CREATE_DATE, 4) = #{year}
</if>
</if>
</select>
</select>
<select
id=
"getAreaIssueStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<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
SELECT LEFT(UNIT_ID, #{size}) 'code', APPLY_TYPE_ID 'type', GRANT_YEAR 'year', COUNT_PEOPLE 'num', SUM_MONEY
'amount'
'amount'
FROM `statics_grant`
FROM `statics_grant`
WHERE
WHERE
# DATE_FORMAT(create_time, '%Y-%m-%d') = (SELECT DATE_FORMAT(create_time, '%Y-%m-%d') FROM statics_grant ORDER BY create_time DESC LIMIT 1)
# DATE_FORMAT(create_time, '%Y-%m-%d') = (SELECT DATE_FORMAT(create_time, '%Y-%m-%d') FROM statics_grant ORDER BY create_time DESC LIMIT 1)
CHAR_LENGTH (LEFT ( UNIT_ID, #{size} )) = #{size}
CHAR_LENGTH (LEFT ( UNIT_ID, #{size} )) = #{size}
<if
test=
"year != null"
>
<if
test=
"year != null"
>
AND GRANT_YEAR = #{year}
AND GRANT_YEAR = #{year}
</if>
</if>
<if
test=
"type != null"
>
<if
test=
"type != null"
>
AND APPLY_TYPE_ID = #{type}
AND APPLY_TYPE_ID = #{type}
</if>
</if>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
AND UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
GROUP BY LEFT(UNIT_ID, #{size})
GROUP BY LEFT(UNIT_ID, #{size})
</select>
</select>
<select
id=
"getAreaSubsidyStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getAreaSubsidyStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT LEFT(AREACODE, #{size}) 'code', FF_DATE 'month',SUM(FF_ZD_PC ) 'hlnum', SUM(FF_ZD_MC) 'hlamount',SUM(FF_KUN_PC) 'shnum', SUM(FF_KUN_MC) 'shamount'
SELECT LEFT(AREACODE, #{size}) 'code', FF_DATE 'month',SUM(FF_ZD_PC ) 'hlnum', SUM(FF_ZD_MC) 'hlamount',SUM(FF_KUN_PC) 'shnum', SUM(FF_KUN_MC) 'shamount'
FROM `ff_data_jm`
FROM `ff_data_jm`
WHERE
WHERE
CHAR_LENGTH (LEFT ( AREACODE, #{size} )) = #{size}
CHAR_LENGTH (LEFT ( AREACODE, #{size} )) = #{size}
AND FF_DATE = DATE_FORMAT(NOW(),'%Y-%m')
AND FF_DATE = DATE_FORMAT(NOW(),'%Y-%m')
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND AREACODE LIKE CONCAT(#{subAreaCode}, '%')
AND AREACODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
GROUP BY LEFT(AREACODE, #{size})
GROUP BY LEFT(AREACODE, #{size})
</select>
</select>
<select
id=
"getEnjoySumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getEnjoySumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT SUM(S_PC) 'num' , SUM(S_MC) 'amount'
SELECT SUM(S_PC) 'num' , SUM(S_MC) 'amount'
FROM ff_data_jm
FROM ff_data_jm
WHERE FF_DATE = DATE_FORMAT(NOW(),'%Y-%m')
WHERE FF_DATE = DATE_FORMAT(NOW(),'%Y-%m')
</select>
</select>
<select
id=
"getYearIssueStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getYearIssueStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT APPLY_TYPE_ID 'type', GRANT_YEAR 'year', SUM( COUNT_PEOPLE ) 'num', SUM( SUM_MONEY ) 'amount'
SELECT APPLY_TYPE_ID 'type', GRANT_YEAR 'year', SUM( COUNT_PEOPLE ) 'num', SUM( SUM_MONEY ) 'amount'
FROM `statics_grant`
FROM `statics_grant`
WHERE 1=1
WHERE 1=1
# DATE_FORMAT(create_time, '%Y-%m-%d') = (SELECT DATE_FORMAT(create_time, '%Y-%m-%d') FROM statics_grant
# DATE_FORMAT(create_time, '%Y-%m-%d') = (SELECT DATE_FORMAT(create_time, '%Y-%m-%d') FROM statics_grant
# ORDER BY create_time DESC LIMIT 1)
# ORDER BY create_time DESC LIMIT 1)
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND UNIT_ID LIKE CONCAT( #{subAreaCode}, '%' )
AND UNIT_ID LIKE CONCAT( #{subAreaCode}, '%' )
</if>
</if>
<if
test=
"type != null"
>
<if
test=
"type != null"
>
AND APPLY_TYPE_ID = #{type}
AND APPLY_TYPE_ID = #{type}
</if>
</if>
GROUP BY GRANT_YEAR
GROUP BY GRANT_YEAR
ORDER BY GRANT_YEAR DESC LIMIT #{size}
ORDER BY GRANT_YEAR DESC LIMIT #{size}
</select>
</select>
<select
id=
"getYearList"
resultType=
"java.lang.String"
>
<select
id=
"getYearList"
resultType=
"java.lang.String"
>
SELECT GRANT_YEAR 'year'
SELECT GRANT_YEAR 'year'
FROM `statics_grant`
FROM `statics_grant`
GROUP BY GRANT_YEAR
GROUP BY GRANT_YEAR
ORDER BY GRANT_YEAR DESC LIMIT 5
ORDER BY GRANT_YEAR DESC LIMIT 5
</select>
</select>
<select
id=
"search"
resultType=
"java.util.Map"
>
<select
id=
"search"
resultType=
"java.util.Map"
>
SELECT NAME 'name', CARD_CODE 'idCard',MARRY_TYPE_ID 'marryType', REGISTER_ADDRESS_NAME
SELECT NAME 'name', CARD_CODE 'idCard',MARRY_TYPE_ID 'marryType', REGISTER_ADDRESS_NAME
'addressName',ENSURE_LEVEL_ID 'levelId', CREATE_DATE 'createTime'
'addressName',ENSURE_LEVEL_ID 'levelId', CREATE_DATE 'createTime'
FROM
FROM
cjrjz_proposer
cjrjz_proposer
WHERE 1=1
WHERE 1=1
<if
test=
"keyword != null and keyword != ''"
>
<if
test=
"keyword != null and keyword != ''"
>
AND (NAME =#{keyword} OR CARD_CODE =#{keyword})
AND (NAME =#{keyword} OR CARD_CODE =#{keyword})
</if>
</if>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
AND CARD_CODE LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
ORDER BY CREATE_DATE DESC
ORDER BY CREATE_DATE DESC
</select>
</select>
</mapper>
<select
id=
"getAppEnjoyData"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
LEFT ( a.UNIT_ID, #{size} ) 'code',
a.APPLY_TYPE 'type',
SUM(a.NUM) 'num'
FROM stat_day_enjoy a
WHERE
CHAR_LENGTH (LEFT ( a.UNIT_ID, #{size} )) = #{size}
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND a.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
<if
test=
"type != null and type != ''"
>
AND a.APPLY_TYPE = #{type}
</if>
GROUP BY
LEFT ( a.UNIT_ID, #{size} ),
a.APPLY_TYPE
</select>
<select
id=
"getAppEnjoyTotal"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
h.APPLY_TYPE 'type',
SUM( h.NUM ) 'num'
FROM
stat_day_enjoy h
GROUP BY
type
</select>
</mapper>
portal-server/src/main/resources/mapper/ShjzStatsDao.xml
View file @
7873c0aa
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.zq.portal.dao.ShjzStatsDao"
>
<mapper
namespace=
"com.zq.portal.dao.ShjzStatsDao"
>
<!-- <select id="search" resultType="java.util.Map">-->
<!-- <select id="search" resultType="java.util.Map">-->
<!-- SELECT AXDF0002 'name', AXDF0004 'mainIdCard', AXDF0011 'phone',AXDF0008 'address', AXAA2701 'unitCode'-->
<!-- SELECT AXDF0002 'name', AXDF0004 'mainIdCard', AXDF0011 'phone',AXDF0008 'address', AXAA2701 'unitCode'-->
<!-- ,UPDATETIME 'createTime'-->
<!-- ,UPDATETIME 'createTime'-->
<!-- FROM-->
<!-- FROM-->
<!-- baf01-->
<!-- baf01-->
<!-- WHERE 1 = 1-->
<!-- WHERE 1 = 1-->
<!-- <choose>-->
<!-- <choose>-->
<!-- <when test="keyword != null and keyword != ''">-->
<!-- <when test="keyword != null and keyword != ''">-->
<!-- AND (AXDF0002 = #{keyword}-->
<!-- AND (AXDF0002 = #{keyword}-->
<!-- OR AXDF0004 = #{keyword})-->
<!-- OR AXDF0004 = #{keyword})-->
<!-- </when>-->
<!-- </when>-->
<!-- <otherwise>-->
<!-- <otherwise>-->
<!-- ORDER BY UPDATETIME DESC LIMIT 20-->
<!-- ORDER BY UPDATETIME DESC LIMIT 20-->
<!-- </otherwise>-->
<!-- </otherwise>-->
<!-- </choose>-->
<!-- </choose>-->
<!-- </select>-->
<!-- </select>-->
<select
id=
"search"
resultType=
"java.util.Map"
>
<select
id=
"search"
resultType=
"java.util.Map"
>
SELECT
SELECT
REPLACE(address, '广西壮族自治区-', '') 'address',
REPLACE(address, '广西壮族自治区-', '') 'address',
NAME 'name',
NAME 'name',
id_card 'idCard',
id_card 'idCard',
help_type 'helpType',
help_type 'helpType',
help_amount 'helpAmount',
help_amount 'helpAmount',
provide_state 'provideState',
provide_state 'provideState',
start_provide_date 'startProvideDate',
start_provide_date 'startProvideDate',
end_provide_date 'endProvideDate'
end_provide_date 'endProvideDate'
FROM
FROM
`gw_temptable_20210630`
`gw_temptable_20210630`
WHERE 1 = 1
WHERE 1 = 1
<if
test=
"keyword != null and keyword != ''"
>
<if
test=
"keyword != null and keyword != ''"
>
AND (NAME = #{keyword}
AND (NAME = #{keyword}
OR id_card = #{keyword})
OR id_card = #{keyword})
</if>
</if>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND id_card LIKE CONCAT(#{subAreaCode},'%')
AND id_card LIKE CONCAT(#{subAreaCode},'%')
</if>
</if>
ORDER BY start_provide_date DESC
ORDER BY start_provide_date DESC
</select>
</select>
<select
id=
"getEnjoyNum"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getEnjoyNum"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
( CASE h.ISCITY
( CASE h.ISCITY
WHEN 0 THEN '农村低保'
WHEN 0 THEN '农村低保'
WHEN 1 THEN '城市低保'
WHEN 1 THEN '城市低保'
WHEN 6 THEN '特困供养'
WHEN 6 THEN '特困供养'
WHEN 10 THEN '农村低收入'
WHEN 10 THEN '农村低收入'
WHEN 11 THEN '城市低收入'
WHEN 11 THEN '城市低收入'
WHEN 21 THEN '住房救助'
WHEN 21 THEN '住房救助'
WHEN 31 THEN '城市特困'
WHEN 31 THEN '城市特困'
ELSE '其他' END ) 'type',
ELSE '其他' END ) 'type',
SUM( h.SURE_POPULATION ) 'num'
SUM( h.SURE_POPULATION ) 'num'
FROM ENBUZ_APPLY_HOME h
FROM ENBUZ_APPLY_HOME h
WHERE h.VP_STATE = 4
WHERE h.VP_STATE = 4
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" )
<
= #{date}
AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" )
<
= #{date}
AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= #{date}
AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= #{date}
GROUP BY
GROUP BY
ISCITY
ISCITY
</select>
</select>
<select
id=
"getTemporaryNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getTemporaryNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
LEFT(h.UNIT_ID, 4) 'code',
LEFT(h.UNIT_ID, 4) 'code',
SUM(h.SURE_POPULATION ) 'num'
SUM(h.SURE_POPULATION ) 'num'
FROM
FROM
tem_home_his h
tem_home_his h
WHERE
WHERE
h.VP_STATE = 4
h.VP_STATE = 4
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<choose>
<choose>
<when
test=
"year != null"
>
<when
test=
"year != null"
>
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = #{year}
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = #{year}
</when>
</when>
<otherwise>
<otherwise>
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = DATE_FORMAT(NOW(), "%Y" )
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = DATE_FORMAT(NOW(), "%Y" )
</otherwise>
</otherwise>
</choose>
</choose>
</select>
</select>
<select
id=
"getBorderNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getBorderNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
LEFT(h.UNIT_ID, #{size}) 'code',
LEFT(h.UNIT_ID, #{size}) 'code',
sum( h.SURE_POPULATION ) 'num'
sum( h.SURE_POPULATION ) 'num'
FROM
FROM
border_region_home h
border_region_home h
WHERE h.VP_STATE = 4
WHERE h.VP_STATE = 4
AND h.ISCITY = 8
AND h.ISCITY = 8
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
</if>
<choose>
<choose>
<when
test=
"year != null"
>
<when
test=
"year != null"
>
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = #{year}
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = #{year}
</when>
</when>
<otherwise>
<otherwise>
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = DATE_FORMAT(NOW(), "%Y" )
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) = DATE_FORMAT(NOW(), "%Y" )
</otherwise>
</otherwise>
</choose>
</choose>
</select>
</select>
<select
id=
"getAreaUnderNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<!-- <select id="getAreaUnderNumStats" resultType="com.zq.portal.vo.StatsVo">-->
SELECT
<!-- SELECT-->
LEFT(h.UNIT_ID, #{size}) 'code',
<!-- LEFT(h.UNIT_ID, #{size}) 'code',-->
h.ISCITY 'type',
<!-- h.ISCITY 'type',-->
SUM( h.SURE_POPULATION ) 'num'
<!-- SUM( h.SURE_POPULATION ) 'num'-->
FROM
<!-- FROM-->
ENBUZ_APPLY_HOME h
<!-- ENBUZ_APPLY_HOME h-->
WHERE h.VP_STATE = 4
<!-- WHERE h.VP_STATE = 4-->
AND LEFT(h.UNIT_ID, #{size}) IS NOT NULL
<!-- AND LEFT(h.UNIT_ID, #{size}) IS NOT NULL-->
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
<!-- <if test="subAreaCode != null and subAreaCode != ''">-->
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
<!-- AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')-->
</if>
<!-- </if>-->
<if
test=
"type != null and type != ''"
>
<!-- <if test="type != null and type != ''">-->
AND h.ISCITY = #{type}
<!-- AND h.ISCITY = #{type}-->
</if>
<!-- </if>-->
AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" )
<
= '2021-12-01'
<!-- AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" ) <= '2021-12-01'-->
AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= '2021-12-01'
<!-- AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= '2021-12-01'-->
GROUP BY
<!-- GROUP BY-->
LEFT(h.UNIT_ID, #{size}),
<!-- LEFT(h.UNIT_ID, #{size}),-->
type
<!-- type-->
</select>
<!-- </select>-->
<select
id=
"getAreaTotalNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<select
id=
"getAreaUnderNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
SELECT
h.ISCITY 'type',
LEFT(h.area_code, #{size}) 'code',
SUM( h.SURE_POPULATION ) 'num'
h.type,
FROM
SUM(h.people_num) 'people_num',
ENBUZ_APPLY_HOME h
SUM(h.family_num) 'family_num'
WHERE h.VP_STATE = 4
FROM
AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" )
<
= '2021-12-01'
city_coutry h
AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= '2021-12-01'
WHERE
AND h.ISCITY IN(0,1)
1=1
GROUP BY
AND LEFT(h.area_code, #{size}) IS NOT NULL
type
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
</select>
AND h.area_code LIKE CONCAT(#{subAreaCode}, '%')
</if>
<!--
GROUP BY
SELECT DATE_FORMAT(h.PERMIT_DATE, "%Y-%m") 'date',
LEFT(h.area_code, #{size}),
( CASE h.ISCITY
h.type
WHEN 0 THEN '农村低保'
</select>
WHEN 1 THEN '城市低保'
WHEN 6 THEN '特困供养'
<!-- <select id="getAreaTotalNumStats" resultType="com.zq.portal.vo.StatsVo">-->
WHEN 10 THEN '农村低收入'
<!-- SELECT-->
WHEN 11 THEN '城市低收入'
<!-- h.ISCITY 'type',-->
WHEN 21 THEN '住房救助'
<!-- SUM( h.SURE_POPULATION ) 'num'-->
WHEN 31 THEN '城市特困'
<!-- FROM-->
ELSE '其他' END ) 'type',
<!-- ENBUZ_APPLY_HOME h-->
SUM( h.SURE_POPULATION ) 'num'
<!-- WHERE h.VP_STATE = 4-->
FROM ENBUZ_APPLY_HOME h
<!-- AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m-%d" ) <= '2021-12-01'-->
WHERE h.VP_STATE = 4
<!-- AND DATE_FORMAT( h.STOP_DATE, "%Y-%m-%d" ) >= '2021-12-01'-->
AND h.ISCITY IN(0, 1)
<!-- AND h.ISCITY IN(0,1)-->
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) > DATE_FORMAT(NOW(), "%Y" ) - 5
<!-- GROUP BY-->
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) <= DATE_FORMAT(NOW(), "%Y" )
<!-- type-->
AND DATE_FORMAT( h.PERMIT_DATE, "%Y-%m" ) <= DATE_FORMAT(DATE_SUB(NOW(), INTERVAL 1 MONTH), "%Y-%m")
<!-- </select>-->
AND h.UNIT_ID LIKE CONCAT('45', '%')
GROUP BY
<select
id=
"getAreaTotalNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
DATE_FORMAT( h.PERMIT_DATE, "%Y-%m" ),
SELECT
ISCITY
h.type 'type',
-->
SUM(h.people_num) 'num'
<select
id=
"getFivesYearEnjoyStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
FROM
SELECT LEFT(date, 4) 'year', type, SUM(num) 'num' FROM ( SELECT DATE_FORMAT(h.PERMIT_DATE, "%Y-%m") 'date',
city_coutry h
( CASE h.ISCITY
WHERE
WHEN 0 THEN '农村低保'
h.type IN('城市低保','农村低保')
WHEN 1 THEN '城市低保'
GROUP BY
WHEN 6 THEN '特困供养'
type
WHEN 10 THEN '农村低收入'
</select>
WHEN 11 THEN '城市低收入'
WHEN 21 THEN '住房救助'
WHEN 31 THEN '城市特困'
<select
id=
"getFivesYearEnjoyStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
ELSE '其他' END ) 'type',
SELECT LEFT(date, 4) 'year', type, SUM(num) 'num' FROM ( SELECT DATE_FORMAT(h.PERMIT_DATE, "%Y-%m") 'date',
SUM( h.SURE_POPULATION ) 'num'
( CASE h.ISCITY
FROM ENBUZ_APPLY_HOME h
WHEN 0 THEN '农村低保'
WHERE h.VP_STATE = 4
WHEN 1 THEN '城市低保'
AND h.ISCITY IN(0, 1)
WHEN 6 THEN '特困供养'
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) > DATE_FORMAT(NOW(), "%Y" ) - 5
WHEN 10 THEN '农村低收入'
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" )
<
= DATE_FORMAT(NOW(), "%Y" )
WHEN 11 THEN '城市低收入'
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
WHEN 21 THEN '住房救助'
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
WHEN 31 THEN '城市特困'
</if>
ELSE '其他' END ) 'type',
GROUP BY
SUM( h.SURE_POPULATION ) 'num'
DATE_FORMAT( h.PERMIT_DATE, "%Y-%m" ),
FROM ENBUZ_APPLY_HOME h
ISCITY) t
WHERE h.VP_STATE = 4
WHERE type IN("城市低保","农村低保")
AND h.ISCITY IN(0, 1)
GROUP BY
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" ) > DATE_FORMAT(NOW(), "%Y" ) - 5
LEFT(date, 4),
AND DATE_FORMAT( h.PERMIT_DATE, "%Y" )
<
= DATE_FORMAT(NOW(), "%Y" )
type
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
</select>
AND h.UNIT_ID LIKE CONCAT(#{subAreaCode}, '%')
</if>
<select
id=
"getPeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
GROUP BY
SELECT
DATE_FORMAT( h.PERMIT_DATE, "%Y-%m" ),
LEFT ( a.area_code, #{size} ) 'code',
ISCITY) t
a.type 'type',
WHERE type IN("城市低保","农村低保")
SUM(a.people_num) 'num'
GROUP BY
FROM city_coutry a
LEFT(date, 4),
WHERE
type
CHAR_LENGTH (LEFT ( a.area_code, #{size} )) = #{size}
</select>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND a.area_code LIKE CONCAT(#{subAreaCode}, '%')
<select
id=
"getPeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
</if>
SELECT
<if
test=
"type != null and type != ''"
>
LEFT ( a.area_code, #{size} ) 'code',
AND a.type = #{type}
a.type 'type',
</if>
SUM(a.people_num) 'num'
GROUP BY
FROM city_coutry a
LEFT ( a.area_code, #{size} ),
WHERE
a.type
CHAR_LENGTH (LEFT ( a.area_code, #{size} )) = #{size}
</select>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND a.area_code LIKE CONCAT(#{subAreaCode}, '%')
<!-- iscity = 1 是城市 0是农村 -->
</if>
<select
id=
"getMonyNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
<if
test=
"type != null and type != ''"
>
SELECT
AND a.type = #{type}
LEFT(p.unit_id, #{size}) 'code',
</if>
p.iscity 'type',
GROUP BY
SUM( p.money ) 'amount'
LEFT ( a.area_code, #{size} ),
FROM
a.type
mon_pay p
</select>
WHERE
p.pay_state = 2
<!-- iscity = 1 是城市 0是农村 -->
AND p.vp_state = 4
<select
id=
"getMonyNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
AND DATE_FORMAT( p.pmonth, "%Y-%m-%d" ) >= '2021-12-01'
SELECT
AND DATE_FORMAT( p.pmonth, "%Y-%m-%d" )
<
= '2021-12-01'
LEFT(p.unit_id, #{size}) 'code',
AND CHAR_LENGTH (LEFT ( p.unit_id, #{size} )) = #{size}
p.iscity 'type',
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
SUM( p.money ) 'amount'
AND p.unit_id LIKE CONCAT(#{subAreaCode}, '%')
FROM
</if>
mon_pay p
<if
test=
"type != null and type != ''"
>
WHERE
AND p.iscity = #{type}
p.pay_state = 2
</if>
AND p.vp_state = 4
GROUP BY
AND DATE_FORMAT( p.pmonth, "%Y-%m-%d" ) >= date_sub(date_sub(date_format(now(),'%y-%m-%d'),interval extract(day from now())-1 day),interval 1 month)
LEFT(p.unit_id, #{size}),
AND DATE_FORMAT( p.pmonth, "%Y-%m-%d" )
<
= date_sub(date_sub(date_format(now(),'%y-%m-%d'),interval extract(day from now())-1 day),interval 1 month)
p.iscity
AND CHAR_LENGTH (LEFT ( p.unit_id, #{size} )) = #{size}
</select>
<if
test=
"subAreaCode != null and subAreaCode != ''"
>
AND p.unit_id LIKE CONCAT(#{subAreaCode}, '%')
</mapper>
</if>
<if
test=
"type != null and type != ''"
>
AND p.iscity = #{type}
</if>
GROUP BY
LEFT(p.unit_id, #{size}),
p.iscity
</select>
<select
id=
"getPeopleNumStats"
resultType=
"com.zq.portal.vo.StatsVo"
>
SELECT
h.type 'type',
SUM(h.people_num) 'num'
FROM
city_coutry h
GROUP BY
type
</select>
<select
id=
"getAppData"
resultType=
"com.zq.portal.entity.AppData"
>
SELECT * FROM app_data
</select>
</mapper>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment