refacor: 为大屏单独设置显示逻辑

This commit is contained in:
nightdays 2025-11-17 17:58:19 +08:00
parent e57b9b4865
commit a4dcff069d
2 changed files with 25 additions and 1 deletions

View File

@ -1,11 +1,26 @@
<template>
<div id="app">
<template v-if="pageLoaded">
<template v-if="!route.meta.screen">
<Index ></Index>
</template>
<router-view v-else></router-view>
</template>
</div>
</template>
<script setup>
import { ref } from 'vue'
import { useRoute } from 'vue-router'
import Index from "./views/index.vue";
import { onMounted } from 'vue';
const route = useRoute()
const pageLoaded = ref(false)
onMounted(() => {
setTimeout(()=>{
pageLoaded.value = true
}, 50)
})
</script>
<style lang="scss" scoped>

View File

@ -32,6 +32,15 @@ const routes = [
name: 'yhzevent',
component: () => import('../views/SnowEventManagement/index.vue')
},
{
path: '/airSkyLand',
name: 'airskyland',
meta: {
screen: true
},
component: () => import('../views/airSkyLand/AirSkyLand.vue')
}
]
const router = createRouter({