From 3e49ff6a3db6710bc327d99384d4b8fc6d474da4 Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期四, 27 六月 2024 13:44:09 +0800
Subject: [PATCH] Merge branch 'master' of http://8.140.179.55:20000/r/pipIrr-SV

---
 pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoBa/BaUser.java |   61 ++++++++++++++++++++++++++++--
 1 files changed, 56 insertions(+), 5 deletions(-)

diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoBa/BaUser.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoBa/BaUser.java
index a1bc809..92317e8 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoBa/BaUser.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoBa/BaUser.java
@@ -2,11 +2,17 @@
 
 import com.alibaba.fastjson2.annotation.JSONField;
 import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
-import com.baomidou.mybatisplus.annotation.*;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
 import com.dy.common.mybatis.envm.Deleted;
 import com.dy.common.mybatis.envm.Disabled;
 import com.dy.common.po.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import jakarta.validation.constraints.NotEmpty;
 import lombok.*;
+import org.hibernate.validator.constraints.Length;
 
 import java.util.List;
 
@@ -31,6 +37,7 @@
 @ToString
 @NoArgsConstructor
 @AllArgsConstructor
+@Schema(name = "鐢ㄦ埛瀹炰綋")
 public class BaUser implements BaseEntity {
 
     public static final long serialVersionUID = 202310100926001L;
@@ -44,50 +51,94 @@
     ASSIGN_UUID(4), //鍏ㄥ眬鍞竴鐨� uuid
     */
     @JSONField(serializeUsing= ObjectWriterImplToString.class)
-    @TableId(type = IdType.INPUT)
+    @TableId(value = "id", type = IdType.INPUT)
+    @Schema(description = "瀹炰綋id", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
+    //public Long userId;
     public Long id;
+
+
+    @Schema(description = "鎵�灞炵墖鍖篒D", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
+    @JSONField(serializeUsing= ObjectWriterImplToString.class)
+    @TableField(value = "blockId")
+    public Long blockId ;
 
     /**
      * 鐢ㄦ埛濮撳悕
      */
-    public String name;
+    @Schema(description = "濮撳悕", requiredMode = Schema.RequiredMode.REQUIRED)
+    @NotEmpty(message = "濮撳悕涓嶈兘涓虹┖") //涓嶈兘涓虹┖涔熶笉鑳戒负null
+    @Length(message = "濮撳悕涓嶅ぇ浜巤max}瀛楋紝涓嶅皬浜巤min}瀛�", min = 2, max = 25)
+    public String userName;
 
     /**
      * 鎵嬫満鍙凤紝鎵嬫満鍙风敤浜庣櫥褰曠郴缁�
      */
+    @Schema(description = "鎵嬫満鍙�", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
+    @Length(message = "鎵嬫満鍙峰繀椤粄max}浣嶆暟鎹�", min = 11, max = 11)
     public String phone;
 
     /**
      * 瀵嗙爜锛屽瘑鐮佺殑MD5鍔犲瘑
      */
+    @Schema(description = "瀵嗙爜", requiredMode = Schema.RequiredMode.REQUIRED)
+    @Length(message = "瀵嗙爜蹇呴』{max}浣嶆暟鎹�", min = 6, max = 6)
     public String password;
 
     /**
      * 渚涙按鏈烘瀯鏍囩
      */
     @TableField(value = "orgTag")
+    @JSONField(serialize = false)
     public String orgTag;
 
     /**
      * 鏄惁瓒呯骇绠$悊鍛� 1:鏄�,0:鍚�
      */
+    @Schema(hidden = true)
     @TableField(value = "supperAdmin")
+    @JSONField(serialize = false)
     public Byte supperAdmin;
 
     /**
      * 鏄惁绂佺敤 0:鍚�,1:鏄�
      */
+    @Schema(description = "鏄惁绂佺敤", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
     public Disabled disabled;
 
     /**
      * 鏄惁鍒犻櫎: 0琛ㄧず鏈垹闄�  1琛ㄧず鍒犻櫎.
      */
+    @Schema(description = "鍒犻櫎鏍囪瘑锛岃〃鍗曚笉鐢ㄥ~鍐�", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
     public Deleted deleted;
 
+
     /**
-     * 鐢ㄦ埛鎵�鎷ユ湁鐨勬潈闄�
+     * 鐢ㄦ埛鎵�灞炶鑹睮d
      */
+    @Schema(description = "鎵�褰掕鑹诧紙鎵�灞炶鑹睮D瀛楃涓叉暟缁勶級", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
     @TableField(exist = false)
+    public String[] roleIds ;
+
+    /**
+     * 鐢ㄦ埛鎵�灞炶鑹�
+     */
+    @Schema(description = "鎵�褰掕鑹插垪琛紝鐢ㄤ簬鏄剧ず锛岃〃鍗曚笉鐢ㄥ~鍐�", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
+    @TableField(exist = false)
+    public List<?> roleList ;
+
+    /**
+     * 鐢ㄦ埛鎵�鎷ユ湁鐨勬潈闄愶紝閽堝鐧诲綍搴旂敤
+     */
+    @Schema(hidden = true)
+    @TableField(exist = false)
+    @JSONField(serialize = false)
     public List<Integer> privileges;
-    //public transient List<Integer> privileges;//姝ょ鏂瑰紡鍙橀噺涓嶅瓨搴擄紝 涔熶笉鍙備笌搴忓垪鍖栦簡
+
+
+    /**
+     * 鎵�灞炵墖鍖哄悕绉�
+     */
+    @Schema(description = "鎵�灞炵墖鍖哄悕绉帮紝鐢ㄤ簬鏄剧ず锛岃〃鍗曚笉鐢ㄥ~鍐�", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
+    @TableField(exist = false)
+    public String blockName ;
 }
\ No newline at end of file

--
Gitblit v1.8.0