浏览代码

前端手机号验证接口变化

Michael Wang 5 年之前
父节点
当前提交
7ba5774fd4
共有 1 个文件被更改,包括 3 次插入7 次删除
  1. 3 7
      src/features/OnlineExam/PhoneVerifyForDD.vue

+ 3 - 7
src/features/OnlineExam/PhoneVerifyForDD.vue

@@ -102,15 +102,11 @@ export default {
     },
     async verify() {
       try {
-        const res = await this.$http.post(
+        await this.$http.post(
           `/api/ecs_oe_student/sms/checkSmsCode?phoneNumber=${this.user.phoneNumber}&code=${this.code}`
         );
-        if (res.data.success) {
-          this.phoneModal = false;
-          localStorage.setItem("phoneVerified", "true");
-        } else {
-          this.$Message.error(res.data.returnMsg);
-        }
+        this.phoneModal = false;
+        localStorage.setItem("phoneVerified", "true");
       } catch (error) {
         this.$Message.error({
           content: "验证手机号接口失败,请重试!",