From 15ad25a91bee0d50c25c3ab5b5a3e17c39a7b0cf Mon Sep 17 00:00:00 2001 From: shijing Date: Fri, 2 Jun 2023 13:28:59 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=97=A5=E5=B8=B8=E7=9B=91=E7=9D=A3?= =?UTF-8?q?=E9=83=A8=E9=97=A8=E6=8A=A5=E5=91=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/router/index.js | 1 - client/src/views/supervisionNew/mytask.vue | 13 +- .../src/views/supervisionNew/statistics.vue | 1394 +++++++++-------- client/src/views/supervisionNew/taskdo.vue | 39 +- 4 files changed, 786 insertions(+), 661 deletions(-) diff --git a/client/src/router/index.js b/client/src/router/index.js index c7ea09f..bab0062 100644 --- a/client/src/router/index.js +++ b/client/src/router/index.js @@ -270,7 +270,6 @@ export const asyncRoutes = [ name: 'statistics', component: () => import('@/views/supervisionNew/statistics.vue'), meta: { title: '部门报告'}, - hidden: true }, { path: 'mytaskDo', diff --git a/client/src/views/supervisionNew/mytask.vue b/client/src/views/supervisionNew/mytask.vue index 512ca2d..e9b6529 100644 --- a/client/src/views/supervisionNew/mytask.vue +++ b/client/src/views/supervisionNew/mytask.vue @@ -36,7 +36,7 @@ {{ props.row.num_complaint }} - {{ props.row.num_complaint10 }} + {{ props.row.num_complaint_10 }} {{ props.row.num_oinspect }} @@ -861,6 +861,7 @@ saveNum(this.task2do,this.numbers).then((res) => { if (res.code >= 200) { this.$message.success("成功"); + this.getList(); } }); } else { @@ -1040,14 +1041,15 @@ }else if(type=='complaint'){ form.key = "num_complaint" }else if(type=='oinspect'){ - form.key = "num_oinspect " + form.key = "num_oinspect" } noNum(this.task2do,form).then(res=>{ if(res.code>=200){ this.$message.success("提交成功"); + this.getList(); }else{} }) - + }) .catch((err) => { }); @@ -1078,22 +1080,27 @@ rcSaveSuccess(){ this.dialogRc = false; this.getRcList(); + this.getList(); }, ptSaveSuccess(){ this.dialogPt = false; this.getPtList(); + this.getList(); }, comSaveSuccess(){ this.dialogCom = false; this.getComplaintList(); + this.getList(); }, riskSaveSuccess(){ this.dialogRisk = false; this.getRiskList(); + this.getList(); }, oinSaveSuccess(){ this.dialogOin = false; this.getOinspectList(); + this.getList(); }, downloads() { let a = document.createElement('a') diff --git a/client/src/views/supervisionNew/statistics.vue b/client/src/views/supervisionNew/statistics.vue index a681a86..90033ba 100644 --- a/client/src/views/supervisionNew/statistics.vue +++ b/client/src/views/supervisionNew/statistics.vue @@ -1,13 +1,11 @@ - \ No newline at end of file diff --git a/client/src/views/supervisionNew/taskdo.vue b/client/src/views/supervisionNew/taskdo.vue index 9c87dfc..7f54521 100644 --- a/client/src/views/supervisionNew/taskdo.vue +++ b/client/src/views/supervisionNew/taskdo.vue @@ -211,7 +211,32 @@
执行详情
-

应发报告:{{ task2doItem.num_expect }} 已发报告:{{ task2doItem.num_issue }}

+

+ +

重大事故:{{ task2doItem.num_acc }}

+

风险识别:{{ task2doItem.num_risk }}

+ + +

应发报告:{{ task2doItem.num_expect }}

+

已发报告:{{ task2doItem.num_issue }}

+
+ +

不准确报告:{{ task2doItem.num_error }}

+

超期报告:{{ task2doItem.num_overdue }}

+
+ +

能力验证结果:{{ task2doItem.num_pt }}

+

验证结果满意:{{ task2doItem.num_pt_10 }}

+
+ +

客户投诉:{{ task2doItem.num_complaint }}

+

投诉结果满意:{{ task2doItem.num_complaint_10 }}

+
+ +

外部监督检查:{{ task2doItem.num_oinspect }}

+
+

+ @@ -224,7 +249,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > @@ -244,7 +269,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > @@ -264,7 +289,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > @@ -295,7 +320,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > @@ -322,7 +347,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > @@ -350,7 +375,7 @@ fit stripe highlight-current-row - max-height="300px" + height="250px" > From 9308f1e8f5a99e949967a4ccd9da14271e7416ed Mon Sep 17 00:00:00 2001 From: shijing Date: Fri, 2 Jun 2023 16:08:49 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=8A=A5=E5=91=8A=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/supervisionNew/statistics.vue | 362 ++++++++++-------- 1 file changed, 199 insertions(+), 163 deletions(-) diff --git a/client/src/views/supervisionNew/statistics.vue b/client/src/views/supervisionNew/statistics.vue index 90033ba..63b256c 100644 --- a/client/src/views/supervisionNew/statistics.vue +++ b/client/src/views/supervisionNew/statistics.vue @@ -6,6 +6,7 @@ v-model="listQuery.belong_dept" placeholder="报送部门" clearable + @change="belongDeptChange" > {{ scope.row.all }} --> +

{{ fileName }}

+

{{ listQuery.task2__year }}年 1—12月质量目标双月报

@@ -89,19 +92,19 @@ - + - + - + - + @@ -114,22 +117,22 @@
报告/证书合格率 已发放报告/证书数量 不准确报告/证书数量报告/证书合格率报告/证书合格率(%) 报告/证书及时率 应发报告/证书数量 实际按时完成报告/证书数量报告/证书及时率报告/证书及时率(%) 能力验证满意率 全部获结果参数数量 满意结果参数数量报告/能力验证满意率报告/能力验证满意率(%) 客户投诉处理满意率 全部已处理投诉数量 获满意结果的投诉数量报告/客户投诉处理满意率报告/客户投诉处理满意率(%) {{item[0]}} {{item[1]}} {{item[2]}}
-
+
-
+
-
+
-
+
-
+
-
+
@@ -283,6 +286,8 @@ all:'21' }, ], + deptName:'', + fileName:'', tableData1:[], // tableDatas:[ // {type:'重大质量事故',title:'重大质量事故'}, @@ -331,6 +336,13 @@ this.optionSet(); }, methods: { + belongDeptChange(a){ + this.fileName = ''; + let selectItem = this.orgData.filter(item=>{ + return item.id==a + }) + this.deptName = selectItem[0].name; + }, optionSet(){ let chartDom1 = document.getElementById('bar1'); this.barChart1 = echarts.init(chartDom1); @@ -344,6 +356,12 @@ }, data:this.xAxisData }, + grid: { + left: '5%', + right: '7%', + bottom: '3%', + containLabel: true + }, yAxis:{}, series:[ { @@ -359,6 +377,12 @@ title:{ text:"应发报告/证书数量" }, + grid: { + left: '5%', + right: '7%', + bottom: '3%', + containLabel: true + }, xAxis:{ axisTick: { show: false @@ -389,7 +413,7 @@ grid: { left: '5%', right: '7%', - bottom: '10%', + bottom: '3%', containLabel: true }, toolbox: { @@ -435,7 +459,7 @@ grid: { left: '7%', right: '5%', - bottom: '10%', + bottom: '3%', containLabel: true }, toolbox: { @@ -481,7 +505,7 @@ grid: { left: '5%', right: '7%', - bottom: '10%', + bottom: '3%', containLabel: true }, toolbox: { @@ -527,7 +551,7 @@ grid: { left: '7%', right: '5%', - bottom: '10%', + bottom: '3%', containLabel: true }, toolbox: { @@ -561,158 +585,170 @@ }, handleFilter(){ let that = this; - that.tableData1 = []; - that.tableDatas = [ [],[],[],[],[],[],[],[],[],[],[],[],[]]; - getTask2Do(that.listQuery).then(res=>{ - let data = res.data.filter(item=>{ - return item.task2_.type==20 - }); - console.log(data) - 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(2) - obj.rate1 = Number(rate1) - }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(2) - obj.rate2 = Number(rate2) - } - 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(2) - obj.rate3 = Number(rate3) - } - 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(2) - obj.rate4 = Number(rate4) - } - 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; + 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 + }); + console.log(data) + 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; + } + } } - } - } - // debugger; - console.log(that.tableDatas) - that.timeStamp++; + // debugger; + console.log(that.tableDatas) + that.timeStamp++; + for(let k=0;k \ No newline at end of file