diff --git a/psdc-ui/src/views/emonitor/db/index.vue b/psdc-ui/src/views/emonitor/db/index.vue index 979c660..4b33898 100644 --- a/psdc-ui/src/views/emonitor/db/index.vue +++ b/psdc-ui/src/views/emonitor/db/index.vue @@ -4,29 +4,29 @@
-

当前功率

-

{{data.totp}}kW

+

当前功率

+

{{data.totp}}kW

-

日用电量

-

{{data.eday}}kWh

+

日用电量

+

{{data.eday}}kWh

-

月用电量

-

{{data.emonth}}kWh

+

月用电量

+

{{data.emonth}}kWh

-

累计用电量

-

{{data.totwh}}kWh

+

累计用电量

+

{{data.totwh}}kWh

diff --git a/psdc-ui/src/views/emonitor/drgl/index.vue b/psdc-ui/src/views/emonitor/drgl/index.vue index 5007576..dc959bf 100644 --- a/psdc-ui/src/views/emonitor/drgl/index.vue +++ b/psdc-ui/src/views/emonitor/drgl/index.vue @@ -4,27 +4,27 @@
-

总用电量

-

{{data.totwh}}kWh

+

总用电量

+

{{data.totwh}}kWh

-

当前功率

-

{{data.totp}}kW

+

当前功率

+

{{data.totp}}kW

-

进水温度:

-

{{data.tempIn}}℃

+

进水温度:

+

{{data.tempIn}}℃

-

出水温度:

-

{{data.tempOut}}℃

+

出水温度:

+

{{data.tempOut}}℃

@@ -241,15 +241,42 @@ export default { myChart.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['日用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.dayXz, + type:'category', + data:data.dayXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -259,12 +286,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -279,6 +306,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -301,15 +344,42 @@ export default { myChart2.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['月用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.emonthXz, + type:'category', + data:data.emonthXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -319,12 +389,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -339,6 +409,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -363,6 +449,15 @@ export default { show: true }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, legend: { data: ['进水', '出水'], textStyle:{ @@ -376,8 +471,19 @@ export default { data: data.time, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -392,7 +498,7 @@ export default { } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -451,6 +557,12 @@ export default { myChart3 = echarts.init(document.getElementById("myEcharts3")); myChart3.setOption({ title: {}, + legend:{ + data:['当前功率'], + textStyle: { + color: "white" //标题的颜色 + }, + }, tooltip: { trigger: "axis", show: true @@ -458,12 +570,31 @@ export default { textStyle:{ color:'#BEC3DA' }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, xAxis: { - data: data.glXz, + data:data.glXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -473,12 +604,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', + type:'solid', color:'#BEC3DA' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -494,6 +625,22 @@ export default { color:'#2F8EE0' }, symbol: "none", //去掉拐角点 + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); diff --git a/psdc-ui/src/views/emonitor/frdl/index.vue b/psdc-ui/src/views/emonitor/frdl/index.vue index 38ed214..2c84fac 100644 --- a/psdc-ui/src/views/emonitor/frdl/index.vue +++ b/psdc-ui/src/views/emonitor/frdl/index.vue @@ -4,31 +4,31 @@
-

总用电量

-

1641kWh

+

总用电量

+

1641kWh

-

当前功率

-

11kW

+

当前功率

+

11kW

-

当前温度

-

25℃

+

当前温度

+

25℃

-

运行状态

-

开启

+

运行状态

+

开启

@@ -233,15 +233,42 @@ export default { myChart.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['日用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.dayXz, + type:'category', + data:data.dayXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -251,12 +278,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -271,6 +298,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -293,15 +336,42 @@ export default { myChart2.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['月用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.emonthXz, + type:'category', + data:data.emonthXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -311,12 +381,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -331,6 +401,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -352,8 +438,24 @@ export default { title: {}, tooltip: { trigger: "axis", + show: true }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend: { + data: ['当前温度'], + textStyle:{ + color:'#F5901A' + } + }, textStyle:{ color:'#BEC3DA' }, @@ -361,8 +463,19 @@ export default { data: data.time, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -377,7 +490,7 @@ export default { } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -388,9 +501,9 @@ export default { { name: '当前温度', type: 'line', - stack: 'Total', - itemStyle: { //线条颜色 - color: '#F5901A', + // stack: 'Total', + itemStyle:{ + color:'#F5901A' }, data: data.tem }, @@ -427,6 +540,12 @@ export default { myChart3 = echarts.init(document.getElementById("myEcharts3")); myChart3.setOption({ title: {}, + legend:{ + data:['当前功率'], + textStyle: { + color: "white" //标题的颜色 + }, + }, tooltip: { trigger: "axis", show: true @@ -434,12 +553,31 @@ export default { textStyle:{ color:'#BEC3DA' }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, xAxis: { - data: data.glXz, + data:data.glXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -449,12 +587,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', + type:'solid', color:'#BEC3DA' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -470,6 +608,22 @@ export default { color:'#2F8EE0' }, symbol: "none", //去掉拐角点 + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); diff --git a/psdc-ui/src/views/emonitor/kqyrb/index.vue b/psdc-ui/src/views/emonitor/kqyrb/index.vue index 62bec96..fe4d4aa 100644 --- a/psdc-ui/src/views/emonitor/kqyrb/index.vue +++ b/psdc-ui/src/views/emonitor/kqyrb/index.vue @@ -4,35 +4,35 @@
-

总用电量

-

{{data.totwh}}kWh

+

总用电量

+

{{data.totwh}}kWh

-

当前功率

-

{{data.totp}}kW

+

当前功率

+

{{data.totp}}kW

-

进水温度:

-

{{data.tempIn}}℃

+

进水温度:

+

{{data.tempIn}}℃

-

出水温度:

-

{{data.tempOut}}℃

+

出水温度:

+

{{data.tempOut}}℃

-

运行状态

-

{{data.runStatus}}

+

运行状态

+

{{data.runStatus}}

@@ -238,15 +238,42 @@ export default { myChart.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['日用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.dayXz, + type:'category', + data:data.dayXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -256,12 +283,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -276,6 +303,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -298,15 +341,42 @@ export default { myChart2.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['月用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.emonthXz, + type:'category', + data:data.emonthXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -316,12 +386,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -336,6 +406,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -357,8 +443,18 @@ export default { title: {}, tooltip: { trigger: "axis", + show: true }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, legend: { data: ['进水', '出水'], textStyle:{ @@ -372,8 +468,19 @@ export default { data: data.time, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -388,7 +495,7 @@ export default { } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -446,6 +553,12 @@ export default { myChart3 = echarts.init(document.getElementById("myEcharts3")); myChart3.setOption({ title: {}, + legend:{ + data:['当前功率'], + textStyle: { + color: "white" //标题的颜色 + }, + }, tooltip: { trigger: "axis", show: true @@ -453,12 +566,31 @@ export default { textStyle:{ color:'#BEC3DA' }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, xAxis: { - data: data.glXz, + data:data.glXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -468,12 +600,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', + type:'solid', color:'#BEC3DA' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -489,6 +621,22 @@ export default { color:'#2F8EE0' }, symbol: "none", //去掉拐角点 + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); diff --git a/psdc-ui/src/views/emonitor/wdcgq/index.vue b/psdc-ui/src/views/emonitor/wdcgq/index.vue index fd7b7dc..3ea9188 100644 --- a/psdc-ui/src/views/emonitor/wdcgq/index.vue +++ b/psdc-ui/src/views/emonitor/wdcgq/index.vue @@ -4,8 +4,8 @@
-

{{item.name}}

-

{{item.temp}}℃

+

{{item.name}}

+

{{item.temp}}℃

@@ -87,6 +87,15 @@ export default { trigger: "axis", show: true }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, legend: { selectedMode: 'single', textStyle:{ @@ -197,8 +206,19 @@ export default { ], axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -213,7 +233,7 @@ export default { } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' diff --git a/psdc-ui/src/views/emonitor/xrgl/index.vue b/psdc-ui/src/views/emonitor/xrgl/index.vue index fc8d45e..56f6548 100644 --- a/psdc-ui/src/views/emonitor/xrgl/index.vue +++ b/psdc-ui/src/views/emonitor/xrgl/index.vue @@ -4,35 +4,35 @@
-

总用电量

-

{{data.totwh}}kWh

+

总用电量

+

{{data.totwh}}kWh

-

当前功率

-

{{data.totp}}kW

+

当前功率

+

{{data.totp}}kW

-

进水温度:

-

{{data.tempIn}}℃

+

进水温度:

+

{{data.tempIn}}℃

-

出水温度:

-

{{data.tempOut}}℃

+

出水温度:

+

{{data.tempOut}}℃

-

运行状态

-

{{data.runStatus}}

+

运行状态

+

{{data.runStatus}}

@@ -247,6 +247,12 @@ export default { myChart3 = echarts.init(document.getElementById("myEcharts3")); myChart3.setOption({ title: {}, + legend:{ + data:['当前功率'], + textStyle: { + color: "white" //标题的颜色 + }, + }, tooltip: { trigger: "axis", show: true @@ -254,12 +260,31 @@ export default { textStyle:{ color:'#BEC3DA' }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, xAxis: { - data: data.glXz, + data:data.glXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -269,12 +294,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', + type:'solid', color:'#BEC3DA' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -290,6 +315,22 @@ export default { color:'#2F8EE0' }, symbol: "none", //去掉拐角点 + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -316,15 +357,42 @@ export default { myChart.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['日用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.dayXz, + type:'category', + data:data.dayXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -334,12 +402,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -354,6 +422,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -376,15 +460,42 @@ export default { myChart2.setOption({ title: {}, tooltip: {}, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, + legend:{ + data:['月用电量'], + textStyle: { + color: "white" //标题的颜色 + }, + }, textStyle:{ color:'#BEC3DA' }, xAxis: { - data: data.emonthXz, + type:'category', + data:data.emonthXz, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -394,12 +505,12 @@ export default { splitLine:{ show:true, lineStyle:{ - type:'dashed', - color:'#BEC3DA' + type:'solid', + color:'#f3ffff' } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA' @@ -414,6 +525,22 @@ export default { itemStyle:{ color:'#2F8EE0' }, + markPoint: { + itemStyle: { + normal: { + label: { + color: '#fff', + // fontSize: 9 + // borderColor: '#000', + // borderWidth: 1, + } + } + }, + data: [ + {type: "max", name: "最大值"}, + {type: "min", name: "最小值"} + ] + }, }, ], }); @@ -435,9 +562,20 @@ export default { title: {}, tooltip: { trigger: "axis", + show: true }, + grid:{ + show: true, + top: '20%', + bottom:'15%', + left:'5%', + right:'3%', + borderWidth: 1, + borderColor: '#767da1', + }, legend: { + data: ['进水', '出水'], textStyle:{ color:'#BEC3DA' } @@ -449,8 +587,19 @@ export default { data: data.time, axisLine:{ lineStyle:{ - color:'#BEC3DA', - type:'dashed' + color:'#767da1', + // type:'dashed' + } + }, + axisTick: { + show: false // 去掉x轴刻度 + }, + splitArea: { + show: true, + interval:0, + areaStyle: { + color: ['rgb(54,68,148,.8)', 'rgb(37,51,133,.8)'] //这里重点,用于设置颜色的数组, + //(有了这个属性,那我们完全可以自己在根据某些条件来生成这样一个数组) } } }, @@ -465,7 +614,7 @@ export default { } }, axisLine: { - show: true, + show: false, lineStyle:{ type:'dashed', color:'#BEC3DA'