web
5 天以前 01b9e7244825cac11146e3961cafa6525dad56f1
src/views/screen/temperature/graphic/index.vue
@@ -1,10 +1,11 @@
<script setup>
import {ref, onMounted, watch} from "vue";
import {ref, onMounted} from "vue";
import * as echarts from 'echarts/core';
import {getTemperaturePointList} from '@/api/screen/index.js'
import Quarter from "@/components/Quarter";
import moment from "moment";
import { getGraphicData } from '@/api/screen/graphic/index.js'
import { debounce } from '@/utils/tool.js'
const menuList = ref([])
@@ -163,6 +164,14 @@
    })
}
// 监听页面大小变化,改变echarts的大小
window.onresize = debounce(function () {
    charts?.forEach(el => {
        el.resize()
    })
}, 500, true)
// 全屏操作
const handleFullScreen = () => {
    graphicRef.value.requestFullscreen()
@@ -225,6 +234,7 @@
// 获取报表数据
const getChartData = (point = '') => {
    chartData.value = []; //先赋值为空,强制元素重载
    const data = {
        type: timeType.value,
        pointId: point,
@@ -448,6 +458,7 @@
                    border-radius: 8px;
                    .charts {
                        width: 100%;
                        height: 100%;
                    }
                }