Просмотр исходного кода

优化:登录页获取短信验证码不重置图形验证码

萤火科技 4 лет назад
Родитель
Сommit
8eefcd1af5
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      pages/login/components/main.vue

+ 2 - 2
pages/login/components/main.vue

@@ -122,7 +122,6 @@
         const app = this
         const app = this
         if (!app.isLoading && !app.smsState && app.formValidation(GET_CAPTCHA)) {
         if (!app.isLoading && !app.smsState && app.formValidation(GET_CAPTCHA)) {
           app.sendSmsCaptcha()
           app.sendSmsCaptcha()
-          app.getCaptcha()
         }
         }
       },
       },
 
 
@@ -192,6 +191,7 @@
             // 执行定时器
             // 执行定时器
             app.timer()
             app.timer()
           })
           })
+          .catch(() => app.getCaptcha())
           .finally(() => app.isLoading = false)
           .finally(() => app.isLoading = false)
       },
       },
 
 
@@ -347,4 +347,4 @@
     justify-content: center;
     justify-content: center;
     align-items: center;
     align-items: center;
   }
   }
-</style>
+</style>