From 137a4e373f600f791229275b8f412eea3de90290 Mon Sep 17 00:00:00 2001 From: zhaobing Date: Wed, 5 Jul 2023 18:37:21 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E5=9B=BE=E8=A1=A8=E7=9A=84=E5=8D=95?= =?UTF-8?q?=E4=BD=8D=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../analysis/containers/operationData.jsx | 15 ++++++++++++++- .../sections/analysis/containers/problemData.jsx | 10 +++++++++- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/web/client/src/sections/analysis/containers/operationData.jsx b/web/client/src/sections/analysis/containers/operationData.jsx index 0c9eda9..d5acc4e 100644 --- a/web/client/src/sections/analysis/containers/operationData.jsx +++ b/web/client/src/sections/analysis/containers/operationData.jsx @@ -190,7 +190,11 @@ const Console = (props) => { }, { t: '运维人员分析', echartOption: { - tooltip: {}, + tooltip: { + formatter:(params)=>{ + return params?.data.name+':'+params?.data.value+'次' + } + }, series: [ { // name: right2List?.map((item)=>{ @@ -206,6 +210,15 @@ const Console = (props) => { } } ], + // graphic: { + // type: 'text', + // left: 'center', + // top: 'middle', + // style: { + // text: '单位:次', + // fontSize: 14 + // } + // }, media: [ { query: { minAspectRatio: 1 }, diff --git a/web/client/src/sections/analysis/containers/problemData.jsx b/web/client/src/sections/analysis/containers/problemData.jsx index 343152e..da1de43 100644 --- a/web/client/src/sections/analysis/containers/problemData.jsx +++ b/web/client/src/sections/analysis/containers/problemData.jsx @@ -137,6 +137,7 @@ const Console = (props) => { // }, }, yAxis: { + name:'单位:次数', type: 'category', data: left1List.map((item) => { return item.projectName @@ -294,6 +295,7 @@ const Console = (props) => { }, }, yAxis: { + name:'单位:次数', type: 'value', // name: "单位:个", // nameLocation: "end", @@ -322,7 +324,11 @@ const Console = (props) => { }, { t: '维修状态分析', echartOption: { - tooltip: {}, + tooltip: { + formatter:(params)=>{ + return params?.data.name+':'+params?.data.value+'个' + } + }, series: [ { name:'维修状态分析', @@ -332,6 +338,8 @@ const Console = (props) => { return {value: Number(item.count), name: item.status} })), label: { + show: true, + //formatter: '单位:次数', // name: right2List.map((item=>{ // return{} // }))