提交 d99ec762 编写于 作者: KK's avatar KK

多主题

上级 ae6c5abc
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
TARGET=PSSYSAPP TARGET=PSSYSAPP
</#ibiztemplate> </#ibiztemplate>
<template> <template>
<ion-app id="app"> <ion-app id="app" :class="themeClass">
<#if app.getAllRefPSAppViews()??> <#if app.getAllRefPSAppViews()??>
<#list app.getAllRefPSAppViews() as view> <#list app.getAllRefPSAppViews() as view>
<#if view.getViewType() == "APPSTARTVIEW" > <#if view.getViewType() == "APPSTARTVIEW" >
...@@ -20,5 +20,22 @@ TARGET=PSSYSAPP ...@@ -20,5 +20,22 @@ TARGET=PSSYSAPP
import { Component, Vue } from "vue-property-decorator"; import { Component, Vue } from "vue-property-decorator";
@Component({}) @Component({})
export default class App extends Vue { } export default class App extends Vue {
/**
* 当前主题
*
* @readonly
* @memberof App
*/
get themeClass() {
if (this.$router.app.$store.state.selectTheme) {
return this.$router.app.$store.state.selectTheme;
} else if (localStorage.getItem('theme-class')) {
return localStorage.getItem('theme-class');
} else {
return 'app-default-theme';
}
}
}
</script> </script>
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册