8 changed files with 913 additions and 45 deletions
@ -0,0 +1,200 @@ |
|||
<template> |
|||
<div class="m-zyqd"> |
|||
|
|||
<div class="pieMain"> |
|||
<div class="pie"><screen-echarts-frame @myChartMethod="pieInitOk" ref="pieChart"></screen-echarts-frame></div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import screenEchartsFrame from '@/views/dataBoard/cpts/screen-echarts-frame/index'; |
|||
import { pieOption } from './fwqdPieOption.js'; |
|||
import { requestPostBi } from '@/js/dai/request-bipass'; |
|||
export default { |
|||
props: { |
|||
orgId: { |
|||
type: String, |
|||
default: '' |
|||
} |
|||
}, |
|||
data() { |
|||
return { |
|||
showNoData: false, |
|||
timer: null, |
|||
pieChart: '', |
|||
pieOption: {}, |
|||
pieInitState: false, |
|||
pieData: [], |
|||
tabList: [ |
|||
'人资源', |
|||
'物资源', |
|||
'场所资源' |
|||
// "下级人口分布", |
|||
], |
|||
currentTab: '人资源', |
|||
info: { |
|||
male_count: 0, |
|||
female_count: 0, |
|||
resi_y_house_y_count: 0, |
|||
resi_y_house_n_count: 0, |
|||
resi_n_house_y_count: 0, |
|||
primary_count: 0, |
|||
junior_high_count: 0, |
|||
second_speci_count: 0, |
|||
high_school_count: 0, |
|||
junior_college_count: 0, |
|||
undergrad_count: 0, |
|||
master_count: 0, |
|||
doctor_count: 0, |
|||
local_count: 0, |
|||
field_count: 0, |
|||
age50_count: 0, |
|||
age5059_count: 0, |
|||
age6069_count: 0, |
|||
age7079_count: 0, |
|||
age80_count: 0, |
|||
culture_count: 0, |
|||
committee_count: 0, |
|||
capable_count: 0, |
|||
friend_count: 0, |
|||
agent_count: 0, |
|||
mediator_count: 0, |
|||
collector_count: 0, |
|||
security_count: 0, |
|||
party_mem_count: 0 |
|||
} |
|||
}; |
|||
}, |
|||
components: { |
|||
screenEchartsFrame |
|||
}, |
|||
mounted() { |
|||
this.init(); |
|||
}, |
|||
watch: { |
|||
currentTab() { |
|||
this.setPieData(); |
|||
}, |
|||
orgId() { |
|||
this.init(); |
|||
} |
|||
}, |
|||
methods: { |
|||
async init() { |
|||
await this.getInfo(); |
|||
this.getPie(); |
|||
}, |
|||
handleClickItem(item) { |
|||
// const { type, name } = item; |
|||
// this.$router.push({ |
|||
// path: '/dataBoard/renfang/resi-analyze', |
|||
// query: { |
|||
// org_id: this.orgId, |
|||
// type, |
|||
// type_category: this.currentTab, |
|||
// type_name: name |
|||
// } |
|||
// }); |
|||
}, |
|||
// 获取房屋总数等 |
|||
async getInfo() { |
|||
let url = ''; |
|||
if (this.currentTab == '人资源') { |
|||
url = 'people_res_view'; |
|||
} else if (this.currentTab == '物资源') { |
|||
url = 'goods_res_view'; |
|||
} else { |
|||
url = 'people_res_view'; |
|||
} |
|||
|
|||
this.$refs.pieChart.showLoading(); |
|||
const { data, code, msg } = await requestPostBi( |
|||
url, |
|||
{ |
|||
queryParam: { |
|||
org_id: this.orgId |
|||
} |
|||
}, |
|||
{ |
|||
// mockId: 60041615, |
|||
} |
|||
); |
|||
this.$refs.pieChart.hideLoading(); |
|||
if (code === 0) { |
|||
if (data && Array.isArray(data) && data.length > 0) { |
|||
let info = data[0]; |
|||
this.info = { |
|||
...this.info, |
|||
...info |
|||
}; |
|||
} |
|||
} else { |
|||
this.$message.error(msg); |
|||
} |
|||
}, |
|||
selItem(selItem, selIndex) { |
|||
this.tabList.forEach((element, index) => { |
|||
if (index === selIndex) { |
|||
element.sel = true; |
|||
} else { |
|||
element.sel = false; |
|||
} |
|||
}); |
|||
}, |
|||
pieInitOk() { |
|||
this.pieInitState = true; |
|||
}, |
|||
getPie() { |
|||
if (this.pieInitState) { |
|||
this.setPieData(); |
|||
} else { |
|||
setTimeout(() => { |
|||
this.getPie(); |
|||
}, 500); |
|||
} |
|||
}, |
|||
setPieData() { |
|||
const { currentTab, info } = this; |
|||
|
|||
let data = [ |
|||
{ |
|||
name: '江', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
}, |
|||
{ |
|||
name: '平', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 63 |
|||
}, |
|||
{ |
|||
name: '究', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 66 |
|||
}, |
|||
{ |
|||
name: '布', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
} |
|||
]; |
|||
data = JSON.parse(JSON.stringify(data).replace(/count/g, 'value')); |
|||
console.log('data', data); |
|||
this.pieData = data; |
|||
|
|||
this.iniPieChart(); |
|||
}, |
|||
// 获取饼状图 |
|||
async iniPieChart() { |
|||
this.$refs.pieChart.clear(); |
|||
// 获取pieChart配置 |
|||
this.pieOption = pieOption(); |
|||
this.pieOption.series[0].name = this.currentTab; |
|||
this.pieOption.series[0].data = this.pieData; |
|||
this.$refs.pieChart.setOption(this.pieOption); |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style lang="scss" src="@/assets/scss/dataBoard/renfang/index.scss" scoped></style> |
|||
@ -0,0 +1,173 @@ |
|||
<template> |
|||
<div class="m-sqpj"> |
|||
<el-row :gutter="16"> |
|||
<el-col :span="12"> |
|||
<div class="kuangkuang"> |
|||
<h3>公共服务数量</h3> |
|||
<h2>256</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<div class="kuangkuang"> |
|||
<h3>指派服务数量</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
</el-row> |
|||
<div class="tablist"> |
|||
<div v-for="item in tabList" :key="item" :class="['item', { 'item-sel': currentTab == item }]" @click="currentTab = item">{{ item }}</div> |
|||
</div> |
|||
<div> |
|||
<div class="linecharts" v-if="resiCategoryData.length > 0"> |
|||
<div class="item" @click="toResiClassPage(item.code, item.name)" :key="item.code + index" v-for="(item, index) in resiCategoryData"> |
|||
<div>{{ ('0' + (index + 1)).substr(-2) }}.</div> |
|||
<div class="item-name">{{ item.name }}</div> |
|||
<div class="item-count"> |
|||
<b>{{ item.count }}</b> |
|||
人 |
|||
</div> |
|||
<div class="item-progress"><b :style="{ width: item.ratio + '%' }"></b></div> |
|||
<!-- <div class="item-per"> |
|||
<span>较上月</span> |
|||
<img v-if="item.growth >= 0" src="~@/assets/images/shuju/renfang/index/up.png" /> |
|||
<img v-else src="~@/assets/images/shuju/renfang/index/down.png" /> |
|||
<b>{{ item.growthAbs }}</b> |
|||
<span>人</span> |
|||
</div> --> |
|||
</div> |
|||
</div> |
|||
<div class="empty" v-else><img src="~@/assets/images/shuju/renfang/index/empty.png" /></div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import screenEchartsFrame from '@/views/dataBoard/cpts/screen-echarts-frame/index'; |
|||
import { requestPostBi } from '@/js/dai/request-bipass'; |
|||
export default { |
|||
props: { |
|||
orgId: { |
|||
type: String, |
|||
default: '' |
|||
} |
|||
}, |
|||
data() { |
|||
return { |
|||
resiCategoryData: [], |
|||
showNoData: false, |
|||
timer: null, |
|||
pieChart: '', |
|||
pieOption: {}, |
|||
pieInitState: false, |
|||
pieData: [], |
|||
tabList: ['服务次数排名', '服务人数排名'], |
|||
currentTab: '服务次数排名', |
|||
info: { |
|||
male_count: 0, |
|||
female_count: 0, |
|||
resi_y_house_y_count: 0, |
|||
resi_y_house_n_count: 0, |
|||
resi_n_house_y_count: 0, |
|||
primary_count: 0, |
|||
junior_high_count: 0, |
|||
second_speci_count: 0, |
|||
high_school_count: 0, |
|||
junior_college_count: 0, |
|||
undergrad_count: 0, |
|||
master_count: 0, |
|||
doctor_count: 0, |
|||
local_count: 0, |
|||
field_count: 0, |
|||
age50_count: 0, |
|||
age5059_count: 0, |
|||
age6069_count: 0, |
|||
age7079_count: 0, |
|||
age80_count: 0, |
|||
culture_count: 0, |
|||
committee_count: 0, |
|||
capable_count: 0, |
|||
friend_count: 0, |
|||
agent_count: 0, |
|||
mediator_count: 0, |
|||
collector_count: 0, |
|||
security_count: 0, |
|||
party_mem_count: 0 |
|||
} |
|||
}; |
|||
}, |
|||
components: { |
|||
screenEchartsFrame |
|||
}, |
|||
mounted() { |
|||
this.init(); |
|||
}, |
|||
watch: { |
|||
currentTab() { |
|||
this.getResiCategoryData(); |
|||
}, |
|||
orgId() { |
|||
this.init(); |
|||
} |
|||
}, |
|||
methods: { |
|||
async init() { |
|||
this.getResiCategoryData(); |
|||
}, |
|||
handleClickItem(item) { |
|||
// const { type, name } = item; |
|||
// this.$router.push({ |
|||
// path: '/dataBoard/renfang/resi-analyze', |
|||
// query: { |
|||
// org_id: this.orgId, |
|||
// type, |
|||
// type_category: this.currentTab, |
|||
// type_name: name |
|||
// } |
|||
// }); |
|||
}, |
|||
selItem(selItem, selIndex) { |
|||
this.tabList.forEach((element, index) => { |
|||
if (index === selIndex) { |
|||
element.sel = true; |
|||
} else { |
|||
element.sel = false; |
|||
} |
|||
}); |
|||
}, |
|||
async getResiCategoryData() { |
|||
let url = ''; |
|||
if (this.currentTab == '服务次数排名') { |
|||
url = 'self_need_view'; |
|||
} else if (this.currentTab == '服务人数排名') { |
|||
url = 'attention_eval_view'; |
|||
} |
|||
|
|||
const { data, code, msg } = await requestPostBi( |
|||
url, |
|||
{ |
|||
queryParam: { |
|||
org_id: this.orgId |
|||
} |
|||
}, |
|||
{ |
|||
// mockId: 60031937, |
|||
} |
|||
); |
|||
if (code === 0) { |
|||
this.resiCategoryData = data.map(item => { |
|||
return { |
|||
code: item.label_id, |
|||
name: item.label, |
|||
count: item.count, |
|||
ratio: item.ratio, |
|||
growth: item.growth, |
|||
growthAbs: Math.abs(item.growth) |
|||
}; |
|||
}); |
|||
} else { |
|||
this.$message.error(msg); |
|||
} |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
<style lang="scss" src="@/assets/scss/dataBoard/renfang/index.scss" scoped></style> |
|||
@ -0,0 +1,225 @@ |
|||
<template> |
|||
<div class="m-zyqd"> |
|||
<el-row :gutter="16"> |
|||
<el-col :span="6"> |
|||
<div class="kuangkuang"> |
|||
<h3>个性服务数量</h3> |
|||
<h2>256</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="6"> |
|||
<div class="kuangkuang"> |
|||
<h3>完成服务数量</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="6"> |
|||
<div class="kuangkuang"> |
|||
<h3>服务完成率</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="6"> |
|||
<div class="kuangkuang"> |
|||
<h3>服务满意度</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
</el-row> |
|||
<div class="pieMain"> |
|||
<div class="pie"><screen-echarts-frame @myChartMethod="pieInitOk" ref="pieChart"></screen-echarts-frame></div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import screenEchartsFrame from '@/views/dataBoard/cpts/screen-echarts-frame/index'; |
|||
import { pieOption } from './fwBarOption.js'; |
|||
import { requestPostBi } from '@/js/dai/request-bipass'; |
|||
export default { |
|||
props: { |
|||
orgId: { |
|||
type: String, |
|||
default: '' |
|||
} |
|||
}, |
|||
data() { |
|||
return { |
|||
showNoData: false, |
|||
timer: null, |
|||
pieChart: '', |
|||
pieOption: {}, |
|||
pieInitState: false, |
|||
pieData: [], |
|||
tabList: [ |
|||
'人资源', |
|||
'物资源', |
|||
'场所资源' |
|||
// "下级人口分布", |
|||
], |
|||
currentTab: '人资源', |
|||
info: { |
|||
male_count: 0, |
|||
female_count: 0, |
|||
resi_y_house_y_count: 0, |
|||
resi_y_house_n_count: 0, |
|||
resi_n_house_y_count: 0, |
|||
primary_count: 0, |
|||
junior_high_count: 0, |
|||
second_speci_count: 0, |
|||
high_school_count: 0, |
|||
junior_college_count: 0, |
|||
undergrad_count: 0, |
|||
master_count: 0, |
|||
doctor_count: 0, |
|||
local_count: 0, |
|||
field_count: 0, |
|||
age50_count: 0, |
|||
age5059_count: 0, |
|||
age6069_count: 0, |
|||
age7079_count: 0, |
|||
age80_count: 0, |
|||
culture_count: 0, |
|||
committee_count: 0, |
|||
capable_count: 0, |
|||
friend_count: 0, |
|||
agent_count: 0, |
|||
mediator_count: 0, |
|||
collector_count: 0, |
|||
security_count: 0, |
|||
party_mem_count: 0 |
|||
} |
|||
}; |
|||
}, |
|||
components: { |
|||
screenEchartsFrame |
|||
}, |
|||
mounted() { |
|||
this.init(); |
|||
}, |
|||
watch: { |
|||
currentTab() { |
|||
this.setPieData(); |
|||
}, |
|||
orgId() { |
|||
this.init(); |
|||
} |
|||
}, |
|||
methods: { |
|||
async init() { |
|||
await this.getInfo(); |
|||
this.getPie(); |
|||
}, |
|||
handleClickItem(item) { |
|||
// const { type, name } = item; |
|||
// this.$router.push({ |
|||
// path: '/dataBoard/renfang/resi-analyze', |
|||
// query: { |
|||
// org_id: this.orgId, |
|||
// type, |
|||
// type_category: this.currentTab, |
|||
// type_name: name |
|||
// } |
|||
// }); |
|||
}, |
|||
// 获取房屋总数等 |
|||
async getInfo() { |
|||
let url = ''; |
|||
if (this.currentTab == '人资源') { |
|||
url = 'people_res_view'; |
|||
} else if (this.currentTab == '物资源') { |
|||
url = 'goods_res_view'; |
|||
} else { |
|||
url = 'people_res_view'; |
|||
} |
|||
|
|||
this.$refs.pieChart.showLoading(); |
|||
const { data, code, msg } = await requestPostBi( |
|||
url, |
|||
{ |
|||
queryParam: { |
|||
org_id: this.orgId |
|||
} |
|||
}, |
|||
{ |
|||
// mockId: 60041615, |
|||
} |
|||
); |
|||
this.$refs.pieChart.hideLoading(); |
|||
if (code === 0) { |
|||
if (data && Array.isArray(data) && data.length > 0) { |
|||
let info = data[0]; |
|||
this.info = { |
|||
...this.info, |
|||
...info |
|||
}; |
|||
} |
|||
} else { |
|||
this.$message.error(msg); |
|||
} |
|||
}, |
|||
selItem(selItem, selIndex) { |
|||
this.tabList.forEach((element, index) => { |
|||
if (index === selIndex) { |
|||
element.sel = true; |
|||
} else { |
|||
element.sel = false; |
|||
} |
|||
}); |
|||
}, |
|||
pieInitOk() { |
|||
this.pieInitState = true; |
|||
}, |
|||
getPie() { |
|||
if (this.pieInitState) { |
|||
this.setPieData(); |
|||
} else { |
|||
setTimeout(() => { |
|||
this.getPie(); |
|||
}, 500); |
|||
} |
|||
}, |
|||
setPieData() { |
|||
const { currentTab, info } = this; |
|||
|
|||
let data = [ |
|||
{ |
|||
name: '江', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
}, |
|||
{ |
|||
name: '平', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 63 |
|||
}, |
|||
{ |
|||
name: '究', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 66 |
|||
}, |
|||
{ |
|||
name: '布', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
} |
|||
]; |
|||
data = JSON.parse(JSON.stringify(data).replace(/count/g, 'value')); |
|||
console.log('data', data); |
|||
this.pieData = data; |
|||
|
|||
this.iniPieChart(); |
|||
}, |
|||
// 获取饼状图 |
|||
async iniPieChart() { |
|||
this.$refs.pieChart.clear(); |
|||
// 获取pieChart配置 |
|||
this.pieOption = pieOption(); |
|||
this.pieOption.series[0].name = this.currentTab; |
|||
this.pieOption.series[0].data = this.pieData; |
|||
this.$refs.pieChart.setOption(this.pieOption); |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style lang="scss" src="@/assets/scss/dataBoard/renfang/index.scss" scoped></style> |
|||
@ -0,0 +1,219 @@ |
|||
<template> |
|||
<div class="m-zyqd"> |
|||
<el-row :gutter="16"> |
|||
<el-col :span="8"> |
|||
<div class="kuangkuang"> |
|||
<h3>发布政策数</h3> |
|||
<h2>256</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<div class="kuangkuang"> |
|||
<h3>指派服务数</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<div class="kuangkuang"> |
|||
<h3>政策找人数</h3> |
|||
<h2>2545</h2> |
|||
</div> |
|||
</el-col> |
|||
</el-row> |
|||
<div class="pieMain"> |
|||
<div class="pie"><screen-echarts-frame @myChartMethod="pieInitOk" ref="pieChart"></screen-echarts-frame></div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import screenEchartsFrame from '@/views/dataBoard/cpts/screen-echarts-frame/index'; |
|||
import { pieOption } from './fwBarOption.js'; |
|||
import { requestPostBi } from '@/js/dai/request-bipass'; |
|||
export default { |
|||
props: { |
|||
orgId: { |
|||
type: String, |
|||
default: '' |
|||
} |
|||
}, |
|||
data() { |
|||
return { |
|||
showNoData: false, |
|||
timer: null, |
|||
pieChart: '', |
|||
pieOption: {}, |
|||
pieInitState: false, |
|||
pieData: [], |
|||
tabList: [ |
|||
'人资源', |
|||
'物资源', |
|||
'场所资源' |
|||
// "下级人口分布", |
|||
], |
|||
currentTab: '人资源', |
|||
info: { |
|||
male_count: 0, |
|||
female_count: 0, |
|||
resi_y_house_y_count: 0, |
|||
resi_y_house_n_count: 0, |
|||
resi_n_house_y_count: 0, |
|||
primary_count: 0, |
|||
junior_high_count: 0, |
|||
second_speci_count: 0, |
|||
high_school_count: 0, |
|||
junior_college_count: 0, |
|||
undergrad_count: 0, |
|||
master_count: 0, |
|||
doctor_count: 0, |
|||
local_count: 0, |
|||
field_count: 0, |
|||
age50_count: 0, |
|||
age5059_count: 0, |
|||
age6069_count: 0, |
|||
age7079_count: 0, |
|||
age80_count: 0, |
|||
culture_count: 0, |
|||
committee_count: 0, |
|||
capable_count: 0, |
|||
friend_count: 0, |
|||
agent_count: 0, |
|||
mediator_count: 0, |
|||
collector_count: 0, |
|||
security_count: 0, |
|||
party_mem_count: 0 |
|||
} |
|||
}; |
|||
}, |
|||
components: { |
|||
screenEchartsFrame |
|||
}, |
|||
mounted() { |
|||
this.init(); |
|||
}, |
|||
watch: { |
|||
currentTab() { |
|||
this.setPieData(); |
|||
}, |
|||
orgId() { |
|||
this.init(); |
|||
} |
|||
}, |
|||
methods: { |
|||
async init() { |
|||
await this.getInfo(); |
|||
this.getPie(); |
|||
}, |
|||
handleClickItem(item) { |
|||
// const { type, name } = item; |
|||
// this.$router.push({ |
|||
// path: '/dataBoard/renfang/resi-analyze', |
|||
// query: { |
|||
// org_id: this.orgId, |
|||
// type, |
|||
// type_category: this.currentTab, |
|||
// type_name: name |
|||
// } |
|||
// }); |
|||
}, |
|||
// 获取房屋总数等 |
|||
async getInfo() { |
|||
let url = ''; |
|||
if (this.currentTab == '人资源') { |
|||
url = 'people_res_view'; |
|||
} else if (this.currentTab == '物资源') { |
|||
url = 'goods_res_view'; |
|||
} else { |
|||
url = 'people_res_view'; |
|||
} |
|||
|
|||
this.$refs.pieChart.showLoading(); |
|||
const { data, code, msg } = await requestPostBi( |
|||
url, |
|||
{ |
|||
queryParam: { |
|||
org_id: this.orgId |
|||
} |
|||
}, |
|||
{ |
|||
// mockId: 60041615, |
|||
} |
|||
); |
|||
this.$refs.pieChart.hideLoading(); |
|||
if (code === 0) { |
|||
if (data && Array.isArray(data) && data.length > 0) { |
|||
let info = data[0]; |
|||
this.info = { |
|||
...this.info, |
|||
...info |
|||
}; |
|||
} |
|||
} else { |
|||
this.$message.error(msg); |
|||
} |
|||
}, |
|||
selItem(selItem, selIndex) { |
|||
this.tabList.forEach((element, index) => { |
|||
if (index === selIndex) { |
|||
element.sel = true; |
|||
} else { |
|||
element.sel = false; |
|||
} |
|||
}); |
|||
}, |
|||
pieInitOk() { |
|||
this.pieInitState = true; |
|||
}, |
|||
getPie() { |
|||
if (this.pieInitState) { |
|||
this.setPieData(); |
|||
} else { |
|||
setTimeout(() => { |
|||
this.getPie(); |
|||
}, 500); |
|||
} |
|||
}, |
|||
setPieData() { |
|||
const { currentTab, info } = this; |
|||
|
|||
let data = [ |
|||
{ |
|||
name: '江', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
}, |
|||
{ |
|||
name: '平', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 63 |
|||
}, |
|||
{ |
|||
name: '究', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 66 |
|||
}, |
|||
{ |
|||
name: '布', |
|||
org_id: '7b6f9a9f9f38d5f9fa7ce94a93d6eb28', |
|||
count: 61 |
|||
} |
|||
]; |
|||
data = JSON.parse(JSON.stringify(data).replace(/count/g, 'value')); |
|||
console.log('data', data); |
|||
this.pieData = data; |
|||
|
|||
this.iniPieChart(); |
|||
}, |
|||
// 获取饼状图 |
|||
async iniPieChart() { |
|||
this.$refs.pieChart.clear(); |
|||
// 获取pieChart配置 |
|||
this.pieOption = pieOption(); |
|||
this.pieOption.series[0].name = this.currentTab; |
|||
this.pieOption.series[0].data = this.pieData; |
|||
this.$refs.pieChart.setOption(this.pieOption); |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style lang="scss" src="@/assets/scss/dataBoard/renfang/index.scss" scoped></style> |
|||
Loading…
Reference in new issue