|
@@ -102,7 +102,7 @@
|
|
|
<el-card class="chart-card" shadow="never">
|
|
|
<template #header>
|
|
|
<div class="flex items-center justify-between">
|
|
|
- <span class="text-base font-medium " style="color: #b6c8da">当日运维成本</span>
|
|
|
+ <span class="text-base font-medium " style="color: #b6c8da">近七日运维成本</span>
|
|
|
</div>
|
|
|
</template>
|
|
|
<div ref="chartContainer" class="h-[290px]"></div>
|
|
@@ -138,7 +138,7 @@
|
|
|
<el-card class="chart-card" shadow="never">
|
|
|
<template #header>
|
|
|
<div class="flex items-center justify-between">
|
|
|
- <span class="text-base font-medium " style="color: #b6c8da">累计注气量统计(m³)</span>
|
|
|
+ <span class="text-base font-medium " style="color: #b6c8da">累计注气/注水量统计</span>
|
|
|
</div>
|
|
|
</template>
|
|
|
<div ref="zqlChartRef" class="h-[300px]"></div>
|
|
@@ -148,7 +148,7 @@
|
|
|
<el-card class="chart-card" shadow="never">
|
|
|
<template #header>
|
|
|
<div class="flex items-center justify-between">
|
|
|
- <span class="text-base font-medium " style="color: #b6c8da">当日注气量统计(m³)</span>
|
|
|
+ <span class="text-base font-medium " style="color: #b6c8da">当日注气/注水量统计</span>
|
|
|
</div>
|
|
|
</template>
|
|
|
<div ref="todayZqlRef" class="h-[300px]"></div>
|
|
@@ -239,6 +239,7 @@ const todayStatus = ref({
|
|
|
const typeData = ref({})
|
|
|
const materialData = ref({})
|
|
|
const orderSevenData = ref({})
|
|
|
+const ywcbSevenData = ref({})
|
|
|
const zqlData = ref({})
|
|
|
const zqlTodayData = ref({})
|
|
|
/** 获取统计数据 */
|
|
@@ -282,6 +283,10 @@ const getStats = () => {
|
|
|
orderSevenData.value = res
|
|
|
initQxChart()
|
|
|
})
|
|
|
+ IotStatApi.getOrderYwcb('rh').then((res) => {
|
|
|
+ ywcbSevenData.value = res
|
|
|
+ initYwcbChart()
|
|
|
+ })
|
|
|
IotStatApi.getMaintenanceStatus('rh').then((res) => {
|
|
|
by.value = res
|
|
|
})
|
|
@@ -401,6 +406,7 @@ const initTodayZqlChart = async () => {
|
|
|
yAxis: [
|
|
|
{
|
|
|
type: 'value',
|
|
|
+ name:'当日注气量(m³)',
|
|
|
axisLabel: {
|
|
|
color: '#B6C8DA',
|
|
|
formatter: '{value}'
|
|
@@ -423,6 +429,7 @@ const initTodayZqlChart = async () => {
|
|
|
},
|
|
|
{
|
|
|
type: 'value',
|
|
|
+ name:'当日注水量(m³)',
|
|
|
axisLabel: {
|
|
|
color: '#B6C8DA',
|
|
|
formatter: '{value}'
|
|
@@ -543,19 +550,16 @@ const initYwcbChart = async () => {
|
|
|
if (!chartContainer.value) return
|
|
|
|
|
|
// 获取数据
|
|
|
- const { months, faults, repairs } = await fetchChartData()
|
|
|
- // const months = ['空压机','增压机','提纯撬']
|
|
|
- // ECharts配置
|
|
|
const option = {
|
|
|
tooltip: {
|
|
|
trigger: 'axis',
|
|
|
axisPointer: {
|
|
|
type: 'shadow'
|
|
|
},
|
|
|
- formatter: (params) => {
|
|
|
- return `${params[0].axisValue}<br/>
|
|
|
- ${params[0].marker} ${params[0].seriesName}: ${params[0].value}`
|
|
|
- }
|
|
|
+ // formatter: (params) => {
|
|
|
+ // return `${params[0].axisValue}<br/>
|
|
|
+ // ${params[0].marker} ${params[0].seriesName}: ${params[0].value}`
|
|
|
+ // }
|
|
|
},
|
|
|
legend: {
|
|
|
data: ['当日运维成本'],
|
|
@@ -572,11 +576,10 @@ const initYwcbChart = async () => {
|
|
|
},
|
|
|
xAxis: {
|
|
|
type: 'category',
|
|
|
- data: zqlTodayData.value.xAxis,
|
|
|
+ data: ywcbSevenData.value.xAxis,
|
|
|
axisLabel: {
|
|
|
- rotate: 45,
|
|
|
- margin: 15,
|
|
|
color: '#B6C8DA',
|
|
|
+ formatter: (value) => value.split('-').join('/')
|
|
|
},
|
|
|
axisLine: {
|
|
|
lineStyle: {
|
|
@@ -588,7 +591,7 @@ const initYwcbChart = async () => {
|
|
|
type: 'value',
|
|
|
axisLabel: {
|
|
|
color: '#B6C8DA',
|
|
|
- formatter: (value) => Math.floor(value).toString()
|
|
|
+ // formatter: (value) => Math.floor(value).toString()
|
|
|
},
|
|
|
splitLine: {
|
|
|
show: true, // 显示水平网格线(默认显示)
|
|
@@ -616,7 +619,7 @@ const initYwcbChart = async () => {
|
|
|
emphasis: {
|
|
|
focus: 'series'
|
|
|
},
|
|
|
- data: repairs
|
|
|
+ data: ywcbSevenData.value.series
|
|
|
}
|
|
|
]
|
|
|
}
|
|
@@ -824,6 +827,7 @@ const initZqlChart = () => {
|
|
|
yAxis: [
|
|
|
{
|
|
|
type: 'value',
|
|
|
+ name: '累计注气量(m³)',
|
|
|
axisLabel: {
|
|
|
color: '#B6C8DA',
|
|
|
formatter: '{value}'
|
|
@@ -846,6 +850,7 @@ const initZqlChart = () => {
|
|
|
},
|
|
|
{
|
|
|
type: 'value',
|
|
|
+ name: '累计注水量(m³)',
|
|
|
axisLabel: {
|
|
|
color: '#B6C8DA',
|
|
|
formatter: '{value}'
|