diff --git a/src/views/BI/js/echarts1.js b/src/views/BI/js/echarts1.js index e772bc1..e1aab14 100644 --- a/src/views/BI/js/echarts1.js +++ b/src/views/BI/js/echarts1.js @@ -107,21 +107,19 @@ function echarts1(id, legend, echartCount) { }, }, itemStyle: { - normal: { - color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ - { - offset: 1, - color: "rgba(109, 131, 180, 1)", - opacity: 0.6, - }, - { - offset: 0, - color: "rgba(66, 91, 147, 1)", - opacity: 1, - }, - ]), - barBorderRadius: [0, 0, 0, 0], - }, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 1, + color: "rgba(109, 131, 180, 1)", + opacity: 0.6, + }, + { + offset: 0, + color: "rgba(66, 91, 147, 1)", + opacity: 1, + }, + ]), + barBorderRadius: [0, 0, 0, 0], }, data: echartCount, }, @@ -138,21 +136,19 @@ function echarts1(id, legend, echartCount) { }, }, itemStyle: { - normal: { - color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ - { - offset: 1, - color: "rgba(109, 131, 180, 1)", - opacity: 0.6, - }, - { - offset: 0, - color: "rgba(99, 126, 188, 1)", - opacity: 1, - }, - ]), - barBorderRadius: [0, 0, 0, 0], - }, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 1, + color: "rgba(109, 131, 180, 1)", + opacity: 0.6, + }, + { + offset: 0, + color: "rgba(99, 126, 188, 1)", + opacity: 1, + }, + ]), + barBorderRadius: [0, 0, 0, 0], }, data: echartCount, barGap: 0, @@ -165,9 +161,7 @@ function echarts1(id, legend, echartCount) { }, type: "pictorialBar", itemStyle: { - normal: { - color: "rgba(183, 195, 226, 1)", - }, + color: "rgba(183, 195, 226, 1)", }, symbol: "diamond", symbolRotate: 0, diff --git a/src/views/BI/js/echarts4.js b/src/views/BI/js/echarts4.js index 07b6867..f5aa0ea 100644 --- a/src/views/BI/js/echarts4.js +++ b/src/views/BI/js/echarts4.js @@ -130,88 +130,63 @@ function echarts4(id) { fontSize: 12, }, itemStyle: { - // normal: { - // color: { - // type: 'linear', - // x: 0, - // y: 0, - // x2: 0, - // y2: 1, - // colorStops: [ - // { - // offset: 0, - // color: '#3b89f4', - // }, - // { - // offset: 1, - // color: '#cce7fc', - // }, - // ], - // global: false, // 缺省为 false - // }, - // }, - // emphasis: { - // opacity: 1, - // }, - normal: { - color: (params) => { - const colorList = [ - { - type: "linear", - x: 0, - y: 0, - x2: 0, - y2: 1, - colorStops: [ - { - offset: 0, - color: "#297ff2", - }, - { - offset: 1, - color: "#cce7fc", - }, - ], - }, - { - type: "linear", - x: 0, - y: 0, - x2: 0, - y2: 1, - colorStops: [ - { - offset: 0, - color: "#3bfafe", - }, - { - offset: 1, - color: "#aaf4fe", - }, - ], - }, - { - type: "linear", - x: 0, - y: 0, - x2: 0, - y2: 1, - colorStops: [ - { - offset: 0, - color: "#e08440", - }, - { - offset: 1, - color: "#decabd", - }, - ], - }, - ]; - return colorList[params.dataIndex]; - }, - opacity: 0.7, + color: (params) => { + const colorList = [ + { + type: "linear", + x: 0, + y: 0, + x2: 0, + y2: 1, + colorStops: [ + { + offset: 0, + color: "#297ff2", + }, + { + offset: 1, + color: "#cce7fc", + }, + ], + }, + { + type: "linear", + x: 0, + y: 0, + x2: 0, + y2: 1, + colorStops: [ + { + offset: 0, + color: "#3bfafe", + }, + { + offset: 1, + color: "#aaf4fe", + }, + ], + }, + { + type: "linear", + x: 0, + y: 0, + x2: 0, + y2: 1, + colorStops: [ + { + offset: 0, + color: "#e08440", + }, + { + offset: 1, + color: "#decabd", + }, + ], + }, + ]; + return colorList[params.dataIndex]; }, + opacity: 0.7, // 鼠标移入柱子上 透明度变为 1 emphasis: { opacity: 1, diff --git a/src/views/aggregation_management/gathering_overview/index.vue b/src/views/aggregation_management/gathering_overview/index.vue index 693862c..4f943ea 100644 --- a/src/views/aggregation_management/gathering_overview/index.vue +++ b/src/views/aggregation_management/gathering_overview/index.vue @@ -248,11 +248,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.one, itemStyle: { - normal: { + color: "red", + lineStyle: { color: "red", - lineStyle: { - color: "red", - }, }, }, }, @@ -261,11 +259,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.two, itemStyle: { - normal: { + color: "orange", + lineStyle: { color: "orange", - lineStyle: { - color: "orange", - }, }, }, }, @@ -274,11 +270,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.three, itemStyle: { - normal: { + color: "#ffeb3b", + lineStyle: { color: "#ffeb3b", - lineStyle: { - color: "#ffeb3b", - }, }, }, }, @@ -287,11 +281,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.zong, itemStyle: { - normal: { + color: "#0385f4", + lineStyle: { color: "#0385f4", - lineStyle: { - color: "#0385f4", - }, }, }, }, diff --git a/src/views/index/components/checklist_check.vue b/src/views/index/components/checklist_check.vue index 0807f54..e02390c 100644 --- a/src/views/index/components/checklist_check.vue +++ b/src/views/index/components/checklist_check.vue @@ -92,18 +92,16 @@ const fnInitEcharts = (data) => { }, barWidth: 15, itemStyle: { - normal: { - color: function (params) { - const colorList = [ - "#ee6666", - "#73c0de", - "#3ca272", - "#fc8452", - "#9a60b4", - "#5470c6", - ]; - return colorList[params.dataIndex]; - }, + color: function (params) { + const colorList = [ + "#ee6666", + "#73c0de", + "#3ca272", + "#fc8452", + "#9a60b4", + "#5470c6", + ]; + return colorList[params.dataIndex]; }, }, }, diff --git a/src/views/index/components/list_check_type.vue b/src/views/index/components/list_check_type.vue index c686231..31afbc0 100644 --- a/src/views/index/components/list_check_type.vue +++ b/src/views/index/components/list_check_type.vue @@ -21,9 +21,7 @@ const fnInitEcharts = (data) => { text: "清单检查类型统计", textStyle: { fontSize: "14", - normal: { - fontWeight: "700", - }, + fontWeight: "700", color: "#fff", }, }, @@ -79,11 +77,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.xcqd, itemStyle: { - normal: { + color: "#3ca272", + lineStyle: { color: "#3ca272", - lineStyle: { - color: "#3ca272", - }, }, }, }, @@ -92,11 +88,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.jcqd, itemStyle: { - normal: { + color: "#5470c6", + lineStyle: { color: "#5470c6", - lineStyle: { - color: "#5470c6", - }, }, }, }, @@ -105,11 +99,9 @@ const fnInitEcharts = (data) => { type: "line", data: data.zhqd, itemStyle: { - normal: { + color: "#ee6666", + lineStyle: { color: "#ee6666", - lineStyle: { - color: "#ee6666", - }, }, }, }, diff --git a/src/views/large_screen_data_display/components/full_staff_training.vue b/src/views/large_screen_data_display/components/full_staff_training.vue index 65f4d2b..d0f8d08 100644 --- a/src/views/large_screen_data_display/components/full_staff_training.vue +++ b/src/views/large_screen_data_display/components/full_staff_training.vue @@ -85,25 +85,23 @@ const fnInitEcharts = (data) => { data: yData, barWidth: "10px", itemStyle: { - normal: { - color: new echarts.graphic.LinearGradient( - 0, - 0, - 0, - 1, - [ - { - offset: 0, - color: "#4abd91", // 0% 处的颜色 - }, - { - offset: 1, - color: "#28b2d5", // 100% 处的颜色 - }, - ], - false - ), - }, + color: new echarts.graphic.LinearGradient( + 0, + 0, + 0, + 1, + [ + { + offset: 0, + color: "#4abd91", // 0% 处的颜色 + }, + { + offset: 1, + color: "#28b2d5", // 100% 处的颜色 + }, + ], + false + ), }, }, ], diff --git a/src/views/large_screen_data_display/components/hidden_danger_situation.vue b/src/views/large_screen_data_display/components/hidden_danger_situation.vue index dd84963..03f2c62 100644 --- a/src/views/large_screen_data_display/components/hidden_danger_situation.vue +++ b/src/views/large_screen_data_display/components/hidden_danger_situation.vue @@ -33,7 +33,7 @@ const fnInitEcharts = (data) => { }, legend: { icon: "rect", - top: "5%", + top: "8%", right: "5%", itemWidth: 12, itemHeight: 12, @@ -103,10 +103,8 @@ const fnInitEcharts = (data) => { data: data.all, smooth: true, itemStyle: { - normal: { - color: colorList[0], - borderColor: colorList[0], - }, + color: colorList[0], + borderColor: colorList[0], }, }, { @@ -115,10 +113,8 @@ const fnInitEcharts = (data) => { data: data.wzg, smooth: true, itemStyle: { - normal: { - color: colorList[1], - borderColor: colorList[1], - }, + color: colorList[1], + borderColor: colorList[1], }, }, { @@ -127,10 +123,8 @@ const fnInitEcharts = (data) => { data: data.yzg, smooth: true, itemStyle: { - normal: { - color: colorList[2], - borderColor: colorList[2], - }, + color: colorList[2], + borderColor: colorList[2], }, }, { @@ -139,10 +133,8 @@ const fnInitEcharts = (data) => { data: data.yys, smooth: true, itemStyle: { - normal: { - color: colorList[3], - borderColor: colorList[3], - }, + color: colorList[3], + borderColor: colorList[3], }, }, ], diff --git a/src/views/large_screen_data_display/components/risk_management.vue b/src/views/large_screen_data_display/components/risk_management.vue index 402099d..a6d0f01 100644 --- a/src/views/large_screen_data_display/components/risk_management.vue +++ b/src/views/large_screen_data_display/components/risk_management.vue @@ -3,20 +3,21 @@