lrf402788946 hace 5 años
padre
commit
2d072c0530
Se han modificado 1 ficheros con 7 adiciones y 2 borrados
  1. 7 2
      src/layout/index/weilai.vue

+ 7 - 2
src/layout/index/weilai.vue

@@ -2,7 +2,7 @@
   <div id="weilai">
     <el-row>
       <el-col :span="24" class="image" v-if="info">
-        <el-link :underline="false" :href="info.url || ''">
+        <el-link :underline="false" @click="turnTo">
           <el-image style="width:100%;height:200px;" :src="info.pic || ''"></el-image>
         </el-link>
       </el-col>
@@ -22,7 +22,12 @@ export default {
   }),
   created() {},
   computed: {},
-  methods: {},
+  methods: {
+    turnTo() {
+      if (this.info.type == '0') window.open(`.${this.info.url}`);
+      else window.open(this.info.url);
+    },
+  },
 };
 </script>