guanchunjie hace 3 años
padre
commit
4a3f993329
Se han modificado 1 ficheros con 14 adiciones y 2 borrados
  1. 14 2
      src/components/inputModules/common/Header.vue

+ 14 - 2
src/components/inputModules/common/Header.vue

@@ -2,7 +2,12 @@
   <!-- 顶部登录导航 -->
   <div class="LoginNav">
     <div class="logo">
-      <span class="logo-img"> logo </span>
+      <template v-if="configInfor">
+        <img :src="configInfor.logo_image_url" alt="logo" class="logo-image" />
+      </template>
+      <template v-else>
+        <span class="logo-img"> logo </span>
+      </template>
       <el-menu
         :default-active="activeIndex"
         class="el-menu-demo"
@@ -119,6 +124,7 @@ export default {
   props: [],
   data() {
     return {
+      configInfor: null,
       activeIndex: "2", // 主导航索引
       LoginNavIndex: 0, //下拉框导航索引
       projectName: "",
@@ -409,7 +415,13 @@ export default {
       });
     },
   },
-  created() {},
+  created() {
+    let _this = this;
+    let config = getConfig();
+    if (config) {
+      _this.configInfor = JSON.parse(config);
+    }
+  },
   mounted() {
     let _this = this;
     let user = getToken();