集团统计表

This commit is contained in:
shijing 2023-08-01 16:26:54 +08:00
parent f40e001947
commit e9707e54ee
5 changed files with 427 additions and 394 deletions

View File

@ -495,3 +495,10 @@ export function noNum(id,data) {
data
})
}
export function taskAnalyse(data) {
return request({
url: '/supervision/analyse/group_by_dept/',
method: 'post',
data
})
}

View File

@ -284,7 +284,7 @@ export const asyncRoutes = [
path: 'statisticsGroup',
name: 'statisticsGroup',
component: () => import('@/views/supervisionNew/statisticsGroup.vue'),
meta: { title: '部门报告统计'},
meta: { title: '部门报告统计', perms: ['task2']},
},
{
path: 'statistics',

View File

@ -48,7 +48,7 @@
</template>
<script>
import { getPgoalDeptList } from "@/api/task";
import { getPgoalDeptList,taskAnalyse } from "@/api/task";
import { getOrgList, getSubOrgList } from "@/api/org";
import checkPermission from "@/utils/permission";
import Pagination from "@/components/Pagination";
@ -104,7 +104,18 @@
});
}
},
//获取任务列表===获取任务id
// getAnalyseList(){
// if(that.listQuery.year==''){
// let date = new Date();
// that.listQuery.year = date.getFullYear();
// }
// this.deptName = this.$store.getters.dept_name;
// taskAnalyse(that.listQuery).then(res=>{
// console.log(res)
// let data = res.data;
// })
// },
//获取列表
getList(){
let that = this;
that.dataList.results = [];

View File

@ -134,13 +134,16 @@
<el-col :span="12" class="chartsWrap">
<div id="lin4" style="width:495px;height:300px;margin-left: 10px;"></div>
</el-col>
<el-col class="chartsWrap">
<div id="analyse" style="width:1000px;height:300px;"></div>
</el-col>
</el-row>
</div>
</el-card>
</div>
</template>
<script>
import { getTask2Do } from "@/api/task";
import { getTask2Do,taskAnalyse } from "@/api/task";
import { getOrgList, getSubOrgList } from "@/api/org";
import checkPermission from "@/utils/permission";
import * as echarts from 'echarts';
@ -153,139 +156,139 @@
task2__year:'',
page:0
},
tableData: [{
type:'重大质量事故',
title:'重大质量事故',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'报告/证书合格率',
title:'已发放报告/证书数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'报告/证书合格率',
title:'不准确报告/证书数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
}, {
type:'报告/证书合格率',
title:'报告/证书合格率',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
}, {
type:'报告/证书及时率',
title:'应发报告/证书数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'报告/证书及时率',
title:'实际按时完成报告/证书数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
}, {
type:'报告/证书及时率',
title:'报告/证书及时率',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},
{
type:'能力验证满意率',
title:'全部获结果参数数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'能力验证满意率',
title:'满意结果参数数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
}, {
type:'能力验证满意率',
title:'能力验证满意率',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'客户投诉处理满意率',
title:'全部已处理投诉数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},{
type:'客户投诉处理满意率',
title:'获满意结果的投诉数量',
first:'1',
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
}, {
type:'客户投诉处理满意率',
title:'客户投诉处理满意率',
first:1,
seconde:'2',
third:'3',
fouth:'4',
fifth:'5',
sixth:'6',
all:'21'
},
],
// tableData: [{
// type:'重大质量事故',
// title:'重大质量事故',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'报告/证书合格率',
// title:'已发放报告/证书数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'报告/证书合格率',
// title:'不准确报告/证书数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// }, {
// type:'报告/证书合格率',
// title:'报告/证书合格率',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// }, {
// type:'报告/证书及时率',
// title:'应发报告/证书数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'报告/证书及时率',
// title:'实际按时完成报告/证书数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// }, {
// type:'报告/证书及时率',
// title:'报告/证书及时率',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },
// {
// type:'能力验证满意率',
// title:'全部获结果参数数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'能力验证满意率',
// title:'满意结果参数数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// }, {
// type:'能力验证满意率',
// title:'能力验证满意率',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'客户投诉处理满意率',
// title:'全部已处理投诉数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },{
// type:'客户投诉处理满意率',
// title:'获满意结果的投诉数量',
// first:'1',
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// }, {
// type:'客户投诉处理满意率',
// title:'客户投诉处理满意率',
// first:1,
// seconde:'2',
// third:'3',
// fouth:'4',
// fifth:'5',
// sixth:'6',
// all:'21'
// },
// ],
deptName:'',
fileName:'',
tableData1:[],
@ -315,6 +318,8 @@
lineChart2:null,
lineChart3:null,
lineChart4:null,
barAnalyse:null,
xAxisDatas:['重大事故','报告/证书合格率(%)','报告/证书及时率(%)','能力验证满意率(%)','客户投诉处理满意率(%)'],
xAxisData:["1-2月","3-4月","5-6月","7-8月","9-10月","11-12月"],
bar1Data:[],
bar2Data:[],
@ -339,6 +344,7 @@
this.deptName = this.$store.getters.dept_name;
this.listQuery.belong_dept = this.$store.getters.dept;
this.handleFilter();
this.getAnalyseData();
}
this.optionSet();
this.getGroup();
@ -606,6 +612,7 @@
let that = this;
if(that.listQuery.belong_dept!==''){
if(that.listQuery.task2__year!==''){
that.getAnalyseData();
that.bar1Data = [];
that.bar2Data = [];
that.line1Data = [];
@ -743,14 +750,14 @@
}else{
that.line4Data.push(0)
}
}
that.bar1Option.series[0].data = that.bar1Data;
that.bar2Option.series[0].data = that.bar2Data;
that.line1Option.series[0].data = that.line1Data;
that.line2Option.series[0].data = that.line2Data;
that.line3Option.series[0].data = that.line3Data;
that.line4Option.series[0].data = that.line4Data;
}
}
that.bar1Option.series[0].data = that.bar1Data;
that.bar2Option.series[0].data = that.bar2Data;
that.line1Option.series[0].data = that.line1Data;
that.line2Option.series[0].data = that.line2Data;
that.line3Option.series[0].data = that.line3Data;
that.line4Option.series[0].data = that.line4Data;
that.barChart1.clear();
that.barChart1.setOption(that.bar1Option);
that.barChart2.clear();
@ -773,6 +780,112 @@
this.$message.warning('请选择部门')
}
},
getAnalyseData(){
let that = this;
let form = {};
form.year = this.listQuery.task2__year;
form.dept_name = this.deptName;
taskAnalyse(form).then(res=>{
console.log(res)
let data1 = [],data2 = [],data3=[];
if(res.data.length>0){
let data = res.data[0];
data1 = [data.重大事故数,data.报告证书合格率,data.报告证书及时率,data.能力验证满意率,data.客户投诉处理满意率];
data2 = [data.重大事故数基础值,data.报告证书合格率基础值,data.报告证书及时率基础值,data.能力验证满意率基础值,data.客户投诉处理满意率基础值];
data3 = [data.重大事故数设定值,data.报告证书合格率设定值,data.报告证书及时率设定值,data.能力验证满意率设定值,data.客户投诉处理满意率设定值];
for(let i=1;i<data1.length;i++){
if(data1[i]!==null){
data1[i] = data1[i].toFixed(2);
}
}
for(let j=1;j<data2.length;j++){
if(data2[j]!==null){
data2[j] = data2[j].toFixed(2);
}
}
for(let k=1;k<data3.length;k++){
if(data3[k]!==null){
data3[k] = data3[k].toFixed(2);
}
}
}
let chartanalyse = document.getElementById('analyse');
that.barAnalyse = echarts.init(chartanalyse);
let option = {
color:['#91cc75','#438af4','#ffc040'],
title:{
text:'年度统计',
x:'center'
},
tooltip: {
trigger:"axis",
axisPointer: {
type: 'shadow'
},
},
legend: {
data:['完成值','基础值','设定值'],
right:'1%',
top:'3%',
tooltip: {
show: true
}
},
xAxis:{
axisTick: {
show: false
},
data:that.xAxisDatas
},
grid: {
left: '5%',
right: '7%',
bottom: '3%',
containLabel: true
},
yAxis:{
type:'value',
axisLabel:{
formatter:"{value}"
},
scale:true,
},
series:[
{
name: '完成值',
type: 'bar',
// label: labelOption,
emphasis: {
focus: 'series'
},
barWidth:20,
data:data1
},
{
name:"基础值",
type:"bar",
emphasis: {
focus: 'series'
},
barWidth:20,
data:data2
},
{
name:"设定值",
type:"bar",
emphasis: {
focus: 'series'
},
barWidth:20,
data:data3
}
]
}
that.barAnalyse.clear();
that.barAnalyse.setOption(option);
})
},
handlePrint() {
this.$PRINT('#myReport');
},

View File

@ -3,7 +3,7 @@
<el-card>
<el-row :gutter="6">
<el-date-picker
v-model="listQuery.task2__year"
v-model="listQuery.year"
type="year"
placeholder="选择年"
value-format="yyyy"
@ -24,22 +24,22 @@
</el-row>
</el-card>
<el-card style="margin-top:10px">
<div ref="print" id="myReport" class="printContainer">
<div ref="print" id="myReport" class="printContainers">
<h3 style="text-align: center;">{{ fileName }}</h3>
<p v-if="fileName!==''" style="text-align: center;">{{ listQuery.task2__year }} </p>
<!-- 5个目标值 -->
<el-row id="echartsContainer">
<el-col class="chartsWrap" style="">
<div id="main" style="width:1800px;height:300px;margin-left: 10px;"></div>
<el-col class="chartsWraps">
<div id="main" style="width:100%;height:500px;margin-left: 10px;"></div>
</el-col>
<el-col class="chartsWrap" style="">
<div id="main2" style="width:1800px;height:300px;margin-left: 10px;"></div>
<el-col class="chartsWraps">
<div id="main2" style="width:100%;height:500px;margin-left: 10px;"></div>
</el-col>
<el-col class="chartsWrap" style="">
<div id="main3" style="width:1800px;height:300px;margin-left: 10px;"></div>
<el-col class="chartsWraps">
<div id="main3" style="width:100%;height:500px;margin-left: 10px;"></div>
</el-col>
<el-col class="chartsWrap" style="">
<div id="main4" style="width:1800px;height:300px;margin-left: 10px;"></div>
<el-col class="chartsWraps">
<div id="main4" style="width:100%;height:500px;margin-left: 10px;"></div>
</el-col>
</el-row>
</div>
@ -47,8 +47,7 @@
</div>
</template>
<script>
import { getTask2Do } from "@/api/task";
import { getOrgList, getSubOrgList } from "@/api/org";
import { taskAnalyse } from "@/api/task";
import checkPermission from "@/utils/permission";
import * as echarts from 'echarts';
export default {
@ -56,211 +55,48 @@
return {
timeStamp:0,
listQuery:{
task2__year:'',
page:0
year:'',
dept_type_name:'2级公司'
},
xaxis:[],
deptName:'',
fileName:'',
option:{},
option1:{},
option2:{},
option3:{},
option4:{},
};
},
mounted() {
this.getGroup();
},
methods: {
// handleFilter(){
// let that = this;
// if(that.listQuery.belong_dept!==''){
// if(that.listQuery.task2__year!==''){
// that.bar1Data = [];
// that.bar2Data = [];
// that.line1Data = [];
// that.line2Data = [];
// that.line3Data = [];
// that.line4Data = [];
// that.fileName = that.deptName;
// that.tableData1 = [];
// that.tableDatas = [ [],[],[],[],[],[],[],[],[],[],[],[],[]];
// getTask2Do(that.listQuery).then(res=>{
// let data = res.data.filter(item=>{
// return item.task2_.type==20
// });
// data.forEach(element => {
// let obj = element;
// if(element.num_issue!==null&&element.num_error!==null&&element.num_issue!==0){
// let rate1 = ((element.num_issue-element.num_error)/element.num_issue).toFixed(4)
// obj.rate1 = Number(rate1)*100
// }else{
// obj.rate1 = ''
// }
// if(element.num_expect!==null&&element.num_issue!==null&&element.num_expect!==0){
// let rate2 = (element.num_issue/element.num_expect).toFixed(4)
// obj.rate2 = Number(rate2)*100
// }
// else{
// obj.rate2 = ''
// }
// if(element.num_pt!==null&&element.num_pt_10!==null&&element.num_pt!==0){
// let rate3 = (element.num_pt_10/element.num_pt).toFixed(4)
// obj.rate3 = Number(rate3)*100
// }
// else{
// obj.rate3 = ''
// }
// if(element.num_complaint!==null&&element.num_complaint_10!==null&&element.num_complaint!==0){
// let rate4 = (element.num_complaint_10/element.num_complaint).toFixed(4)
// obj.rate4 = Number(rate4)*100
// }
// else{
// obj.rate4 = ''
// }
// let ind = element.task2_.cycle-1;
// that.tableData1[ind] = obj;
// });
// for (let i = 0; i < that.tableData1.length; i++) {
// let item = that.tableData1[i];
// if(item!==undefined){
// for(let j = 0; j < that.tableDatas.length; j++){
// that.tableDatas[j][i] =
// j==0?item.num_acc:
// j==1?item.num_issue:
// j==2?item.num_error:
// j==3?item.rate1:
// j==4?item.num_expect:
// j==5?item.num_issue:
// j==6?item.rate2:
// j==7?item.num_pt:
// j==8?item.num_pt_10:
// j==9?item.rate3:
// j==10?item.num_complaint:
// j==11?item.num_complaint_10:
// item.rate4;
// }
// }
// }
// that.timeStamp++;
// for(let k=0;k<that.tableDatas.length;k++){
// let num = 0;
// let num1 = that.tableDatas[k][0]?that.tableDatas[k][0]:0;
// let num2 = that.tableDatas[k][1]?that.tableDatas[k][1]:0;
// let num3 = that.tableDatas[k][2]?that.tableDatas[k][2]:0;
// let num4 = that.tableDatas[k][3]?that.tableDatas[k][3]:0;
// let num5 = that.tableDatas[k][4]?that.tableDatas[k][4]:0;
// let num6 = that.tableDatas[k][5]?that.tableDatas[k][5]:0;
// if(k==3){
// num = ((that.tableDatas[1][7]-that.tableDatas[2][7])/that.tableDatas[1][7]).toFixed(4)
// }else if(k==6){
// num = (that.tableDatas[5][7]/that.tableDatas[4][7]).toFixed(4)
// }else if(k==9){
// num =(that.tableDatas[8][7]/that.tableDatas[7][7]).toFixed(4)
// }else if(k==12){
// num = (that.tableDatas[11][7]/that.tableDatas[10][7]).toFixed(4)
// }else{
// num = Number(num1)+Number(num2)+Number(num3)+Number(num4)+Number(num5)+Number(num6);
// }
// if(num!=='NaN'&&num!==NaN){
// if(k==3||k==6||k==9||k==12){
// // debugger;
// console.log(parseFloat((Number(num)*100)))
// // parseFloat((Number(num)*100).toPrecision(12))
// let numbe = parseFloat((Number(num)*100).toPrecision(12));
// that.tableDatas[k][7] = numbe;
// }else{
// that.tableDatas[k][7] = num;
// }
// }else{
// that.tableDatas[k][7] = ''
// }
// }
// for(let i=0;i<6;i++){
// if(that.tableDatas[1][i]!==undefined){
// that.bar1Data.push(Number(that.tableDatas[1][i]))
// }else{
// that.bar1Data.push(0)
// }
// if(that.tableDatas[4][i]!==undefined){
// that.bar2Data.push(Number(that.tableDatas[4][i]))
// }else{
// that.bar2Data.push(0)
// }
// if(that.tableDatas[3][i]!==undefined){
// that.line1Data.push(Number(that.tableDatas[3][i]))
// }else{
// that.line1Data.push(0)
// }
// if(that.tableDatas[6][i]!==undefined){
// that.line2Data.push(Number(that.tableDatas[6][i]))
// }else{
// that.line2Data.push(0)
// }
// if(that.tableDatas[9][i]!==undefined){
// that.line3Data.push(Number(that.tableDatas[9][i]))
// }else{
// that.line3Data.push(0)
// }
// if(that.tableDatas[12][i]!==undefined){
// that.line4Data.push(Number(that.tableDatas[12][i]))
// }else{
// that.line4Data.push(0)
// }
// }
// that.bar1Option.series[0].data = that.bar1Data;
// that.bar2Option.series[0].data = that.bar2Data;
// that.line1Option.series[0].data = that.line1Data;
// that.line2Option.series[0].data = that.line2Data;
// that.line3Option.series[0].data = that.line3Data;
// that.line4Option.series[0].data = that.line4Data;
// that.barChart1.clear();
// that.barChart1.setOption(that.bar1Option);
// that.barChart2.clear();
// that.barChart2.setOption(that.bar2Option);
// that.lineChart1.clear();
// that.lineChart1.setOption(that.line1Option);
// that.lineChart2.clear();
// that.lineChart2.setOption(that.line2Option);
// that.lineChart3.clear();
// that.lineChart3.setOption(that.line3Option);
// that.lineChart4.clear();
// that.lineChart4.setOption(that.line4Option);
// })
// }else{
// this.$message.warning('请选择时间')
// }
// }else{
// this.$message.warning('请选择部门')
// }
// },
handlePrint() {
this.$PRINT('#myReport');
},
setOption(){
var myChart = echarts.init(document.getElementById('main'));
var myChart2 = echarts.init(document.getElementById('main2'));
var myChart3 = echarts.init(document.getElementById('main3'));
var myChart4 = echarts.init(document.getElementById('main4'));
var option = {
var myDate = new Date();
this.listQuery.year = myDate.getFullYear();
this.setOption();
this.handleFilter();
this.option = {
//标题
title: {
text: '',
// subtext: '小标题',
x: 'center',
top:'3%'
},
tooltip: {
trigger:"axis",
axisPointer: {
type: 'shadow'
},
formatter:"{a1}<br/>{b1}{c1}%"
},
legend: {
data:['目标值']
data:['完成值','设定值'],
right:'10%',
top:'3%'
},
grid: {
left: '2%',
right: '2%',
bottom: '10%',
top: '2%',
bottom: '5%',
top: '20%',
containLabel: true
},
xAxis: {
@ -269,28 +105,31 @@
rotate: 80 //设置倾斜角度数值 可设置 正负 两种
},
type: 'category',
data: this.xaxis,
data: [],
},
color:['#91cc75','#438af4'],
color:['#438af4','#91cc75'],
yAxis: {
type: 'value',
axisLabel:{
formatter:"{value}%"
}
},
scale:true,
min:60,
},
series: [
{
name: '',
name: '完成值',
type: 'bar',
z:"-1",
barGap: '-100%',
barGap: 0,
barWidth:10,
data: [100, 100, 100, 100, 100, 100],
data: [],
markLine : {
symbol:"none",
label: {
position: "end", //将警示值放在哪个位置三个值start,"middle","end" 开始 中点 结束
},
data : [{
data :[
{
silent:false, //鼠标悬停事件 true没有false有
lineStyle:{ //警戒线的样式 虚实 颜色
type:"solid",
@ -298,63 +137,126 @@
},
label:{
position:'end',
formatter:"目标(90)",
formatter:'{c}',
color:"#ffb4b4",
fontSize:'8'
},
yAxis:90 // 警戒线的标注值可以有多个yAxis,多条警示线 或者采用 {type : 'average', name: '平均值'}type值有 max min average分为最大最小平均值
}]
name:'',
yAxis:99 // 警戒线的标注值可以有多个yAxis,多条警示线 或者采用 {type : 'average', name: '平均值'}type值有 max min average分为最大最小平均值
}
]
}
},
{
name: '及时率',
name: '设定值',
type: 'bar',
barWidth:10,
data: [95, 92, 96, 90, 91, 98]
data: []
}
],
};
// 使用刚指定的配置项和数据显示图表
myChart.setOption(option);
myChart2.setOption(option);
myChart3.setOption(option);
myChart4.setOption(option);
},
methods: {
handlePrint() {
this.$PRINT('#myReport');
},
setOption(){
this.barChart1 = echarts.init(document.getElementById('main'));
this.barChart2 = echarts.init(document.getElementById('main2'));
this.barChart3 = echarts.init(document.getElementById('main3'));
this.barChart4 = echarts.init(document.getElementById('main4'));
},
checkPermission,
getGroup() {
if (this.checkPermission(["record_confirm"])) {
getOrgList({ can_supervision: true }).then((res) => {
let data = res.data,xaxis = [];
let arr = data.filter(item=>{
return item.type==26||item.type==28
})
arr.forEach(item=>{
xaxis.push(item.name)
})
this.orgData = arr;
this.xaxis = xaxis;
this.setOption();
});
} else {
getSubOrgList().then((res) => {
let data = res.data,xaxis = [];
let arr = data.filter(item=>{
return item.type==26||item.type==28
})
arr.forEach(item=>{
xaxis.push(item.name)
})
this.orgData = arr;
this.xaxis = xaxis;
this.setOption();
});
handleFilter(){
let that = this;
function compare(property) {
return function (a, b) {
return b[property]-a[property];
}
}
},
taskAnalyse(that.listQuery).then(res=>{
console.log(res)
let data = res.data;
// let list = data.filter(item=>{
// })
// 按照属性num给data排序
let xaxis1 = [],data1 = [],data12=[],
xaxis2 = [],data2 = [],data22=[],
xaxis3 = [],data3 = [],data32=[],
xaxis4 = [],data4 = [],data42=[];
let markLine1 = 0,markLine2=0,markLine3=0,markLine4=0;
let sortedArr1 = data.sort(compare("报告证书合格率"));
sortedArr1.forEach(item1=>{
xaxis1.push(item1.单位)
data1.push(item1.报告证书合格率)
data12.push(item1.报告证书合格率设定值)
})
markLine1 = sortedArr1[0].报告证书合格率基础值;
let sortedArr2 = data.sort(compare("报告证书及时率"));
sortedArr2.forEach(item2=>{
xaxis2.push(item2.单位)
data2.push(item2.报告证书及时率)
data22.push(item2.报告证书及时率设定值)
})
markLine2 = sortedArr2[0].报告证书及时率基础值;
let sortedArr3 = data.sort(compare("能力验证满意率"));
sortedArr3.forEach(item3=>{
xaxis3.push(item3.单位)
data3.push(item3.能力验证满意率)
data32.push(item3.能力验证满意率设定值)
})
markLine3 = sortedArr3[0].能力验证满意率基础值;
let sortedArr4 = data.sort(compare("客户投诉处理满意率"));
sortedArr4.forEach(item4=>{
xaxis4.push(item4.单位)
data4.push(item4.客户投诉处理满意率)
data42.push(item4.客户投诉处理满意率设定值)
})
markLine4 = sortedArr4[0].客户投诉处理满意率基础值;
let option1 =that.option;
let option2 =that.option;
let option3=that.option;
let option4= that.option;
option1.xAxis.data = xaxis1;
option1.series[0].data = data1;
option1.series[1].data = data12;
option1.title.text = '报告证书合格率';
option1.series[0].markLine.data[0].yAxis = markLine1;
that.barChart1.clear();
that.barChart1.setOption(option1);
option2.xAxis.data = xaxis2;
option2.series[0].data = data2;
option2.series[1].data = data22;
option2.title.text = '报告证书及时率';
option2.series[0].markLine.data[0].yAxis = markLine2;
that.barChart2.clear();
that.barChart2.setOption(option2);
option3.xAxis.data = xaxis3;
option3.series[0].data = data3;
option3.series[1].data = data32;
option3.title.text = '能力验证满意率';
option3.series[0].markLine.data[0].yAxis = markLine3;
that.barChart3.clear();
that.barChart3.setOption(option3);
option4.xAxis.data = xaxis4;
option4.series[0].data = data4;
option4.series[1].data = data42;
option4.title.text = '客户投诉处理满意率';
option4.series[0].markLine.data[0].yAxis = markLine4;
that.barChart4.clear();
that.barChart4.setOption(option4);
})
},
}
};
</script>
<style>
.printContainer{
.printContainers{
/* width: 1075px; */
}
#numTable,#echartsContainer{
@ -374,10 +276,10 @@
#echartsContainer{
margin-top: 30px;
}
.chartsWrap{
/* margin-top: 30px; */
/* padding-top: 50px; */
width: 100%;
.chartsWraps{
width: 99%;
height: fit-content;
overflow-y: hidden;
overflow-x: scroll;
border-top: 1px solid #eeeeee;
}