From d9e54388e7fde2462e8b7e0165c5e7da3f202593 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期四, 07 七月 2022 19:07:59 +0800
Subject: [PATCH] add 整合 springdoc-openapi-javadoc 基于代码注释生成文档

---
 ruoyi-common/src/main/java/com/ruoyi/common/core/domain/model/LoginBody.java |  111 +++++++++++++++++++++----------------------------------
 1 files changed, 42 insertions(+), 69 deletions(-)

diff --git a/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/model/LoginBody.java b/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/model/LoginBody.java
index 583b7a6..4a4cfb5 100644
--- a/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/model/LoginBody.java
+++ b/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/model/LoginBody.java
@@ -1,69 +1,42 @@
-package com.ruoyi.common.core.domain.model;
-
-/**
- * 鐢ㄦ埛鐧诲綍瀵硅薄
- * 
- * @author ruoyi
- */
-public class LoginBody
-{
-    /**
-     * 鐢ㄦ埛鍚�
-     */
-    private String username;
-
-    /**
-     * 鐢ㄦ埛瀵嗙爜
-     */
-    private String password;
-
-    /**
-     * 楠岃瘉鐮�
-     */
-    private String code;
-
-    /**
-     * 鍞竴鏍囪瘑
-     */
-    private String uuid;
-
-    public String getUsername()
-    {
-        return username;
-    }
-
-    public void setUsername(String username)
-    {
-        this.username = username;
-    }
-
-    public String getPassword()
-    {
-        return password;
-    }
-
-    public void setPassword(String password)
-    {
-        this.password = password;
-    }
-
-    public String getCode()
-    {
-        return code;
-    }
-
-    public void setCode(String code)
-    {
-        this.code = code;
-    }
-
-    public String getUuid()
-    {
-        return uuid;
-    }
-
-    public void setUuid(String uuid)
-    {
-        this.uuid = uuid;
-    }
-}
+package com.ruoyi.common.core.domain.model;
+
+import com.ruoyi.common.constant.UserConstants;
+import lombok.Data;
+import org.hibernate.validator.constraints.Length;
+
+import javax.validation.constraints.NotBlank;
+
+/**
+ * 鐢ㄦ埛鐧诲綍瀵硅薄
+ *
+ * @author Lion Li
+ */
+
+@Data
+public class LoginBody {
+
+    /**
+     * 鐢ㄦ埛鍚�
+     */
+    @NotBlank(message = "{user.username.not.blank}")
+    @Length(min = UserConstants.USERNAME_MIN_LENGTH, max = UserConstants.USERNAME_MAX_LENGTH, message = "{user.username.length.valid}")
+    private String username;
+
+    /**
+     * 鐢ㄦ埛瀵嗙爜
+     */
+    @NotBlank(message = "{user.password.not.blank}")
+    @Length(min = UserConstants.PASSWORD_MIN_LENGTH, max = UserConstants.PASSWORD_MAX_LENGTH, message = "{user.password.length.valid}")
+    private String password;
+
+    /**
+     * 楠岃瘉鐮�
+     */
+    private String code;
+
+    /**
+     * 鍞竴鏍囪瘑
+     */
+    private String uuid;
+
+}

--
Gitblit v1.9.3