Browse Source

商品分享:商家名称

panyong 2 years ago
parent
commit
f18dd00c25
2 changed files with 9 additions and 2 deletions
  1. 1 1
      htmldev/cps/src/api/request.js
  2. 8 1
      htmldev/cps/src/views/category/detail/index.vue

+ 1 - 1
htmldev/cps/src/api/request.js

@@ -55,7 +55,7 @@ request.interceptors.request.use(request => {
 
   // 因为微信开发者工具重复授权,本地开发时写死
   if (/^(0|192|10|localhost)/.test(domain)) {
-    request.headers.wechatToken = '7820fddb72c61b89c7d31c3450269da1'
+    request.headers.wechatToken = 'fcb5ce1baa28fba5b43db5e4dc4df04c'
   } else {
     request.headers.wechatToken = getCookieValue('fanbutingwechatToken')
   }

+ 8 - 1
htmldev/cps/src/views/category/detail/index.vue

@@ -145,6 +145,13 @@ export default {
         return result[0].logo
       }
       return ''
+    },
+    businessName () {
+      const result = this.sourceList.filter(item => item.value === this.source)
+      if (result.length) {
+        return result[0].name
+      }
+      return ''
     }
   },
   created () {
@@ -182,7 +189,7 @@ export default {
       }
       // 处理用户ID未获取成功的场景
       if (!this.isFetchLock) {
-        platform.isWeixin && funWxShare('返不停', this.goodsInfo.goods_name, coverImg, this.source === 'taobao' ? `${location.origin}/category/tbLandingPage/${id}/${this.goodsId}` : this.goodsInfo.url)
+        platform.isWeixin && funWxShare(this.businessName, this.goodsInfo.goods_name, coverImg, this.source === 'taobao' ? `${location.origin}/category/tbLandingPage/${id}/${this.goodsId}` : this.goodsInfo.url)
         this.isFetchLock = true
       }
       this.$refs.fbtShareTipInWechat.init()