jbb 2 lat temu
rodzic
commit
2af302d0b3

+ 1 - 1
src/components/layouts/TabLayout.vue

@@ -182,7 +182,7 @@ export default {
         changeTitle (title) {
             // 技能博物馆
             // let projectTitle = 'OA办公系统'
-            let projectTitle = '上海萃颠信息科技有限公司'
+            let projectTitle =  this.$store.state.bottonTitle
             // 首页特殊处理
             if (this.$route.path === indexKey) {
                 document.title = projectTitle

+ 2 - 2
src/components/layouts/UserLayout.vue

@@ -7,7 +7,7 @@
         <div class="logo">
           <!-- 技能博物馆 -->
           <!-- <img src="../../assets/logo-cd-left1.png" alt="" /> -->
-          <img :src="this.imgUrl" alt="" />
+          <img :src="this.$store.state.imgUrl" alt="" />
         </div>
 
         <!-- 放表单的盒子 -->
@@ -57,7 +57,7 @@ export default {
         return {}
     },
     created(){
-      this.imgUrl = require(this.imgUrl)
+      // this.imgUrl = require(this.imgUrl)
     },
     mounted () {
         document.body.classList.add('userLayout')

+ 1 - 1
src/components/page/GlobalFooter.vue

@@ -12,7 +12,7 @@
       <!-- Copyright
       <a-icon type="copyright"/>
       2019 <span>JEECG开源社区 出品</span> -->
-      上海萃颠信息科技有限公司出品
+       {{this.$store.state.bottonTitle}}
     </div>
   </div>
 </template>

+ 2 - 2
src/components/page/GlobalLayout.vue

@@ -14,7 +14,7 @@
       >
         <!-- 垂直菜单 横向展示二级三级 -->
         <side-menu
-          mode="vertical"
+          :mode="this.$store.state.mode"
           :menus="menus"
           @menuSelect="menuSelect()"
           :theme="navTheme"
@@ -25,7 +25,7 @@
 
       <side-menu
         v-else
-        mode="vertical"
+        :mode="this.$store.state.mode"
         :menus="menus"
         @menuSelect="myMenuSelect"
         :theme="navTheme"

+ 1 - 1
src/components/page/GlobalNavFooter.vue

@@ -28,7 +28,7 @@
             </a-col>
             <!-- 公司名称 -->
             <a-col :span="8" style="textAlign:right;">
-              <span style="color:#ccc;">上海萃颠信息科技有限公司出品</span>
+              <span style="color:#ccc;">{{this.$store.state.bottonTitle}}</span>
             </a-col>
           </a-row>
         </div>

+ 1 - 1
src/components/tools/Logo.vue

@@ -13,7 +13,7 @@
       <!-- 技能博物馆 -->
       <!-- <img src="~@/assets/logo-cd-left1.png" alt="logo">
       <h1 >OA办公系统</h1>  -->
-      <img :src="this.logoUrl" alt="logo">
+      <img :src="this.$store.state.logoUrl" alt="logo">
       <!-- <h1 >{{ dashboard }}</h1> -->
     </router-link>
   </div>

+ 8 - 0
src/defaultSettings.js

@@ -24,6 +24,14 @@ export default {
   autoHideHeader: false, //  auto hide header
   colorWeak: false,
   multipage: true, //默认多页签模式
+  //登陆界面logo
+  imgUrl : require("@assets/logo-blue.png"),
+  //首页左上角logo
+   logoUrl : require("@assets/logo-cd-left.png"),
+   //菜单样式
+   mode:'inline',
+   //文字信息
+   bottonTitle:'上海萃颠信息科技有限公司',
   // vue-ls options
   storageOptions: {
     namespace: 'pro__', // key prefix

+ 6 - 4
src/main.js

@@ -67,15 +67,17 @@ Vue.prototype.doMian = '/jeecg-boot/'
 Vue.prototype.postFormAction = postFormAction
 Vue.prototype.postDataAction = postAction
 Vue.prototype.getAction = getAction
-//登陆界面logo
-Vue.prototype.imgUrl = require("@assets/logo-blue.png")
-//首页左上角logo
-Vue.prototype.logoUrl = require("@assets/logo-cd-left.png")
+
+
 Vue.use(dataV)
 new Vue({
     router,
     store,
     mounted () {
+        this.$store.state.imgUrl = config.imgUrl
+        this.$store.state.logoUrl = config.logoUrl
+        this.$store.state.bottonTitle = config.bottonTitle
+        this.$store.state.mode = config.mode
         store.commit('SET_SIDEBAR_TYPE', Vue.ls.get(SIDEBAR_TYPE, true))
         store.commit('TOGGLE_THEME', Vue.ls.get(DEFAULT_THEME, config.navTheme))
         store.commit('TOGGLE_LAYOUT_MODE', Vue.ls.get(DEFAULT_LAYOUT_MODE, config.layout))

+ 4 - 1
src/store/index.js

@@ -15,7 +15,10 @@ export default new Vuex.Store({
     permission
   },
   state: {
-
+    imgUrl:'',
+    logoUrl:'',
+    bottonTitle:'',
+    mode:''
   },
   mutations: {