Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fgqyxxlr
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
yaru
fgqyxxlr
Commits
36b95de3
Commit
36b95de3
authored
Sep 10, 2020
by
zhangyuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改首页统计页面,新加统计接口
parent
a00f7559
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
253 additions
and
0 deletions
+253
-0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/HomeStatisticsController.java
+37
-0
ruoyi-admin/src/main/resources/static/js/radialIndicator.js
+0
-0
ruoyi-admin/target/classes/templates/main.html
+0
-0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/OrhonFgqyMapper.java
+12
-0
ruoyi-system/src/main/java/com/ruoyi/system/service/IOrhonFgqyService.java
+4
-0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/OrhonFgqyServiceImpl.java
+28
-0
ruoyi-system/src/main/resources/mapper/system/OrhonFgqyMapper.xml
+86
-0
ruoyi-system/target/classes/mapper/system/OrhonFgqyMapper.xml
+86
-0
No files found.
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/HomeStatisticsController.java
0 → 100644
View file @
36b95de3
package
com
.
ruoyi
.
web
.
controller
.
system
;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
com.ruoyi.system.service.IOrhonFgqyService
;
import
com.ruoyi.system.service.ISysDeptService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
import
java.util.Map
;
/**
* 首页统计
*
* @author ruoyi
*/
@Controller
@RequestMapping
(
"/home/statistics"
)
public
class
HomeStatisticsController
extends
BaseController
{
@Autowired
private
IOrhonFgqyService
orhonFgqyService
;
@PostMapping
(
"/chart"
)
@ResponseBody
public
Object
chart
(){
try
{
return
AjaxResult
.
success
(
orhonFgqyService
.
chart
());
}
catch
(
Exception
e
){
return
AjaxResult
.
error
();
}
}
}
ruoyi-admin/src/main/resources/static/js/radialIndicator.js
0 → 100644
View file @
36b95de3
This diff is collapsed.
Click to expand it.
ruoyi-admin/target/classes/templates/main.html
View file @
36b95de3
This diff is collapsed.
Click to expand it.
ruoyi-system/src/main/java/com/ruoyi/system/mapper/OrhonFgqyMapper.java
View file @
36b95de3
package
com
.
ruoyi
.
system
.
mapper
;
package
com
.
ruoyi
.
system
.
mapper
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
com.ruoyi.system.domain.OrhonFgqy
;
import
com.ruoyi.system.domain.OrhonFgqy
;
/**
/**
...
@@ -62,4 +64,14 @@ public interface OrhonFgqyMapper
...
@@ -62,4 +64,14 @@ public interface OrhonFgqyMapper
public
String
findDzz
();
public
String
findDzz
();
public
String
findQyzs
();
public
String
findQyzs
();
public
List
<
Map
>
selectLineChart
();
List
<
Map
>
selectBarChart
();
List
<
Map
>
selectCurveChart
();
List
<
Map
>
selectPieChart
();
List
<
Map
>
selectRadarChart
();
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/IOrhonFgqyService.java
View file @
36b95de3
package
com
.
ruoyi
.
system
.
service
;
package
com
.
ruoyi
.
system
.
service
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
com.ruoyi.system.domain.OrhonFgqy
;
import
com.ruoyi.system.domain.OrhonFgqy
;
/**
/**
...
@@ -62,4 +64,6 @@ public interface IOrhonFgqyService
...
@@ -62,4 +64,6 @@ public interface IOrhonFgqyService
public
String
findQyzs
();
public
String
findQyzs
();
public
String
findDzz
();
public
String
findDzz
();
Object
chart
();
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/OrhonFgqyServiceImpl.java
View file @
36b95de3
package
com
.
ruoyi
.
system
.
service
.
impl
;
package
com
.
ruoyi
.
system
.
service
.
impl
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.ruoyi.system.mapper.OrhonFgqyMapper
;
import
com.ruoyi.system.mapper.OrhonFgqyMapper
;
...
@@ -101,4 +105,28 @@ public class OrhonFgqyServiceImpl implements com.ruoyi.system.service.IOrhonFgqy
...
@@ -101,4 +105,28 @@ public class OrhonFgqyServiceImpl implements com.ruoyi.system.service.IOrhonFgqy
public
String
findDzz
()
{
public
String
findDzz
()
{
return
orhonFgqyMapper
.
findDzz
();
return
orhonFgqyMapper
.
findDzz
();
}
}
@Override
public
Object
chart
()
{
Map
resultMap
=
new
HashMap
();
try
{
List
<
Map
>
lineChart
=
orhonFgqyMapper
.
selectLineChart
();
resultMap
.
put
(
"lineChart"
,
lineChart
);
List
<
Map
>
barChart
=
orhonFgqyMapper
.
selectBarChart
();
resultMap
.
put
(
"barChart"
,
barChart
);
List
<
Map
>
curveChart
=
orhonFgqyMapper
.
selectCurveChart
();
resultMap
.
put
(
"curveChart"
,
curveChart
);
List
<
Map
>
pieChart
=
orhonFgqyMapper
.
selectPieChart
();
resultMap
.
put
(
"pieChart"
,
pieChart
);
List
<
Map
>
radarChart
=
orhonFgqyMapper
.
selectRadarChart
();
resultMap
.
put
(
"radarChart"
,
radarChart
);
}
catch
(
Exception
e
){
return
AjaxResult
.
error
(
e
+
""
);
}
return
AjaxResult
.
success
(
resultMap
);
}
}
}
ruoyi-system/src/main/resources/mapper/system/OrhonFgqyMapper.xml
View file @
36b95de3
...
@@ -384,4 +384,90 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -384,4 +384,90 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</foreach>
</foreach>
</delete>
</delete>
<!-- 市直、各旗区非公企业分布折线统计-->
<select
id=
"selectLineChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
count( off.id ) value
FROM
sys_dict_data d
LEFT JOIN orhon_fgqy off ON off.dept_id = d.dict_value
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区社会组织分布折线统计-->
<select
id=
"selectBarChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
count( oz.id ) value
FROM
sys_dict_data d
LEFT JOIN orhon_shzz oz ON oz.dept_id = d.dict_value
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区社会组织分布折线统计-->
<select
id=
"selectCurveChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 全市非公企业与社会组织党委、党总支、党支部、联合党支部数量分布统计-->
<select
id=
"selectPieChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区非公企业与社会组织统计-->
<select
id=
"selectRadarChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
</mapper>
</mapper>
ruoyi-system/target/classes/mapper/system/OrhonFgqyMapper.xml
View file @
36b95de3
...
@@ -384,4 +384,90 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -384,4 +384,90 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</foreach>
</foreach>
</delete>
</delete>
<!-- 市直、各旗区非公企业分布折线统计-->
<select
id=
"selectLineChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
count( off.id ) value
FROM
sys_dict_data d
LEFT JOIN orhon_fgqy off ON off.dept_id = d.dict_value
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区社会组织分布折线统计-->
<select
id=
"selectBarChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
count( oz.id ) value
FROM
sys_dict_data d
LEFT JOIN orhon_shzz oz ON oz.dept_id = d.dict_value
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区社会组织分布折线统计-->
<select
id=
"selectCurveChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 全市非公企业与社会组织党委、党总支、党支部、联合党支部数量分布统计-->
<select
id=
"selectPieChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
<!-- 市直、各旗区非公企业与社会组织统计-->
<select
id=
"selectRadarChart"
parameterType=
"java.util.List"
resultType=
"java.util.Map"
>
SELECT
d.dict_label name,
(select count(0) from orhon_shzz where dept_id = d.dict_value) shzzValue,
(select count(0) from orhon_fgqy where dept_id = d.dict_value) fgqyValue
FROM
sys_dict_data d
WHERE
d.dict_type = 'orhon_qyfl'
AND d.STATUS = '0'
GROUP BY
d.dict_code
ORDER BY
d.dict_sort
</select>
</mapper>
</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