You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

32 lines
809 B

<template>
<div id="app">
<router-view />
<theme-picker />
</div>
</template>
<script>
import ThemePicker from "@/components/ThemePicker";
import { getStationConfig } from "@/utils/stationTitle";
export default {
name: "App",
components: { ThemePicker },
metaInfo() {
// 标签页标题按访问 IP 显示站名(如"白杨坪智能巡检系统"),
// 不能直接用 VUE_APP_TITLE,否则会把启动时设置的站名覆盖回去
const stationName = getStationConfig().name;
return {
title: this.$store.state.settings.dynamicTitle && this.$store.state.settings.title,
titleTemplate: title => {
return title ? `${title} - ${stationName}` : stationName
}
}
}
};
</script>
<style scoped>
#app .theme-picker {
display: none;
}
</style>