Răsfoiți Sursa

fix: same phone value watch bug

fenghao 3 ani în urmă
părinte
comite
dfdc3106cb
1 a modificat fișierele cu 14 adăugiri și 0 ștergeri
  1. 14 0
      src/views/platform/profile/components/UserInfoItem.vue

+ 14 - 0
src/views/platform/profile/components/UserInfoItem.vue

@@ -172,6 +172,13 @@ export default {
         })
         return
       }
+      if (this.value === this.initial) {
+        this.$message({
+          type: 'warning',
+          message: `${this.config.tipText}不能相同`
+        })
+        return
+      }
       authcodeSend({
         [this.config.typeKey]: this.value
       })
@@ -215,6 +222,13 @@ export default {
         })
         return
       }
+      if (this.value === this.initial) {
+        this.$message({
+          type: 'warning',
+          message: `${this.config.tipText}不能相同`
+        })
+        return
+      }
       authcodeCheck({
         [this.config.typeKey]: this.value,
         [this.config.codeKey]: this.code