소스 검색

fix: 点击收藏未登录跳转到登录

Signed-off-by: tangshizhe <48740614+tangshizhe@users.noreply.github.com>
tangshizhe 1 년 전
부모
커밋
dd9bc2769e
1개의 변경된 파일5개의 추가작업 그리고 0개의 파일을 삭제
  1. 5 0
      jydocs-mobile/src/views/details/details.vue

+ 5 - 0
jydocs-mobile/src/views/details/details.vue

@@ -623,6 +623,11 @@ export default class extends Vue {
   }
 
   canged () {
+    // 未登录跳转登录
+    if (!this.loginInfo) {
+      window.location.href = '/jyapp/free/login?to=back'
+      return
+    }
     if (this.collectd === 0) {
       this.getAdd({ docId: this.docIds }).then((res: any) => {
         if (res.error_code === 0) {