Commit cedaec7b by 苏咏卓

接口对接

parent 946b4f93
......@@ -23,6 +23,8 @@ export const getAreaUnderSoorganStatsList = data => {
})
}
getAreaNursingStatsList
/** -------------------- 婚姻 -------------------- **/
//获取地区结婚离婚人数列表
export const getAreaUnderMarriageStatsList = data => {
......@@ -151,6 +153,17 @@ export const getAgencyUnderChildStatsList = data => {
})
}
/** -------------------- 殡葬 -------------------- **/
//统计该区域的殡葬火化量
export const getCremationStats = data => {
return request({
url: 'portal/admin/stats/getCremationStats',
method: 'POST',
data
})
}
/** -------------------- 两项补贴 -------------------- **/
//获取区域残疾发放统计
export const getAreaDisabledIssueStats = data => {
......
......@@ -103,7 +103,7 @@
<script>
import * as echarts from "echarts";
import { getSoorganStats,getAreaUnderSoorganStatsList,getAreaNursingStatsList } from "@/api/unified/unified";
import { getSoorganStats,getAreaUnderSoorganStatsList,getAreaNursingStatsList,getAgencyPercentageStats } from "@/api/unified/unified";
export default {
data() {
return {
......@@ -172,13 +172,16 @@ export default {
],
soorganStats: {},
areaUnderSoorganStatsList:{},
areaNursingStatsList:{}
areaNursingStatsList:{},
agencyPercentageStats:[],
welfareHomeName: [],
};
},
created() {
this.getSoorganStatsFun();
this.getAreaUnderSoorganStatsListFun()
this.getAreaNursingStatsListFun()
this.getAgencyPercentageStatsFun()
},
methods: {
getSoorganStatsFun() {
......@@ -202,6 +205,18 @@ export default {
})
},
getAgencyPercentageStatsFun() {
getAgencyPercentageStats({}).then((res) => {
console.log(res, "获取区域机构占比");
this.agencyPercentageStats = res.data;
res.data.forEach((item) => {
this.welfareHomeName.push(item.name);
});
console.log(this.welfareHomeName);
this.childrenFun();
});
},
//社会组织柱形图
sociologyFun() {
var chartDom = document.getElementById("sociology");
......@@ -526,23 +541,18 @@ export default {
trigger: "item",
formatter: "{a} <br/>{b} : {c} ({d}%)",
},
legend: {
bottom: 10,
left: "center",
data: ["西凉", "益州", "兖州", "荆州"],
},
// legend: {
// bottom: 10,
// left: "center",
// data: this.welfareHomeName,
// },
series: [
{
type: "pie",
radius: "65%",
center: ["50%", "50%"],
selectedMode: "single",
data: [
{ value: 735, name: "荆州" },
{ value: 510, name: "兖州" },
{ value: 434, name: "益州" },
{ value: 335, name: "西凉" },
],
data: this.agencyPercentageStats,
emphasis: {
itemStyle: {
shadowBlur: 10,
......@@ -561,7 +571,6 @@ export default {
setTimeout(() => {
this.sociologyFun();
this.pensionFun();
this.childrenFun();
}, 1000);
},
};
......
......@@ -57,8 +57,8 @@
</el-col>
<el-col :span="12">
<div class="rescue">
<div class="size24">1000</div>
<div class="size16">事实无人领养</div>
<div class="size24Info">1000</div>
<div class="size16Info">事实无人领养</div>
</div>
</el-col>
</el-row>
......@@ -194,7 +194,7 @@ export default {
})
},
//儿童机构柱形图
//儿童福利统计
orphanFun() {
var chartDom = document.getElementById("orphan");
var myChart = echarts.init(chartDom, "dark");
......@@ -243,7 +243,7 @@ export default {
},
yAxis: {
type: "category",
data: ["巴西", "印尼", "美国", "印度", "桂林", "南宁"],
data: this.agencyChildStatsList.areaList,
axisLabel: {
textStyle: {
color: "#FFFFFF",
......@@ -267,7 +267,7 @@ export default {
{
name: "孤儿",
type: "bar",
data: [18203, 23489, 29034, 104970, 131744, 63023],
data: this.agencyChildStatsList.orphanNumList,
itemStyle: {
normal: {
color: "#3167ff",
......@@ -280,12 +280,12 @@ export default {
{
name: "事实无人领养",
type: "bar",
data: [19325, 23438, 31000, 121594, 134141, 68180],
data: this.agencyChildStatsList.factUnadoptedNumList,
itemStyle: {
normal: {
color: "#ff4444",
color: "#C1BDBD",
lineStyle: {
color: "#ff4444",
color: "#C1BDBD",
},
},
},
......@@ -791,6 +791,14 @@ export default {
.size16 {
font-size: 16;
}
.size24Info {
font-size: 24px;
color: #C1BDBD;
}
.size16Info {
font-size: 16;
color: #C1BDBD;
}
.rescue {
text-align: center;
color: #fff;
......
......@@ -12,7 +12,7 @@
<div class="text">火化总数</div>
<div>
<div class="borderBottom"></div>
<div class="textNum">123456</div>
<div class="textNum">{{cremationStats.cremationSum}}</div>
<div class="borderTop"></div>
</div>
<div class="text"></div>
......@@ -21,7 +21,7 @@
<div class="texts">火化率</div>
<div>
<div class="borderBottom"></div>
<div class="textNums">88</div>
<div class="textNums">{{cremationStats.cremationRate}}</div>
<div class="borderTop"></div>
</div>
<div class="text">%</div>
......@@ -100,6 +100,7 @@
<script>
import * as echarts from "echarts";
import { getCremationStats } from "@/api/unified/unified";
export default {
data() {
return {
......@@ -117,10 +118,20 @@ export default {
dates:"2020-12-2"
},
],
cremationStats:{}
};
},
created() {},
created() {
this.getCremationStatsFun()
},
methods: {
getCremationStatsFun(){
getCremationStats({}).then(res =>{
console.log(res,'统计该区域的殡葬火化量')
this.cremationStats = res.data
})
},
//机构占比
proportionFun() {
var chartDom = document.getElementById("proportion");
......
......@@ -12,7 +12,7 @@
<div class="text">社会组织总数</div>
<div>
<div class="borderBottom"></div>
<div class="yellowNum">{{soorganStats.totalNum}}</div>
<div class="yellowNum">{{ soorganStats.totalNum }}</div>
<div class="borderTop"></div>
</div>
<div class="text"></div>
......@@ -21,7 +21,7 @@
<div class="textLeft">社团</div>
<div>
<div class="borderBottom"></div>
<div class="textNum">{{soorganStats.leagueNum}}</div>
<div class="textNum">{{ soorganStats.leagueNum }}</div>
<div class="borderTop"></div>
</div>
<div class="text"></div>
......@@ -30,7 +30,7 @@
<div class="textLeft">民非</div>
<div>
<div class="borderBottom"></div>
<div class="textNum">{{soorganStats.minFeiNum}}</div>
<div class="textNum">{{ soorganStats.minFeiNum }}</div>
<div class="borderTop"></div>
</div>
<div class="text"></div>
......@@ -39,7 +39,7 @@
<div class="textLefts">基金会</div>
<div>
<div class="borderBottom"></div>
<div class="textNum">{{soorganStats.foundationNum}}</div>
<div class="textNum">{{ soorganStats.foundationNum }}</div>
<div class="borderTop"></div>
</div>
<div class="text"></div>
......@@ -75,7 +75,7 @@
<el-row :gutter="20">
<el-col :span="18" :offset="6">
<div class="classification">
<div class="classificationText">社团:</div>
<div class="classificationText">社团:</div>
<div class="numText">{{ soorganStats.leagueNum }}</div>
</div>
</el-col>
......@@ -88,12 +88,14 @@
<el-col :span="18" :offset="6">
<div class="classification">
<div class="classificationText">基金会:</div>
<div class="numText">{{ soorganStats.foundationNum }}</div>
<div class="numText">
{{ soorganStats.foundationNum }}
</div>
</div>
</el-col>
</el-row>
</el-col>
<el-col :span="16">
<el-col :span="18">
<div id="annualStatistics" class="annualStatistics"></div>
</el-col>
</el-row>
......@@ -117,7 +119,11 @@
</el-table-column>
<el-table-column prop="name" label="地区" align="center">
</el-table-column>
<el-table-column prop="address" label="组织名称/代码" align="center">
<el-table-column
prop="address"
label="组织名称/代码"
align="center"
>
</el-table-column>
</el-table>
</div>
......@@ -135,7 +141,11 @@
<script>
import * as echarts from "echarts";
import { getSoorganStats,getSoorganPercentageStats } from "@/api/unified/unified";
import {
getSoorganStats,
getSoorganPercentageStats,
getAreaUnderSoorganStatsList,
} from "@/api/unified/unified";
export default {
data() {
return {
......@@ -151,35 +161,42 @@ export default {
address: "上海市普陀区金沙江路 1517 弄",
},
],
soorganStats:{},
SoorganPercentageStats:[],
placeNames:[],
soorganStats:{}
soorganStats: {},
SoorganPercentageStats: [],
placeNames: [],
soorganStats: {},
areaUnderSoorganStatsList: {},
};
},
created() {
this.getSoorganStatsFun()
this.getSoorganPercentageStatsFun()
this.getSoorganStatsFun();
this.getSoorganPercentageStatsFun();
this.getAreaUnderSoorganStatsListFun();
},
methods: {
getSoorganStatsFun(){
getSoorganStats({}).then(res =>{
console.log(res,'获取社会机构统计')
this.soorganStats = res.data
})
getSoorganStatsFun() {
getSoorganStats({}).then((res) => {
console.log(res, "获取社会机构统计");
this.soorganStats = res.data;
});
},
getSoorganPercentageStatsFun(){
getSoorganPercentageStats({}).then(res =>{
console.log(res.data,'获取社会机构区域占比统计')
this.SoorganPercentageStats = res.data
res.data.forEach(item => {
this.placeNames.push(
item.name
)
getSoorganPercentageStatsFun() {
getSoorganPercentageStats({}).then((res) => {
console.log(res.data, "获取社会机构区域占比统计");
this.SoorganPercentageStats = res.data;
res.data.forEach((item) => {
this.placeNames.push(item.name);
});
console.log(this.placeNames);
})
});
},
getAreaUnderSoorganStatsListFun() {
getAreaUnderSoorganStatsList({}).then((res) => {
console.log(res, "获取地区下面社会机构统计列表");
this.areaUnderSoorganStatsList = res.data;
});
},
//机构占比
......@@ -329,7 +346,7 @@ export default {
},
},
legend: {
data: ["Forest", "Steppe", "Desert", "Wetland"],
data: ["社团", "民非", "基金会"],
},
toolbox: {
show: true,
......@@ -341,7 +358,7 @@ export default {
{
type: "category",
axisTick: { show: false },
data: ["2012", "2013", "2014", "2015", "2016"],
data: this.areaUnderSoorganStatsList.areaList,
axisLabel: {
textStyle: {
color: "#FFFFFF",
......@@ -387,14 +404,14 @@ export default {
],
series: [
{
name: "Forest",
name: "社团",
type: "bar",
barGap: 0,
label: labelOption,
emphasis: {
focus: "series",
},
data: [320, 332, 301, 334, 390],
data: this.areaUnderSoorganStatsList.foundationNumList,
itemStyle: {
normal: {
color: "#3167ff",
......@@ -405,13 +422,13 @@ export default {
},
},
{
name: "Steppe",
name: "民非",
type: "bar",
label: labelOption,
emphasis: {
focus: "series",
},
data: [220, 182, 191, 234, 290],
data: this.areaUnderSoorganStatsList.leagueNumList,
itemStyle: {
normal: {
color: "#ff4444",
......@@ -421,6 +438,23 @@ export default {
},
},
},
{
name: "基金会",
type: "bar",
label: labelOption,
emphasis: {
focus: "series",
},
data: this.areaUnderSoorganStatsList.minFeiNumList,
itemStyle: {
normal: {
color: "#FAC858",
lineStyle: {
color: "#FAC858",
},
},
},
},
],
};
......@@ -515,7 +549,7 @@ export default {
.numText {
font-size: 20px;
color: #3A92F1;
color: #3a92f1;
text-align: center;
}
......
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