ソースを参照

feat(活动邀请好友赚星币): 修改短信参数

曾志翔 2 年 前
コミット
261eddf081
共有2 個のファイルを変更した4 個の追加3 個の削除を含む
  1. 1 1
      pages/activity/invite-user/register.vue
  2. 3 2
      plugins/axios.js

+ 1 - 1
pages/activity/invite-user/register.vue

@@ -136,7 +136,7 @@ export default {
           this.$tongji.trackEvent('活动', '发送短信', '', 0);
           const res = await sendSmsCode(this, {
             type: 'common',
-            authorizationType: 4,
+            authorizationType: 5,
             phone: this.form.phone,
           });
           this.codeTime = 60;

+ 3 - 2
plugins/axios.js

@@ -9,8 +9,9 @@ export default function ({ $axios, $auth, redirect }) {
   });
   $axios.onResponse(async (response) => {
     if (Object.prototype.toString.call(response.data) === '[object Object]') {
-      if ([2, 4, 6013, 6014].includes(response.data.status)) {
-        await $auth.logout();
+      if ([6013, 6014].includes(response.data.status)) {
+        // await $auth.logout();
+        await $auth.reset();
         // await $auth.setUserToken(null);
       }
       if (response.data.status !== 0) {