Files
admin-govern/src/views/govern/device/control/supplementaryRecruitment.vue

44 lines
1.3 KiB
Vue
Raw Normal View History

2024-07-22 10:35:01 +08:00
<template>
2024-09-26 10:01:41 +08:00
<div class="default-main device">
2024-12-09 16:30:40 +08:00
<currentDevice ref="currentDeviceRef" v-if="activeName == '0'" />
<offLineDataImport ref="currentDeviceRef" v-else-if="activeName == '1'" />
2024-07-22 10:35:01 +08:00
</div>
</template>
<script lang="ts" setup>
2024-10-16 16:57:04 +08:00
import { ref, onMounted, watch, nextTick } from 'vue'
import currentDevice from './supplementaryRecruitment/currentDevice.vue'
2024-12-09 16:30:40 +08:00
import offLineDataImport from '@/views/govern/device/control/offLineDataImport/index.vue'
import { useRoute } from 'vue-router'
const route = useRoute()
2024-12-09 16:30:40 +08:00
const activeName = ref('')
2024-10-16 16:57:04 +08:00
const currentDeviceRef = ref()
watch(
2024-10-16 16:57:04 +08:00
() => activeName.value,
(val, oldVal) => {
2024-12-09 16:30:40 +08:00
// if (val == '0') {
// nextTick(() => {
// currentDeviceRef.value && currentDeviceRef.value.getMakeUpDataList(route.query)
// })
// } else if (val == '1') {
nextTick(() => {
currentDeviceRef.value && currentDeviceRef.value.getMakeUpDataList(route.query)
})
// }
},
{
2024-10-16 16:57:04 +08:00
immediate: true,
deep: true
}
)
onMounted(() => {
2024-12-09 16:30:40 +08:00
activeName.value = route.query.activeName
// currentDeviceRef.value && currentDeviceRef.value.getMakeUpDataList(route.query)
2024-07-22 10:35:01 +08:00
})
</script>
2024-09-26 10:01:41 +08:00
<style lang="scss" scoped>
2024-10-16 16:57:04 +08:00
.device {
2024-11-06 13:25:42 +08:00
height: calc(100vh - 130px);
2024-09-26 10:01:41 +08:00
}
</style>