Lius
11 小时以前 54c22f2f0e98c35e48cdad6c4d0299d08beea630
src/views/mdc/base/modules/GradeSignage/EquipmentSignage.vue
@@ -242,6 +242,7 @@
        rightBottomChart2: null,
        rightBottomChart3: null,
        rightBottomChart1Data: [],
        timingAcquisition: null,
        rightBottomChart2And3Data: [],
        chartQuantity: 3,
        hasLoadedChartDataQuantity: 0,
@@ -282,11 +283,19 @@
    mounted() {
      this.getEquipmentListByApi()
      this.handleWindowResize()
      // 组件挂载后启动定时器
      this.timingAcquisition = setInterval(() => {
        this.getEquipmentStatusAndInfoByApi()
      }, 2000)
      window.addEventListener('resize', this.handleWindowResize)
    },
    beforeDestroy() {
      window.removeEventListener('resize', this.handleWatchHistory)
      // 组件销毁前清除定时器
      if (this.timingAcquisition) {
        clearInterval(this.timingAcquisition)
      }
    },
    methods: {
      getEquipmentListByApi() {
@@ -302,7 +311,7 @@
      getEquipmentStatusAndInfoByApi() {
        const that = this
        this.equipmentStatusAndInfoObj = {}
        //this.equipmentStatusAndInfoObj = {}
        signageApi.getEquipmentOperationStatusAndInfoApi(this.currentProductionId)
          .then(res => {
            if (res.success) {