Bladeren bron

修改验证码开关变量名

RuoYi 3 jaren geleden
bovenliggende
commit
e753cea03e
1 gewijzigde bestanden met toevoegingen van 5 en 5 verwijderingen
  1. 5 5
      ruoyi-ui/src/views/register.vue

+ 5 - 5
ruoyi-ui/src/views/register.vue

@@ -29,7 +29,7 @@
29 29
           <svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" />
30 30
         </el-input>
31 31
       </el-form-item>
32
-      <el-form-item prop="code" v-if="captchaOnOff">
32
+      <el-form-item prop="code" v-if="captchaEnabled">
33 33
         <el-input
34 34
           v-model="registerForm.code"
35 35
           auto-complete="off"
@@ -104,7 +104,7 @@ export default {
104 104
         code: [{ required: true, trigger: "change", message: "请输入验证码" }]
105 105
       },
106 106
       loading: false,
107
-      captchaOnOff: true
107
+      captchaEnabled: true
108 108
     };
109 109
   },
110 110
   created() {
@@ -113,8 +113,8 @@ export default {
113 113
   methods: {
114 114
     getCode() {
115 115
       getCodeImg().then(res => {
116
-        this.captchaOnOff = res.captchaOnOff === undefined ? true : res.captchaOnOff;
117
-        if (this.captchaOnOff) {
116
+        this.captchaEnabled = res.captchaEnabled === undefined ? true : res.captchaEnabled;
117
+        if (this.captchaEnabled) {
118 118
           this.codeUrl = "data:image/gif;base64," + res.img;
119 119
           this.registerForm.uuid = res.uuid;
120 120
         }
@@ -134,7 +134,7 @@ export default {
134 134
             }).catch(() => {});
135 135
           }).catch(() => {
136 136
             this.loading = false;
137
-            if (this.captchaOnOff) {
137
+            if (this.captchaEnabled) {
138 138
               this.getCode();
139 139
             }
140 140
           })