Commit 77f6acb3 by liuguorong93

技术人员序列统计 修改

parent 518a3926
......@@ -122,7 +122,7 @@ export default {
value: res.data.workDogClass[item],
};
}
if (item == "其他工作犬") {
if (item == "普通工作犬") {
this.qzCount.Grade[3] = {
name: item,
value: res.data.workDogClass[item],
......
......@@ -8,16 +8,6 @@
class="dogPh_co_ov"
id="dogPhId"
>
<!-- <div
class="dogPh_co_ov_for"
v-for="(item, index) in dogRankingList"
:key="index"
>
<div class="dogPh_co_ov_for_name">{{ item.name }}</div>
<div class="dogPh_co_ov_for_value">
<span class="dogPh_co_ov_for_value_count">{{ item.count }}</span><span class="dogPh_co_ov_for_value_tou"></span>
</div>
</div> -->
</div>
</div>
</div>
......@@ -28,23 +18,34 @@ import { postRequest } from "@/api/dogView.js";
export default {
data() {
return {
dogRankingList: [],
seriesDatas: [],
};
},
mounted() {
this.setEcharts();
// postRequest("/policeDogScreen/oneworkDogqz").then((res) => {
// if (res.data) {
// for (let item in res.data.一级工作犬犬种排行) {
// this.dogRankingList.push({
// name: item,
// count: res.data.一级工作犬犬种排行[item],
// });
// }
// }
// });
this.getData();
},
methods: {
getData() {
this.seriesDatas = [];
postRequest("/policeDogScreen/selectJwjsxlFlCount").then((res) => {
if (
res.code === 200 &&
res.success &&
res.data &&
res.data.jwjsxlFl &&
res.data.jwjsxlFl.length
) {
let datas = res.data.jwjsxlFl;
datas.forEach((item) => {
this.seriesDatas.push({
value: item.counts,
name: item.name,
});
});
this.setEcharts();
}
});
},
setEcharts() {
let myChart = this.$echarts.init(document.getElementById("dogPhId"));
const colorList = ["#4D88FE", "#50CCCB", "#FFBF3C"];
......@@ -66,6 +67,9 @@ export default {
type: "pie",
top: -30,
radius: "60%",
label: {
show: false,
},
itemStyle: {
normal: {
borderColor: "#fff",
......@@ -75,11 +79,7 @@ export default {
},
},
},
data: [
{ value: 1048, name: "警务技术" },
{ value: 735, name: "执法勤务" },
{ value: 580, name: "综合管理" },
],
data: this.seriesDatas,
},
],
};
......
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