Commit b7107a4dba6ba04149a4107a99760fdda5f1cd56

Authored by RuoYi
1 parent c0cd2f61

用户手机邮箱必填&密码参数修改

ruoyi-ui/src/views/system/user/index.vue
... ... @@ -416,6 +416,7 @@ export default {
416 416 { required: true, message: "用户密码不能为空", trigger: "blur" }
417 417 ],
418 418 email: [
  419 + { required: true, message: "邮箱地址不能为空", trigger: "blur" },
419 420 {
420 421 type: "email",
421 422 message: "'请输入正确的邮箱地址",
... ... @@ -423,6 +424,7 @@ export default {
423 424 }
424 425 ],
425 426 phonenumber: [
  427 + { required: true, message: "手机号码不能为空", trigger: "blur" },
426 428 {
427 429 pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
428 430 message: "请输入正确的手机号码",
... ... @@ -448,7 +450,7 @@ export default {
448 450 this.sexOptions = response.data;
449 451 });
450 452 this.getConfigKey("sys.user.initPassword").then(response => {
451   - this.initPassword = response.data;
  453 + this.initPassword = response.msg;
452 454 });
453 455 },
454 456 methods: {
... ...
ruoyi/src/main/java/com/ruoyi/project/system/domain/SysUser.java
... ... @@ -7,7 +7,7 @@ import javax.validation.constraints.NotBlank;
7 7 import javax.validation.constraints.Size;
8 8 import org.apache.commons.lang3.builder.ToStringBuilder;
9 9 import org.apache.commons.lang3.builder.ToStringStyle;
10   -import com.fasterxml.jackson.annotation.JsonIgnore;
  10 +import com.fasterxml.jackson.annotation.JsonProperty;
11 11 import com.ruoyi.framework.aspectj.lang.annotation.Excel;
12 12 import com.ruoyi.framework.aspectj.lang.annotation.Excel.ColumnType;
13 13 import com.ruoyi.framework.aspectj.lang.annotation.Excel.Type;
... ... @@ -197,7 +197,7 @@ public class SysUser extends BaseEntity
197 197 this.avatar = avatar;
198 198 }
199 199  
200   - @JsonIgnore
  200 + @JsonProperty
201 201 public String getPassword()
202 202 {
203 203 return password;
... ...