From 2cef955017c735c2828e69f878d3d6b44200074f Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期二, 22 八月 2023 16:54:57 +0800
Subject: [PATCH] 111
---
screen_standard/src/views/index.vue | 74 ++++++++++++++++++++++++++++---------
1 files changed, 56 insertions(+), 18 deletions(-)
diff --git a/screen_standard/src/views/index.vue b/screen_standard/src/views/index.vue
index ee207a7..edb7242 100644
--- a/screen_standard/src/views/index.vue
+++ b/screen_standard/src/views/index.vue
@@ -190,8 +190,8 @@
</template>
<script setup>
- import { reactive, ref, onBeforeUnmount, onUnmounted, nextTick, computed, watch, onActivated } from 'vue'
- import { getTop, getStockList, getWorkPlansList, getProcedureProcessList, getRecordLogPage, getDeviceCheckPage, getUnqualified7DayData, getUnqualifiedCateData } from '@/utils/api.js'
+ import { reactive, ref, onMounted, nextTick, onUnmounted, computed, watch, onActivated } from 'vue'
+ import { getPlanData, getTop, getStockList, getWorkPlansList, getProcedureProcessList, getRecordLogPage, getDeviceCheckPage, getUnqualified7DayData, getUnqualifiedCateData } from '@/utils/api.js'
import { useCounterStore } from '@/stores/counter.js'
import * as echarts from 'echarts'
import { useRouter } from 'vue-router'
@@ -255,13 +255,36 @@
init()
}
})
-
- onActivated(() => {
- console.log('departId', departId.value)
- if (!departId.value) return
- init()
- console.log('onActivated')
- })
+ // router.afterEach((to) => {
+ // if (to.fullPath === '/') {
+ // if (!departId.value) return
+ // // data.production = []
+ // // data.marginStatistics = []
+ // // data.plannedProgress = []
+ // // data.processProgress = []
+ // // data.log = []
+ // // init()
+ // } else {
+ // clearTimeout(timer.value)
+ // clearTimeout(timer1.value)
+ // clearTimeout(timer2.value)
+ // clearTimeout(timer3.value)
+ // clearTimeout(timer4.value)
+ // }
+ // })
+ // router.beforeEach((to) => {
+ // console.log(to);
+ // if (to.fullPath === '/') {
+ // if (!departId.value) return
+ // init()
+ // } else {
+ // clearTimeout(timer.value)
+ // clearTimeout(timer1.value)
+ // clearTimeout(timer2.value)
+ // clearTimeout(timer3.value)
+ // clearTimeout(timer4.value)
+ // }
+ // })
start1()
@@ -343,6 +366,11 @@
})
setTypeChart()
}
+ })
+ // getPlanData
+ getPlanData(companyId.value, departId.value)
+ .then(res => {
+ enterprise.setNum(res)
})
}
@@ -526,13 +554,13 @@
option && myChart.setOption(option);
}
- onBeforeUnmount(()=>{
- clearTimeout(timer.value)
- clearTimeout(timer1.value)
- clearTimeout(timer2.value)
- clearTimeout(timer3.value)
- clearTimeout(timer4.value)
- })
+ // onBeforeUnmount(()=>{
+ // clearTimeout(timer.value)
+ // clearTimeout(timer1.value)
+ // clearTimeout(timer2.value)
+ // clearTimeout(timer3.value)
+ // clearTimeout(timer4.value)
+ // })
onUnmounted(()=>{
clearTimeout(timer.value)
clearTimeout(timer1.value)
@@ -754,6 +782,15 @@
}
}
}
+
+ // onUnmounted(() => {
+
+ // })
+
+ onMounted(() => {
+ console.log('11111')
+ init()
+ })
</script>
<style lang="scss" scoped>
@@ -1260,8 +1297,9 @@
position: relative;
.content_right_top_nr_bottom_yuan {
position: absolute;
- top: 63%;
- left: 37%;
+ top: 50%;
+ left: 50%;
+ transform: translate(-50%, 53%);
z-index: 999;
width: 114px;
height: 114px;
--
Gitblit v1.9.3