guhongwei 4 years ago
parent
commit
2e1bfecf57
2 changed files with 11 additions and 4 deletions
  1. 10 3
      src/layout/userCenter/heads.vue
  2. 1 1
      src/plugins/setting.js

+ 10 - 3
src/layout/userCenter/heads.vue

@@ -17,22 +17,22 @@
       </div>
       <div class="superlogo">
         <div class="w_1200">
-          <a href="/platlive/market/index">
+          <el-col :span="24" @click.native="linkBtn()">
             <img :src="logo" />
             <span>
               中科在线
             </span>
-          </a>
+          </el-col>
         </div>
       </div>
     </el-row>
   </div>
 </template>
 <script>
+import Vue from 'vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: login } = createNamespacedHelpers('login');
 const { mapActions: dockLogin } = createNamespacedHelpers('dockLogin');
-
 export default {
   name: 'heads',
   props: {},
@@ -67,6 +67,10 @@ export default {
     async toLogin() {
       this.$router.push({ path: '/' });
     },
+    // 返回科技超市页面
+    linkBtn() {
+      this.$router.push({ path: `${process.env.NODE_ENV != 'development' ? '/market/index' : Vue.config.weixin.baseUrl + '/platlive/market/index'}` });
+    },
   },
   computed: {
     ...mapState(['user']),
@@ -134,4 +138,7 @@ export default {
   top: 10px;
   padding: 0 0 0 10px;
 }
+.superlogo:hover {
+  cursor: pointer;
+}
 </style>

+ 1 - 1
src/plugins/setting.js

@@ -2,7 +2,7 @@ import Vue from 'vue';
 
 Vue.config.weixin = {
   // baseUrl: process.env.BASE_URL + 'weixin',
-  baseUrl: 'http://10.16.8.209:9005',
+  baseUrl: `http://${location.host}`,
 };
 
 Vue.config.stomp = {