Browse Source

解决商城店铺列表点击空白地方链接会失效的问题

huangb 7 years ago
parent
commit
d4e4b87856
1 changed files with 5 additions and 2 deletions
  1. 5 2
      components/provider/Suppliers.vue

+ 5 - 2
components/provider/Suppliers.vue

@@ -19,7 +19,7 @@
             <a @click="goStoreApply" class="btn-sure"><button class="btn btn-primary">立即入驻</button></a>
           </td>
         </tr>
-        <nuxt-link tag="tr" :to="'/store/' + store.uuid" :key="store.uuid" v-for="store in stores.content" v-if="store">
+        <tr :key="store.uuid" v-for="store in stores.content" v-if="store" @click="goStoreDetail(store)">
           <td>
             <div class="logo">
               <a :href="'/store/' + store.uuid" target="_blank"><img :src="store.logoUrl || '/images/store/common/default.png'" :alt="store.storeName"></a>
@@ -35,7 +35,7 @@
           <td class="vertical-middle" style="text-align: center">
             <a :href="'/store/' + store.uuid" target="_blank"><button class="btn btn-primary">进入店铺</button></a>
           </td>
-        </nuxt-link>
+        </tr>
         <tr v-if="!stores.content || stores.content.length == 0" class="no-content">
           <td colspan="10" class="text-center" style="line-height: 1125px; font-size: 20px;">
             <i class="fa fa-smile-o fa-lg"></i> 暂无店铺信息
@@ -129,6 +129,9 @@ export default {
       this.pageParams.keyword = this.keyword === '' ? null : this.keyword
 
       this.pageCommodity(this.pageParams)
+    },
+    goStoreDetail (store) {
+      window.open('/store/' + store.uuid)
     }
   }
 }