From 143445b890657d51282807ce2eec6ff6434dbe7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E8=A3=95=E8=B4=A2?= Date: Thu, 2 Feb 2023 21:49:47 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/xm/rpt/project/taskAgeDist.vue | 1 + src/views/xm/rpt/project/taskAttDist.vue | 11 ++++++++ src/views/xm/rpt/project/taskSort.vue | 1 + .../xm/rpt/testPlan/testCaseToPlanCalc.vue | 27 +++++++++++++++++++ .../xm/rpt/testPlan/testDayTimesCalc.vue | 2 +- .../testPlan/testPlanCaseExecStatusDist.vue | 27 ++++++++++++++++++- 6 files changed, 67 insertions(+), 2 deletions(-) diff --git a/src/views/xm/rpt/project/taskAgeDist.vue b/src/views/xm/rpt/project/taskAgeDist.vue index 268eb5c6..cf835198 100644 --- a/src/views/xm/rpt/project/taskAgeDist.vue +++ b/src/views/xm/rpt/project/taskAgeDist.vue @@ -218,6 +218,7 @@ if(this.filters.iteration){ params.iterationId=this.filters.iteration.id } + params.ntype='0' getXmTaskAgeDist(params).then(res=>{ this.xmTaskAgeDists=res.data.data }) diff --git a/src/views/xm/rpt/project/taskAttDist.vue b/src/views/xm/rpt/project/taskAttDist.vue index b577c129..3d51b24d 100644 --- a/src/views/xm/rpt/project/taskAttDist.vue +++ b/src/views/xm/rpt/project/taskAttDist.vue @@ -96,6 +96,16 @@ }) } }, + + total(){ + if(!this.xmTestCaseToPlanCalcList || this.xmTestCaseToPlanCalcList.length==0){ + return 0 + }else{ + return this.xmTestCaseToPlanCalcList.reduce((n, i) => { + return (n += i.useTimes); + }, 0) + } + }, title(){ var preName="" @@ -282,6 +292,7 @@ if(this.filters.iteration){ params.iterationId=this.filters.iteration.id } + params.ntype='0' getXmTaskAttDist(params).then(res=>{ this.xmTaskAttDists=res.data.data }) diff --git a/src/views/xm/rpt/project/taskSort.vue b/src/views/xm/rpt/project/taskSort.vue index fabd1f97..8fc883af 100644 --- a/src/views/xm/rpt/project/taskSort.vue +++ b/src/views/xm/rpt/project/taskSort.vue @@ -256,6 +256,7 @@ } params.orderBy = orderBys.join(","); } + params.ntype='0' getXmTaskSort(params).then(res=>{ this.xmTaskSorts=res.data.data }) diff --git a/src/views/xm/rpt/testPlan/testCaseToPlanCalc.vue b/src/views/xm/rpt/testPlan/testCaseToPlanCalc.vue index de2505c0..a4a1bbbf 100644 --- a/src/views/xm/rpt/testPlan/testCaseToPlanCalc.vue +++ b/src/views/xm/rpt/testPlan/testCaseToPlanCalc.vue @@ -98,6 +98,16 @@ return datas; } }, + + total(){ + if(!this.xmTestCaseToPlanCalcList || this.xmTestCaseToPlanCalcList.length==0){ + return 0 + }else{ + return this.xmTestCaseToPlanCalcList.reduce((n, i) => { + return (n += i.useTimes); + }, 0) + } + }, title(){ var preName="" if(this.filters.testPlan && this.filters.testPlan.id){ @@ -201,6 +211,23 @@ bottom: 'bottom', data:this.legendCpd, }, + + graphic: { + type: 'text', + left: 'center', + top: 'center', + style: { + // text: '总数', + text: + '总用例数'+this.total , + + textAlign: 'center', + fill: '#333', + width: 30, + height: 30, + fontSize: 14 + } + }, series: [ { type: 'pie', diff --git a/src/views/xm/rpt/testPlan/testDayTimesCalc.vue b/src/views/xm/rpt/testPlan/testDayTimesCalc.vue index 92a1042b..970b14d8 100644 --- a/src/views/xm/rpt/testPlan/testDayTimesCalc.vue +++ b/src/views/xm/rpt/testPlan/testDayTimesCalc.vue @@ -229,7 +229,7 @@ { name:'次数', data: this.testDayTimesCpd, - type: 'line', + type: 'bar', label:{ show: true, }, diff --git a/src/views/xm/rpt/testPlan/testPlanCaseExecStatusDist.vue b/src/views/xm/rpt/testPlan/testPlanCaseExecStatusDist.vue index b90ae3ae..8b3c461c 100644 --- a/src/views/xm/rpt/testPlan/testPlanCaseExecStatusDist.vue +++ b/src/views/xm/rpt/testPlan/testPlanCaseExecStatusDist.vue @@ -90,6 +90,15 @@ return datas; } }, + total(){ + if(!this.xmTestPlanCaseExecStatusDists || this.xmTestPlanCaseExecStatusDists.length==0){ + return 0 + }else{ + return this.xmTestPlanCaseExecStatusDists.reduce((n, i) => { + return (n += i.totalCnt); + }, 0) + } + }, title(){ var preName="" if(this.filters.testPlan && this.filters.testPlan.id){ @@ -194,10 +203,26 @@ bottom: 'bottom', data:this.legendCpd, }, + graphic: { + type: 'text', + left: 'center', + top: 'center', + style: { + // text: '总数', + text: + '总用例数'+this.total , + + textAlign: 'center', + fill: '#333', + width: 30, + height: 30, + fontSize: 14 + } + }, series: [ { type: 'pie', - radius: '50%', + radius: ['50%','70%'], data: this.xmTestPlanCaseExecStatusDistsCpd, emphasis: { itemStyle: {