Browse Source

fix: 点击精准匹配调整跳转订阅设置逻辑

Signed-off-by: tangshizhe <48740614+tangshizhe@users.noreply.github.com>
tangshizhe 1 năm trước cách đây
mục cha
commit
a286066a1d

+ 19 - 3
apps/bigmember_pc/src/views/recommen-list/recommenList.vue

@@ -7,6 +7,9 @@
       <div class="content-config" @click="setKeyEvent">
         <img src="@/assets/images/recommend-hd.png" alt="" />
       </div>
+      <FollowOfficialAccountDialog
+        :visible.sync="toFollowOfficialAccount"
+      ></FollowOfficialAccountDialog>
       <div class="recommend-pushList">
         <div
           class="info-list"
@@ -38,6 +41,7 @@
 
 <script>
 import ArticleItem from '@/components/article-item/ArticleItem.vue'
+import FollowOfficialAccountDialog from '@/components/dialog/FollowOfficialAccountDialog.vue'
 import {
   getViewStatus,
   setSubscribeInfoRead,
@@ -50,7 +54,8 @@ export default {
   name: 'recommendList',
   mixins: [mixinVisited],
   components: {
-    ArticleItem
+    ArticleItem,
+    FollowOfficialAccountDialog
   },
   data() {
     return {
@@ -64,7 +69,8 @@ export default {
         collect: false
       },
       statusList: [],
-      vt: ''
+      vt: '',
+      toFollowOfficialAccount: false
     }
   },
   computed: {
@@ -97,7 +103,17 @@ export default {
       }
     },
     setKeyEvent() {
-      openSelfLink(this.$router.resolve('/set_subscribe/config?vt=' + this.vt))
+      // 前往订阅管理
+      if (this.vt === 'f' || this.vt === 'v') {
+        // 弹窗提示关注公众号
+        this.toFollowOfficialAccount = true
+      } else if (this.vt === 'm') {
+        openSelfLink(this.$router.resolve('/set_subscribe/config'))
+      } else if (this.vt === 's') {
+        // 商机管理跳转老页面(框架内打开)
+        const url = '/entpc/newBus/set_subscribe'
+        window.open(url)
+      }
     },
     // 查看分发状态
     async setShow(id) {

+ 3 - 3
apps/bigmember_pc/src/views/workspace/components/SubscribeList.vue

@@ -32,10 +32,10 @@
         <p v-if="hasKey">您尚未设置关键词</p>
         <p v-else>对不起,没有匹配到数据,请修改订阅设置</p>
         <button class="empty-button mt12" @click="addSet">前往订阅设置</button>
+        <FollowOfficialAccountDialog
+          :visible.sync="toFollowOfficialAccount"
+        ></FollowOfficialAccountDialog>
       </div>
-      <FollowOfficialAccountDialog
-        :visible.sync="toFollowOfficialAccount"
-      ></FollowOfficialAccountDialog>
     </div>
   </ListCard>
 </template>