Merge branch 'master' of https://gitee.com/youlaiorg/youlai-boot into feature/noticews
# Conflicts: # src/main/java/com/youlai/boot/platform/websocket/service/impl/WebsocketServiceImpl.java # src/main/java/com/youlai/boot/system/controller/NoticeController.java # src/main/java/com/youlai/boot/system/controller/NoticeStatusController.java # src/main/java/com/youlai/boot/system/converter/NoticeConverter.java # src/main/java/com/youlai/boot/system/converter/NoticeStatusConverter.java # src/main/java/com/youlai/boot/system/mapper/NoticeMapper.java # src/main/java/com/youlai/boot/system/mapper/NoticeStatusMapper.java # src/main/java/com/youlai/boot/system/model/entity/Notice.java # src/main/java/com/youlai/boot/system/model/entity/NoticeStatus.java # src/main/java/com/youlai/boot/system/model/form/NoticeForm.java # src/main/java/com/youlai/boot/system/model/form/NoticeStatusForm.java # src/main/java/com/youlai/boot/system/model/query/NoticeQuery.java # src/main/java/com/youlai/boot/system/model/query/NoticeStatusQuery.java # src/main/java/com/youlai/boot/system/model/vo/NoticeStatusVO.java # src/main/java/com/youlai/boot/system/model/vo/NoticeVO.java # src/main/java/com/youlai/boot/system/service/NoticeService.java # src/main/java/com/youlai/boot/system/service/NoticeStatusService.java # src/main/java/com/youlai/boot/system/service/impl/NoticeServiceImpl.java # src/main/java/com/youlai/boot/system/service/impl/NoticeStatusServiceImpl.java
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
@Schema(description = "数据表字段VO")
|
||||
@Data
|
||||
public class ColumnMetaData {
|
||||
|
||||
/**
|
||||
* 字段名称
|
||||
*/
|
||||
private String columnName;
|
||||
|
||||
/**
|
||||
* 字段类型
|
||||
*/
|
||||
private String dataType;
|
||||
|
||||
/**
|
||||
* 字段描述
|
||||
*/
|
||||
private String columnComment;
|
||||
|
||||
/**
|
||||
* 字段长度
|
||||
*/
|
||||
private Integer characterMaximumLength;
|
||||
|
||||
/**
|
||||
* 是否主键(1-是 0-否)
|
||||
*/
|
||||
private Integer isPrimaryKey;
|
||||
|
||||
/**
|
||||
* 是否可为空(1-是 0-否)
|
||||
*/
|
||||
private String isNullable;
|
||||
|
||||
/**
|
||||
* 字符集
|
||||
*/
|
||||
private String characterSetName;
|
||||
|
||||
/**
|
||||
* 排序规则
|
||||
*/
|
||||
private String collationName;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 角色权限业务对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2023/11/29
|
||||
*/
|
||||
@Data
|
||||
public class RolePermsBO {
|
||||
|
||||
/**
|
||||
* 角色编码
|
||||
*/
|
||||
private String roleCode;
|
||||
|
||||
/**
|
||||
* 权限标识集合
|
||||
*/
|
||||
private Set<String> perms;
|
||||
|
||||
}
|
||||
84
src/main/java/com/youlai/boot/system/model/bo/RouteBO.java
Normal file
84
src/main/java/com/youlai/boot/system/model/bo/RouteBO.java
Normal file
@@ -0,0 +1,84 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import com.youlai.boot.common.enums.MenuTypeEnum;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 路由
|
||||
*/
|
||||
@Data
|
||||
public class RouteBO {
|
||||
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 父菜单ID
|
||||
*/
|
||||
private Long parentId;
|
||||
|
||||
/**
|
||||
* 菜单名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 菜单类型(1-菜单 2-目录 3-外链 4-按钮)
|
||||
*/
|
||||
private MenuTypeEnum type;
|
||||
|
||||
/**
|
||||
* 路由名称(Vue Router 中定义的路由名称)
|
||||
*/
|
||||
private String routeName;
|
||||
|
||||
/**
|
||||
* 路由路径(Vue Router 中定义的 URL 路径)
|
||||
*/
|
||||
private String routePath;
|
||||
|
||||
/**
|
||||
* 组件路径(vue页面完整路径,省略.vue后缀)
|
||||
*/
|
||||
private String component;
|
||||
|
||||
/**
|
||||
* 权限标识
|
||||
*/
|
||||
private String perm;
|
||||
|
||||
/**
|
||||
* 显示状态(1:显示;0:隐藏)
|
||||
*/
|
||||
private Integer visible;
|
||||
|
||||
/**
|
||||
* 排序
|
||||
*/
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 菜单图标
|
||||
*/
|
||||
private String icon;
|
||||
|
||||
/**
|
||||
* 跳转路径
|
||||
*/
|
||||
private String redirect;
|
||||
|
||||
/**
|
||||
* 【目录】只有一个子路由是否始终显示(1:是 0:否)
|
||||
*/
|
||||
private Integer alwaysShow;
|
||||
|
||||
/**
|
||||
* 【菜单】是否开启页面缓存(1:是 0:否)
|
||||
*/
|
||||
private Integer keepAlive;
|
||||
|
||||
/**
|
||||
* 【菜单】路由参数
|
||||
*/
|
||||
private String params;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
|
||||
/**
|
||||
* 数据表元数据
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@Data
|
||||
public class TableMetaData {
|
||||
|
||||
/**
|
||||
* 表名称
|
||||
*/
|
||||
private String tableName;
|
||||
|
||||
/**
|
||||
* 表描述
|
||||
*/
|
||||
private String tableComment;
|
||||
|
||||
/**
|
||||
* 排序规则
|
||||
*/
|
||||
private String tableCollation;
|
||||
|
||||
/**
|
||||
* 存储引擎
|
||||
*/
|
||||
private String engine;
|
||||
|
||||
/**
|
||||
* 字符集
|
||||
*/
|
||||
private String charset;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private String createTime;
|
||||
|
||||
}
|
||||
72
src/main/java/com/youlai/boot/system/model/bo/UserBO.java
Normal file
72
src/main/java/com/youlai/boot/system/model/bo/UserBO.java
Normal file
@@ -0,0 +1,72 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 用户持久化对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/6/10
|
||||
*/
|
||||
@Data
|
||||
public class UserBO {
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 账户名
|
||||
*/
|
||||
private String username;
|
||||
|
||||
/**
|
||||
* 昵称
|
||||
*/
|
||||
private String nickname;
|
||||
|
||||
/**
|
||||
* 手机号
|
||||
*/
|
||||
private String mobile;
|
||||
|
||||
/**
|
||||
* 性别(1->男;2->女)
|
||||
*/
|
||||
private Integer gender;
|
||||
|
||||
/**
|
||||
* 头像URL
|
||||
*/
|
||||
private String avatar;
|
||||
|
||||
/**
|
||||
* 邮箱
|
||||
*/
|
||||
private String email;
|
||||
|
||||
/**
|
||||
* 状态: 1->启用;0->禁用
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
private String deptName;
|
||||
|
||||
/**
|
||||
* 角色名称,多个使用英文逗号(,)分割
|
||||
*/
|
||||
private String roleNames;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date createTime;
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.youlai.boot.system.model.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 特定日期访问统计
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@Data
|
||||
public class VisitCount {
|
||||
|
||||
/**
|
||||
* 日期 yyyy-MM-dd
|
||||
*/
|
||||
private String date;
|
||||
|
||||
/**
|
||||
* 访问次数
|
||||
*/
|
||||
private Integer count;
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* 验证码响应对象
|
||||
*
|
||||
* @author Ray Hao
|
||||
* @since 2023/03/24
|
||||
*/
|
||||
@Schema(description = "验证码响应对象")
|
||||
@Builder
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class CaptchaResult {
|
||||
|
||||
@Schema(description = "验证码ID")
|
||||
private String captchaKey;
|
||||
|
||||
@Schema(description = "验证码图片Base64字符串")
|
||||
private String captchaBase64;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* WebSocket 消息体
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class ChatMessage {
|
||||
|
||||
/**
|
||||
* 发送者
|
||||
*/
|
||||
private String sender;
|
||||
|
||||
/**
|
||||
* 消息内容
|
||||
*/
|
||||
private String content;
|
||||
|
||||
}
|
||||
16
src/main/java/com/youlai/boot/system/model/dto/FileInfo.java
Normal file
16
src/main/java/com/youlai/boot/system/model/dto/FileInfo.java
Normal file
@@ -0,0 +1,16 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
@Schema(description = "文件对象")
|
||||
@Data
|
||||
public class FileInfo {
|
||||
|
||||
@Schema(description = "文件名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "文件URL")
|
||||
private String url;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
||||
@Schema(description ="登录响应对象")
|
||||
@Data
|
||||
@Builder
|
||||
public class LoginResult {
|
||||
|
||||
@Schema(description = "访问token")
|
||||
private String accessToken;
|
||||
|
||||
@Schema(description = "token 类型",example = "Bearer")
|
||||
private String tokenType;
|
||||
|
||||
@Schema(description = "刷新token")
|
||||
private String refreshToken;
|
||||
|
||||
@Schema(description = "过期时间(单位:毫秒)")
|
||||
private Long expires;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 用户认证信息
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/10/22
|
||||
*
|
||||
*/
|
||||
@Data
|
||||
public class UserAuthInfo {
|
||||
|
||||
private Long userId;
|
||||
|
||||
private String username;
|
||||
|
||||
private String nickname;
|
||||
|
||||
private Long deptId;
|
||||
|
||||
private String password;
|
||||
|
||||
private Integer status;
|
||||
|
||||
private Set<String> roles;
|
||||
|
||||
private Set<String> perms;
|
||||
|
||||
private Integer dataScope;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.alibaba.excel.annotation.format.DateTimeFormat;
|
||||
import com.alibaba.excel.annotation.write.style.ColumnWidth;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 用户导出视图对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/4/11 8:46
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ColumnWidth(20)
|
||||
public class UserExportDTO {
|
||||
|
||||
@ExcelProperty(value = "用户名")
|
||||
private String username;
|
||||
|
||||
@ExcelProperty(value = "用户昵称")
|
||||
private String nickname;
|
||||
|
||||
@ExcelProperty(value = "部门")
|
||||
private String deptName;
|
||||
|
||||
@ExcelProperty(value = "性别")
|
||||
private String gender;
|
||||
|
||||
@ExcelProperty(value = "手机号码")
|
||||
private String mobile;
|
||||
|
||||
@ExcelProperty(value = "邮箱")
|
||||
private String email;
|
||||
|
||||
@ExcelProperty(value = "创建时间")
|
||||
@DateTimeFormat("yyyy/MM/dd HH:mm:ss")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.youlai.boot.system.model.dto;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 用户导入对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/4/10
|
||||
*/
|
||||
@Data
|
||||
public class UserImportDTO {
|
||||
|
||||
@ExcelProperty(value = "用户名")
|
||||
private String username;
|
||||
|
||||
@ExcelProperty(value = "昵称")
|
||||
private String nickname;
|
||||
|
||||
@ExcelProperty(value = "性别")
|
||||
private String genderLabel;
|
||||
|
||||
@ExcelProperty(value = "手机号码")
|
||||
private String mobile;
|
||||
|
||||
@ExcelProperty(value = "邮箱")
|
||||
private String email;
|
||||
|
||||
@ExcelProperty("角色")
|
||||
private String roleCodes;
|
||||
|
||||
@ExcelProperty("部门")
|
||||
private String deptCode;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import com.youlai.boot.common.base.BaseEntity;
|
||||
import lombok.Data;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
/**
|
||||
* 系统配置 实体
|
||||
*
|
||||
* @author Theo
|
||||
* @since 2024-07-29 11:17:26
|
||||
*/
|
||||
@Schema(description = "系统配置")
|
||||
@TableName("sys_config")
|
||||
@Data
|
||||
public class Config extends BaseEntity {
|
||||
|
||||
@Schema(description = "配置名称")
|
||||
private String configName;
|
||||
|
||||
@Schema(description = "配置键")
|
||||
private String configKey;
|
||||
|
||||
@Schema(description = "配置值")
|
||||
private String configValue;
|
||||
|
||||
@Schema(description = "描述、备注")
|
||||
private String remark;
|
||||
|
||||
@Schema(description = "创建人ID")
|
||||
@TableField(fill = FieldFill.INSERT)
|
||||
private Long createBy;
|
||||
|
||||
@Schema(description = "更新人ID")
|
||||
@TableField(fill = FieldFill.UPDATE)
|
||||
private Long updateBy;
|
||||
|
||||
@TableLogic(value = "0", delval = "1")
|
||||
private Integer isDeleted;
|
||||
|
||||
}
|
||||
59
src/main/java/com/youlai/boot/system/model/entity/Dept.java
Normal file
59
src/main/java/com/youlai/boot/system/model/entity/Dept.java
Normal file
@@ -0,0 +1,59 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.boot.common.base.BaseEntity;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* 部门实体
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/06/23
|
||||
*/
|
||||
@TableName("sys_dept")
|
||||
@Getter
|
||||
@Setter
|
||||
public class Dept extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 部门编码
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 父节点id
|
||||
*/
|
||||
private Long parentId;
|
||||
|
||||
/**
|
||||
* 父节点id路径
|
||||
*/
|
||||
private String treePath;
|
||||
|
||||
/**
|
||||
* 显示顺序
|
||||
*/
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 状态(1-正常 0-禁用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 创建人 ID
|
||||
*/
|
||||
private Long createBy;
|
||||
|
||||
/**
|
||||
* 更新人 ID
|
||||
*/
|
||||
private Long updateBy;
|
||||
|
||||
}
|
||||
37
src/main/java/com/youlai/boot/system/model/entity/Dict.java
Normal file
37
src/main/java/com/youlai/boot/system/model/entity/Dict.java
Normal file
@@ -0,0 +1,37 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.boot.common.base.BaseEntity;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 字典实体
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/12/17
|
||||
*/
|
||||
@TableName("sys_dict")
|
||||
@Data
|
||||
public class Dict extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 类型名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 类型编码
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 状态(0:正常;1:禁用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 字典项实体
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/12/17
|
||||
*/
|
||||
@TableName("sys_dict_item")
|
||||
@Data
|
||||
public class DictItem implements Serializable {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 字典类ID
|
||||
*/
|
||||
private Long dictId;
|
||||
|
||||
/**
|
||||
* 字典项名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 字典项值
|
||||
*/
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* 排序
|
||||
*/
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 状态(1-正常,0-禁用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
}
|
||||
90
src/main/java/com/youlai/boot/system/model/entity/Log.java
Normal file
90
src/main/java/com/youlai/boot/system/model/entity/Log.java
Normal file
@@ -0,0 +1,90 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
import com.youlai.boot.common.enums.LogModuleEnum;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 系统日志 实体类
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@TableName("sys_log")
|
||||
@Data
|
||||
public class Log implements Serializable {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 日志模块
|
||||
*/
|
||||
private LogModuleEnum module;
|
||||
|
||||
|
||||
/**
|
||||
* 日志内容
|
||||
*/
|
||||
private String content;
|
||||
|
||||
/**
|
||||
* 请求路径
|
||||
*/
|
||||
private String requestUri;
|
||||
|
||||
/**
|
||||
* IP 地址
|
||||
*/
|
||||
private String ip;
|
||||
|
||||
/**
|
||||
* 省份
|
||||
*/
|
||||
private String province;
|
||||
|
||||
/**
|
||||
* 城市
|
||||
*/
|
||||
private String city;
|
||||
|
||||
/**
|
||||
* 浏览器
|
||||
*/
|
||||
private String browser;
|
||||
|
||||
/**
|
||||
* 浏览器版本
|
||||
*/
|
||||
private String browserVersion;
|
||||
|
||||
/**
|
||||
* 终端系统
|
||||
*/
|
||||
private String os;
|
||||
|
||||
/**
|
||||
* 执行时间(毫秒)
|
||||
*/
|
||||
private Long executionTime;
|
||||
|
||||
|
||||
/**
|
||||
* 创建人ID
|
||||
*/
|
||||
private Long createBy;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@TableField(fill = FieldFill.INSERT)
|
||||
private LocalDateTime createTime;
|
||||
|
||||
|
||||
}
|
||||
113
src/main/java/com/youlai/boot/system/model/entity/Menu.java
Normal file
113
src/main/java/com/youlai/boot/system/model/entity/Menu.java
Normal file
@@ -0,0 +1,113 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
|
||||
import com.youlai.boot.common.enums.MenuTypeEnum;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 菜单实体
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2023/3/6
|
||||
*/
|
||||
@TableName("sys_menu")
|
||||
@Getter
|
||||
@Setter
|
||||
public class Menu {
|
||||
/**
|
||||
* 菜单ID
|
||||
*/
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 父菜单ID
|
||||
*/
|
||||
private Long parentId;
|
||||
|
||||
/**
|
||||
* 菜单名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 菜单类型(1-菜单;2-目录;3-外链;4-按钮权限)
|
||||
*/
|
||||
private MenuTypeEnum type;
|
||||
|
||||
/**
|
||||
* 路由名称(Vue Router 中定义的路由名称)
|
||||
*/
|
||||
private String routeName;
|
||||
|
||||
/**
|
||||
* 路由路径(Vue Router 中定义的 URL 路径)
|
||||
*/
|
||||
private String routePath;
|
||||
|
||||
/**
|
||||
* 组件路径(vue页面完整路径,省略.vue后缀)
|
||||
*/
|
||||
private String component;
|
||||
|
||||
/**
|
||||
* 权限标识
|
||||
*/
|
||||
private String perm;
|
||||
|
||||
/**
|
||||
* 显示状态(1:显示;0:隐藏)
|
||||
*/
|
||||
private Integer visible;
|
||||
|
||||
/**
|
||||
* 排序
|
||||
*/
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 菜单图标
|
||||
*/
|
||||
private String icon;
|
||||
|
||||
/**
|
||||
* 跳转路径
|
||||
*/
|
||||
private String redirect;
|
||||
|
||||
/**
|
||||
* 父节点路径,以英文逗号(,)分割
|
||||
*/
|
||||
private String treePath;
|
||||
|
||||
/**
|
||||
* 【菜单】是否开启页面缓存(1:开启;0:关闭)
|
||||
*/
|
||||
private Integer keepAlive;
|
||||
|
||||
/**
|
||||
* 【目录】只有一个子路由是否始终显示(1:是 0:否)
|
||||
*/
|
||||
private Integer alwaysShow;
|
||||
|
||||
/**
|
||||
* 路由参数
|
||||
*/
|
||||
@TableField(updateStrategy = FieldStrategy.ALWAYS)
|
||||
private String params;
|
||||
|
||||
|
||||
@TableField(fill = FieldFill.INSERT)
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@TableField(fill = FieldFill.INSERT_UPDATE)
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
package com.youlai.system.model.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.system.common.base.BaseEntity;
|
||||
|
||||
/**
|
||||
* 通知公告实体对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-27 10:31
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("sys_notice")
|
||||
public class Notice extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 通知标题
|
||||
*/
|
||||
private String title;
|
||||
/**
|
||||
* 通知内容
|
||||
*/
|
||||
private String content;
|
||||
/**
|
||||
* 通知类型
|
||||
*/
|
||||
private Integer noticeType;
|
||||
/**
|
||||
* 发布人
|
||||
*/
|
||||
private Long releaseBy;
|
||||
/**
|
||||
* 优先级(0-低 1-中 2-高)
|
||||
*/
|
||||
private Integer priority;
|
||||
/**
|
||||
* 目标类型(0-全体 1-指定)
|
||||
*/
|
||||
private Integer tarType;
|
||||
/**
|
||||
* 发布状态(0-未发布 1已发布 2已撤回)
|
||||
*/
|
||||
private Integer sendStatus;
|
||||
/**
|
||||
* 发布时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime sendTime;
|
||||
/**
|
||||
* 撤回时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime recallTime;
|
||||
/**
|
||||
* 创建人ID
|
||||
*/
|
||||
private Long createBy;
|
||||
/**
|
||||
* 更新人ID
|
||||
*/
|
||||
private Long updateBy;
|
||||
/**
|
||||
* 逻辑删除标识(0-未删除 1-已删除)
|
||||
*/
|
||||
private Integer isDelete;
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
package com.youlai.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.system.common.base.BaseEntity;
|
||||
|
||||
/**
|
||||
* 用户公告状态实体对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-28 16:56
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("sys_notice_status")
|
||||
public class NoticeStatus implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 公共通知id
|
||||
*/
|
||||
private Long noticeId;
|
||||
/**
|
||||
* 用户id
|
||||
*/
|
||||
private Long userId;
|
||||
/**
|
||||
* 读取状态,0未读,1已读取
|
||||
*/
|
||||
private Long readStatus;
|
||||
/**
|
||||
* 用户阅读时间
|
||||
*/
|
||||
private LocalDateTime readTiem;
|
||||
}
|
||||
53
src/main/java/com/youlai/boot/system/model/entity/Role.java
Normal file
53
src/main/java/com/youlai/boot/system/model/entity/Role.java
Normal file
@@ -0,0 +1,53 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.boot.common.base.BaseEntity;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* 角色实体
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/6/23
|
||||
*/
|
||||
@TableName("sys_role")
|
||||
@Getter
|
||||
@Setter
|
||||
public class Role extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 角色编码
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 显示顺序
|
||||
*/
|
||||
private Integer sort;
|
||||
|
||||
/**
|
||||
* 角色状态(1-正常 0-停用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 数据权限
|
||||
*/
|
||||
private Integer dataScope;
|
||||
|
||||
/**
|
||||
* 创建人 ID
|
||||
*/
|
||||
private Long createBy;
|
||||
|
||||
/**
|
||||
* 更新人 ID
|
||||
*/
|
||||
private Long updateBy;
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
|
||||
/**
|
||||
* 角色和菜单关联表
|
||||
*/
|
||||
@TableName("sys_role_menu")
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class RoleMenu {
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
private Long roleId;
|
||||
|
||||
/**
|
||||
* 菜单ID
|
||||
*/
|
||||
private Long menuId;
|
||||
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
}
|
||||
70
src/main/java/com/youlai/boot/system/model/entity/User.java
Normal file
70
src/main/java/com/youlai/boot/system/model/entity/User.java
Normal file
@@ -0,0 +1,70 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.youlai.boot.common.base.BaseEntity;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* 用户实体
|
||||
*/
|
||||
@TableName("sys_user")
|
||||
@Getter
|
||||
@Setter
|
||||
public class User extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 用户名
|
||||
*/
|
||||
private String username;
|
||||
|
||||
/**
|
||||
* 昵称
|
||||
*/
|
||||
private String nickname;
|
||||
|
||||
/**
|
||||
* 性别((1-男 2-女 0-保密)
|
||||
*/
|
||||
private Integer gender;
|
||||
|
||||
/**
|
||||
* 密码
|
||||
*/
|
||||
private String password;
|
||||
|
||||
/**
|
||||
* 部门ID
|
||||
*/
|
||||
private Long deptId;
|
||||
|
||||
/**
|
||||
* 用户头像
|
||||
*/
|
||||
private String avatar;
|
||||
|
||||
/**
|
||||
* 联系方式
|
||||
*/
|
||||
private String mobile;
|
||||
|
||||
/**
|
||||
* 状态((1-正常 0-禁用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 用户邮箱
|
||||
*/
|
||||
private String email;
|
||||
|
||||
/**
|
||||
* 创建人 ID
|
||||
*/
|
||||
private Long createBy;
|
||||
|
||||
/**
|
||||
* 更新人 ID
|
||||
*/
|
||||
private Long updateBy;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.youlai.boot.system.model.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
|
||||
/**
|
||||
* 用户和角色关联表
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/12/17
|
||||
*/
|
||||
@TableName("sys_user_role")
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class UserRole {
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
private Long roleId;
|
||||
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 系统配置 表单实体
|
||||
*
|
||||
* @author Theo
|
||||
* @since 2024-07-29 11:17:26
|
||||
*/
|
||||
@Data
|
||||
@Schema(description = "系统配置Form实体")
|
||||
public class ConfigForm implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "主键")
|
||||
private Long id;
|
||||
|
||||
@NotBlank(message = "配置名称不能为空")
|
||||
@Schema(description = "配置名称")
|
||||
private String configName;
|
||||
|
||||
@NotBlank(message = "配置键不能为空")
|
||||
@Schema(description = "配置键")
|
||||
private String configKey;
|
||||
|
||||
@NotBlank(message = "配置值不能为空")
|
||||
@Schema(description = "配置值")
|
||||
private String configValue;
|
||||
|
||||
@Schema(description = "描述、备注")
|
||||
private String remark;
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.validator.constraints.Range;
|
||||
|
||||
@Schema(description = "部门表单对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class DeptForm {
|
||||
|
||||
@Schema(description="部门ID", example = "1001")
|
||||
private Long id;
|
||||
|
||||
@Schema(description="部门名称", example = "研发部")
|
||||
private String name;
|
||||
|
||||
@Schema(description="部门编号", example = "RD001")
|
||||
private String code;
|
||||
|
||||
@Schema(description="父部门ID", example = "1000")
|
||||
@NotNull(message = "父部门ID不能为空")
|
||||
private Long parentId;
|
||||
|
||||
@Schema(description="状态(1:启用;0:禁用)", example = "1")
|
||||
@Range(min = 0, max = 1, message = "状态值不正确")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="排序(数字越小排名越靠前)", example = "1")
|
||||
private Integer sort;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.validator.constraints.Range;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 字典表单对象
|
||||
*
|
||||
* @author Ray Hao
|
||||
* @since 2.9.0
|
||||
*/
|
||||
@Schema(description = "字典")
|
||||
@Data
|
||||
public class DictForm {
|
||||
|
||||
@Schema(description = "字典ID",example = "1")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "字典名称",example = "性别")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "字典编码", example ="gender")
|
||||
private String code;
|
||||
|
||||
@Schema(description = "字典状态(1-启用,0-禁用)", example = "1")
|
||||
@Range(min = 0, max = 1, message = "字典状态不正确")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "字典数据项列表",example = "[{\"id\":1,\"name\":\"男\",\"value\":\"1\",\"sort\":1,\"status\":1},{\"id\":2,\"name\":\"女\",\"value\":\"2\",\"sort\":2,\"status\":1}]")
|
||||
private List<DictItem> dictItems;
|
||||
|
||||
@Schema(description = "字典数据项")
|
||||
@Getter
|
||||
@Setter
|
||||
public static class DictItem {
|
||||
|
||||
@Schema(description = "字典ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "字典名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "字典值")
|
||||
private String value;
|
||||
|
||||
@Schema(description = "排序")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description = "状态(1-启用,0-禁用)")
|
||||
private Integer status;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 修改邮箱表单
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/19
|
||||
*/
|
||||
@Schema(description = "修改邮箱表单")
|
||||
@Data
|
||||
public class EmailChangeForm {
|
||||
|
||||
@Schema(description = "原密码")
|
||||
private String email;
|
||||
|
||||
@Schema(description = "验证码")
|
||||
private String code;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import com.youlai.boot.common.enums.MenuTypeEnum;
|
||||
import com.youlai.boot.common.model.KeyValue;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import org.hibernate.validator.constraints.Range;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 菜单表单对象
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/06/23
|
||||
*/
|
||||
@Schema(description = "菜单表单对象")
|
||||
@Data
|
||||
public class MenuForm {
|
||||
|
||||
@Schema(description = "菜单ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "父菜单ID")
|
||||
private Long parentId;
|
||||
|
||||
@Schema(description = "菜单名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "菜单类型(1-菜单 2-目录 3-外链 4-按钮)")
|
||||
private MenuTypeEnum type;
|
||||
|
||||
@Schema(description = "路由名称")
|
||||
private String routeName;
|
||||
|
||||
@Schema(description = "路由路径")
|
||||
private String routePath;
|
||||
|
||||
@Schema(description = "组件路径(vue页面完整路径,省略.vue后缀)")
|
||||
private String component;
|
||||
|
||||
@Schema(description = "权限标识")
|
||||
private String perm;
|
||||
|
||||
@Schema(description = "显示状态(1:显示;0:隐藏)")
|
||||
@Range(max = 1, min = 0, message = "显示状态不正确")
|
||||
private Integer visible;
|
||||
|
||||
@Schema(description = "排序(数字越小排名越靠前)")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description = "菜单图标")
|
||||
private String icon;
|
||||
|
||||
@Schema(description = "跳转路径")
|
||||
private String redirect;
|
||||
|
||||
@Schema(description = "【菜单】是否开启页面缓存", example = "1")
|
||||
private Integer keepAlive;
|
||||
|
||||
@Schema(description = "【目录】只有一个子路由是否始终显示", example = "1")
|
||||
private Integer alwaysShow;
|
||||
|
||||
@Schema(description = "路由参数")
|
||||
private List<KeyValue> params;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 修改手机表单
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/19
|
||||
*/
|
||||
@Schema(description = "修改手机表单")
|
||||
@Data
|
||||
public class MobileBindingForm {
|
||||
|
||||
@Schema(description = "原密码")
|
||||
private String mobile;
|
||||
|
||||
@Schema(description = "验证码")
|
||||
private String code;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
package com.youlai.system.model.form;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 通知公告表单对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-27 10:31
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Schema(description = "通知公告表单对象")
|
||||
public class NoticeForm implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "通知标题")
|
||||
@NotBlank(message = "通知标题不能为空")
|
||||
@Size(max=50, message="通知标题长度不能超过50个字符")
|
||||
private String title;
|
||||
|
||||
@Schema(description = "通知内容")
|
||||
@NotBlank(message = "通知内容不能为空")
|
||||
@Size(max=65535, message="通知内容长度不能超过65535个字符")
|
||||
private String content;
|
||||
|
||||
@Schema(description = "通知类型")
|
||||
private Integer noticeType;
|
||||
|
||||
@Schema(description = "发布人")
|
||||
@NotNull(message = "发布人不能为空")
|
||||
private Long releaseBy;
|
||||
|
||||
@Schema(description = "优先级(0-低 1-中 2-高)")
|
||||
private Integer priority;
|
||||
|
||||
@Schema(description = "目标类型(0-全体 1-指定)")
|
||||
private Integer tarType;
|
||||
|
||||
@Schema(description = "发布状态(0-未发布 1已发布 2已撤回)")
|
||||
private Integer sendStatus;
|
||||
|
||||
@Schema(description = "发布时间")
|
||||
@NotNull(message = "发布时间不能为空")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime sendTime;
|
||||
|
||||
@Schema(description = "撤回时间")
|
||||
@NotNull(message = "撤回时间不能为空")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime recallTime;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.youlai.system.model.form;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 用户公告状态表单对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-28 16:56
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Schema(description = "用户公告状态表单对象")
|
||||
public class NoticeStatusForm implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 修改密码表单
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/13
|
||||
*/
|
||||
@Schema(description = "修改密码表单")
|
||||
@Data
|
||||
public class PasswordChangeForm {
|
||||
|
||||
@Schema(description = "原密码")
|
||||
private String oldPassword;
|
||||
|
||||
@Schema(description = "新密码")
|
||||
private String newPassword;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 重置密码表单
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/13
|
||||
*/
|
||||
@Schema(description = "重置密码表单")
|
||||
@Data
|
||||
public class PasswordResetForm {
|
||||
|
||||
@Schema(description = "用户ID")
|
||||
private Long userId;
|
||||
|
||||
@Schema(description = "密码")
|
||||
private String password;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
// import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import org.hibernate.validator.constraints.Range;
|
||||
|
||||
@Schema(description = "角色表单对象")
|
||||
@Data
|
||||
public class RoleForm {
|
||||
|
||||
@Schema(description="角色ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description="角色名称")
|
||||
@NotBlank(message = "角色名称不能为空")
|
||||
private String name;
|
||||
|
||||
@Schema(description="角色编码")
|
||||
@NotBlank(message = "角色编码不能为空")
|
||||
private String code;
|
||||
|
||||
@Schema(description="排序")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description="角色状态(1-正常;0-停用)")
|
||||
@Range(max = 1, min = 0, message = "角色状态不正确")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="数据权限")
|
||||
private Integer dataScope;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.Pattern;
|
||||
import org.hibernate.validator.constraints.Range;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户表单对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/4/12 11:04
|
||||
*/
|
||||
@Schema(description = "用户表单对象")
|
||||
@Data
|
||||
public class UserForm {
|
||||
|
||||
@Schema(description="用户ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description="用户名")
|
||||
@NotBlank(message = "用户名不能为空")
|
||||
private String username;
|
||||
|
||||
@Schema(description="昵称")
|
||||
@NotBlank(message = "昵称不能为空")
|
||||
private String nickname;
|
||||
|
||||
|
||||
@Schema(description="手机号码")
|
||||
@Pattern(regexp = "^$|^1(3\\d|4[5-9]|5[0-35-9]|6[2567]|7[0-8]|8\\d|9[0-35-9])\\d{8}$", message = "手机号码格式不正确")
|
||||
private String mobile;
|
||||
|
||||
@Schema(description="性别")
|
||||
private Integer gender;
|
||||
|
||||
@Schema(description="用户头像")
|
||||
private String avatar;
|
||||
|
||||
@Schema(description="邮箱")
|
||||
private String email;
|
||||
|
||||
@Schema(description="用户状态(1:正常;0:禁用)")
|
||||
@Range(min = 0, max = 1, message = "用户状态不正确")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="部门ID")
|
||||
private Long deptId;
|
||||
|
||||
@Schema(description="角色ID集合")
|
||||
@NotEmpty(message = "用户角色不能为空")
|
||||
private List<Long> roleIds;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
package com.youlai.boot.system.model.form;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 个人中心用户信息
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/13
|
||||
*/
|
||||
@Schema(description = "个人中心用户信息")
|
||||
@Data
|
||||
public class UserProfileForm {
|
||||
|
||||
@Schema(description = "用户ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "用户名")
|
||||
private String username;
|
||||
|
||||
@Schema(description = "用户昵称")
|
||||
private String nickname;
|
||||
|
||||
@Schema(description = "头像URL")
|
||||
private String avatar;
|
||||
|
||||
@Schema(description = "性别")
|
||||
private Integer gender;
|
||||
|
||||
@Schema(description = "手机号")
|
||||
private String mobile;
|
||||
|
||||
@Schema(description = "邮箱")
|
||||
private String email;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* 系统配置查询对象
|
||||
*
|
||||
* @author Theo
|
||||
* @since 2024-7-29 11:38:00
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Schema(description = "系统配置分页查询")
|
||||
public class ConfigPageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(配置项名称/配置项值)")
|
||||
private String keywords;
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 部门查询对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/6/11
|
||||
*/
|
||||
@Schema(description ="部门分页查询对象")
|
||||
@Data
|
||||
public class DeptQuery {
|
||||
|
||||
@Schema(description="关键字(部门名称)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="状态(1->正常;0->禁用)")
|
||||
private Integer status;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
@Schema(description ="字典数据项分页查询对象")
|
||||
@Data
|
||||
public class DictPageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(字典项名称)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="字典编码")
|
||||
private String typeCode;
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 日志分页查询对象
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@Schema(description = "日志分页查询对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class LogPageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(日志内容/请求路径/请求方法/地区/浏览器/终端系统)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="操作时间范围")
|
||||
List<String> createTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 菜单查询对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/10/28
|
||||
*/
|
||||
@Schema(description ="部门分页查询对象")
|
||||
@Data
|
||||
public class MenuQuery {
|
||||
|
||||
@Schema(description="关键字(菜单名称)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="状态(1->显示;0->隐藏)")
|
||||
private Integer status;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.youlai.system.model.query;
|
||||
|
||||
import com.youlai.system.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 通知公告分页查询对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-27 10:31
|
||||
*/
|
||||
@Schema(description ="通知公告查询对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class NoticeQuery extends BasePageQuery {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "通知标题")
|
||||
private String title;
|
||||
@Schema(description = "通知内容")
|
||||
private String content;
|
||||
@Schema(description = "通知类型")
|
||||
private Integer noticeType;
|
||||
@Schema(description = "发布人")
|
||||
private Long releaseBy;
|
||||
@Schema(description = "优先级(0-低 1-中 2-高)")
|
||||
private Integer priority;
|
||||
@Schema(description = "目标类型(0-全体 1-指定)")
|
||||
private Integer tarType;
|
||||
@Schema(description = "发布状态(0-未发布 1已发布 2已撤回)")
|
||||
private Integer sendStatus;
|
||||
@Schema(description = "发布时间")
|
||||
private List<String> sendTime;
|
||||
@Schema(description = "撤回时间")
|
||||
private List<String> recallTime;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.youlai.system.model.query;
|
||||
|
||||
import com.youlai.system.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户公告状态分页查询对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-28 16:56
|
||||
*/
|
||||
@Schema(description ="用户公告状态查询对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class NoticeStatusQuery extends BasePageQuery {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "id")
|
||||
private Long id;
|
||||
@Schema(description = "公共通知id")
|
||||
private Long noticeId;
|
||||
@Schema(description = "用户id")
|
||||
private Integer userId;
|
||||
@Schema(description = "读取状态,0未读,1已读取")
|
||||
private Long readStatus;
|
||||
@Schema(description = "用户阅读时间")
|
||||
private List<String> readTiem;
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 权限分页查询对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/1/14 22:22
|
||||
*/
|
||||
@Data
|
||||
@Schema
|
||||
public class PermPageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="权限名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description="菜单ID")
|
||||
private Long menuId;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 角色分页查询对象
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2022/6/3
|
||||
*/
|
||||
@Schema(description = "角色分页查询对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class RolePageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(角色名称/角色编码)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="开始日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDateTime startDate;
|
||||
|
||||
@Schema(description="结束日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDateTime endDate;
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 数据表分页查询对象
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@Schema(description = "数据表分页查询对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class TablePageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(表名)")
|
||||
private String keywords;
|
||||
|
||||
/**
|
||||
* 排除的表名
|
||||
*/
|
||||
@JsonIgnore
|
||||
private List<String> excludeTables;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package com.youlai.boot.system.model.query;
|
||||
|
||||
import com.youlai.boot.common.base.BasePageQuery;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户分页查询对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/1/14
|
||||
*/
|
||||
@Schema(description ="用户分页查询对象")
|
||||
@Data
|
||||
public class UserPageQuery extends BasePageQuery {
|
||||
|
||||
@Schema(description="关键字(用户名/昵称/手机号)")
|
||||
private String keywords;
|
||||
|
||||
@Schema(description="用户状态")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="部门ID")
|
||||
private Long deptId;
|
||||
|
||||
@Schema(description="创建时间范围")
|
||||
private List<String> createTime;
|
||||
|
||||
}
|
||||
38
src/main/java/com/youlai/boot/system/model/vo/ConfigVO.java
Normal file
38
src/main/java/com/youlai/boot/system/model/vo/ConfigVO.java
Normal file
@@ -0,0 +1,38 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 系统配置视图对象
|
||||
*
|
||||
* @author Theo
|
||||
* @since 2024-07-30 14:49
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@Schema(description = "系统配置VO")
|
||||
public class ConfigVO {
|
||||
|
||||
@Schema(description = "主键")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "配置名称")
|
||||
private String configName;
|
||||
|
||||
@Schema(description = "配置键")
|
||||
private String configKey;
|
||||
|
||||
@Schema(description = "配置值")
|
||||
private String configValue;
|
||||
|
||||
@Schema(description = "描述、备注")
|
||||
private String remark;
|
||||
}
|
||||
42
src/main/java/com/youlai/boot/system/model/vo/DeptVO.java
Normal file
42
src/main/java/com/youlai/boot/system/model/vo/DeptVO.java
Normal file
@@ -0,0 +1,42 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
@Schema(description = "部门视图对象")
|
||||
@Data
|
||||
public class DeptVO {
|
||||
|
||||
@Schema(description = "部门ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "父部门ID")
|
||||
private Long parentId;
|
||||
|
||||
@Schema(description = "部门名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "部门编号")
|
||||
private String code;
|
||||
|
||||
@Schema(description = "排序")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description = "状态(1:启用;0:禁用)")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "子部门")
|
||||
private List<DeptVO> children;
|
||||
|
||||
@Schema(description = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm")
|
||||
private LocalDateTime createTime;
|
||||
@Schema(description = "修改时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 字典分页VO
|
||||
*
|
||||
* @author Ray
|
||||
* @since 0.0.1
|
||||
*/
|
||||
@Schema(description = "字典分页对象")
|
||||
@Getter
|
||||
@Setter
|
||||
public class DictPageVO {
|
||||
|
||||
@Schema(description = "字典ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "字典名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "字典编码")
|
||||
private String code;
|
||||
|
||||
@Schema(description = "字典状态(1-启用,0-禁用)")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description = "字典项列表")
|
||||
private List<DictItem> dictItems;
|
||||
|
||||
@Schema(description = "字典")
|
||||
@Getter
|
||||
@Setter
|
||||
public static class DictItem {
|
||||
|
||||
@Schema(description = "字典项ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "字典项名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "字典项值")
|
||||
private String value;
|
||||
|
||||
@Schema(description = "排序")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description = "状态(1-启用,0-禁用)")
|
||||
private Integer status;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
@Schema(description = "代码生成代码预览VO")
|
||||
@Data
|
||||
public class GeneratorPreviewVO {
|
||||
|
||||
@Schema(description = "生成文件路径")
|
||||
private String path;
|
||||
|
||||
@Schema(description = "生成文件名称",example = "SysUser.java" )
|
||||
private String fileName;
|
||||
|
||||
@Schema(description = "生成文件内容")
|
||||
private String content;
|
||||
|
||||
}
|
||||
59
src/main/java/com/youlai/boot/system/model/vo/LogPageVO.java
Normal file
59
src/main/java/com/youlai/boot/system/model/vo/LogPageVO.java
Normal file
@@ -0,0 +1,59 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.youlai.boot.common.enums.LogModuleEnum;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 系统日志分页VO
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2.10.0
|
||||
*/
|
||||
@Data
|
||||
@Schema(description = "系统日志分页VO")
|
||||
public class LogPageVO implements Serializable {
|
||||
|
||||
@Schema(description = "主键")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "日志模块")
|
||||
private LogModuleEnum module;
|
||||
|
||||
@Schema(description = "日志内容")
|
||||
private String content;
|
||||
|
||||
@Schema(description = "请求路径")
|
||||
private String requestUri;
|
||||
|
||||
@Schema(description = "请求方法")
|
||||
private String method;
|
||||
|
||||
@Schema(description = "IP 地址")
|
||||
private String ip;
|
||||
|
||||
@Schema(description = "地区")
|
||||
private String region;
|
||||
|
||||
@Schema(description = "浏览器")
|
||||
private String browser;
|
||||
|
||||
@Schema(description = "终端系统")
|
||||
private String os;
|
||||
|
||||
@Schema(description = "执行时间(毫秒)")
|
||||
private Long executionTime;
|
||||
|
||||
@Schema(description = "创建人ID")
|
||||
private Long createBy;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Schema(description = "操作人")
|
||||
private String operator;
|
||||
}
|
||||
54
src/main/java/com/youlai/boot/system/model/vo/MenuVO.java
Normal file
54
src/main/java/com/youlai/boot/system/model/vo/MenuVO.java
Normal file
@@ -0,0 +1,54 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import com.youlai.boot.common.enums.MenuTypeEnum;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Schema(description ="菜单视图对象")
|
||||
@Data
|
||||
public class MenuVO {
|
||||
|
||||
@Schema(description = "菜单ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "父菜单ID")
|
||||
private Long parentId;
|
||||
|
||||
@Schema(description = "菜单名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description="菜单类型")
|
||||
private MenuTypeEnum type;
|
||||
|
||||
@Schema(description = "路由名称")
|
||||
private String routeName;
|
||||
|
||||
@Schema(description = "路由路径")
|
||||
private String routePath;
|
||||
|
||||
@Schema(description = "组件路径")
|
||||
private String component;
|
||||
|
||||
@Schema(description = "菜单排序(数字越小排名越靠前)")
|
||||
private Integer sort;
|
||||
|
||||
@Schema(description = "菜单是否可见(1:显示;0:隐藏)")
|
||||
private Integer visible;
|
||||
|
||||
@Schema(description = "ICON")
|
||||
private String icon;
|
||||
|
||||
@Schema(description = "跳转路径")
|
||||
private String redirect;
|
||||
|
||||
@Schema(description="按钮权限标识")
|
||||
private String perm;
|
||||
|
||||
@Schema(description = "子菜单")
|
||||
@JsonInclude(value = JsonInclude.Include.NON_NULL)
|
||||
private List<MenuVO> children;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
package com.youlai.system.model.vo;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 用户公告状态视图对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-28 16:56
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Schema( description = "用户公告状态视图对象")
|
||||
public class NoticeStatusVO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "id")
|
||||
private Long id;
|
||||
@Schema(description = "公共通知id")
|
||||
private Long noticeId;
|
||||
@Schema(description = "用户id")
|
||||
private Integer userId;
|
||||
@Schema(description = "读取状态,0未读,1已读取")
|
||||
private Long readStatus;
|
||||
@Schema(description = "用户阅读时间")
|
||||
private LocalDateTime readTiem;
|
||||
}
|
||||
48
src/main/java/com/youlai/boot/system/model/vo/NoticeVO.java
Normal file
48
src/main/java/com/youlai/boot/system/model/vo/NoticeVO.java
Normal file
@@ -0,0 +1,48 @@
|
||||
package com.youlai.system.model.vo;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 通知公告视图对象
|
||||
*
|
||||
* @author youlaitech
|
||||
* @since 2024-08-27 10:31
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Schema( description = "通知公告视图对象")
|
||||
public class NoticeVO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Long id;
|
||||
@Schema(description = "通知标题")
|
||||
private String title;
|
||||
@Schema(description = "通知内容")
|
||||
private String content;
|
||||
@Schema(description = "通知类型")
|
||||
private Integer noticeType;
|
||||
@Schema(description = "发布人")
|
||||
private Long releaseBy;
|
||||
@Schema(description = "优先级(0-低 1-中 2-高)")
|
||||
private Integer priority;
|
||||
@Schema(description = "目标类型(0-全体 1-指定)")
|
||||
private Integer tarType;
|
||||
@Schema(description = "发布状态(0-未发布 1已发布 2已撤回)")
|
||||
private Integer sendStatus;
|
||||
@Schema(description = "发布时间")
|
||||
private LocalDateTime sendTime;
|
||||
@Schema(description = "撤回时间")
|
||||
private LocalDateTime recallTime;
|
||||
@Schema(description = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Schema(description = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
@Schema(description ="角色分页对象")
|
||||
@Data
|
||||
public class RolePageVO {
|
||||
|
||||
@Schema(description="角色ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description="角色名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description="角色编码")
|
||||
private String code;
|
||||
|
||||
@Schema(description="角色状态")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="排序")
|
||||
private Integer sort;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime updateTime;
|
||||
}
|
||||
63
src/main/java/com/youlai/boot/system/model/vo/RouteVO.java
Normal file
63
src/main/java/com/youlai/boot/system/model/vo/RouteVO.java
Normal file
@@ -0,0 +1,63 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 菜单路由视图对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2020/11/28
|
||||
*/
|
||||
@Schema(description = "路由对象")
|
||||
@Data
|
||||
@JsonInclude(JsonInclude.Include.NON_EMPTY)
|
||||
public class RouteVO {
|
||||
|
||||
@Schema(description = "路由路径", example = "user")
|
||||
private String path;
|
||||
|
||||
@Schema(description = "组件路径", example = "system/user/index")
|
||||
private String component;
|
||||
|
||||
@Schema(description = "跳转链接", example = "https://www.youlai.tech")
|
||||
private String redirect;
|
||||
|
||||
@Schema(description = "路由名称")
|
||||
private String name;
|
||||
|
||||
@Schema(description = "路由属性")
|
||||
private Meta meta;
|
||||
|
||||
@Schema(description = "路由属性类型")
|
||||
@Data
|
||||
public static class Meta {
|
||||
|
||||
@Schema(description = "路由title")
|
||||
private String title;
|
||||
|
||||
@Schema(description = "ICON")
|
||||
private String icon;
|
||||
|
||||
@Schema(description = "是否隐藏(true-是 false-否)", example = "true")
|
||||
private Boolean hidden;
|
||||
|
||||
@Schema(description = "【菜单】是否开启页面缓存", example = "true")
|
||||
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||
private Boolean keepAlive;
|
||||
|
||||
@Schema(description = "【目录】只有一个子路由是否始终显示", example = "true")
|
||||
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||
private Boolean alwaysShow;
|
||||
|
||||
@Schema(description = "路由参数")
|
||||
private Map<String,String> params;
|
||||
}
|
||||
|
||||
@Schema(description = "子路由列表")
|
||||
private List<RouteVO> children;
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
|
||||
@Schema(description = "表视图对象")
|
||||
@Data
|
||||
public class TablePageVO {
|
||||
|
||||
@Schema(description = "表名称", example = "sys_user")
|
||||
private String tableName;
|
||||
|
||||
@Schema(description = "表描述",example = "用户表")
|
||||
private String tableComment;
|
||||
|
||||
@Schema(description = "表排序规则",example = "utf8mb4_general_ci")
|
||||
private String tableCollation;
|
||||
|
||||
@Schema(description = "存储引擎",example = "InnoDB")
|
||||
private String engine;
|
||||
|
||||
@Schema(description = "字符集",example = "utf8mb4")
|
||||
private String charset;
|
||||
|
||||
@Schema(description = "创建时间",example = "2023-08-08 08:08:08")
|
||||
private String createTime;
|
||||
|
||||
@Schema(description="是否已配置")
|
||||
private Integer isConfigured;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 用户登录视图对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/1/14
|
||||
*/
|
||||
@Schema(description ="当前登录用户视图对象")
|
||||
@Data
|
||||
public class UserInfoVO {
|
||||
|
||||
@Schema(description="用户ID")
|
||||
private Long userId;
|
||||
|
||||
@Schema(description="用户名")
|
||||
private String username;
|
||||
|
||||
@Schema(description="用户昵称")
|
||||
private String nickname;
|
||||
|
||||
@Schema(description="头像地址")
|
||||
private String avatar;
|
||||
|
||||
@Schema(description="用户角色编码集合")
|
||||
private Set<String> roles;
|
||||
|
||||
@Schema(description="用户权限标识集合")
|
||||
private Set<String> perms;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 用户分页视图对象
|
||||
*
|
||||
* @author haoxr
|
||||
* @since 2022/1/15 9:41
|
||||
*/
|
||||
@Schema(description ="用户分页对象")
|
||||
@Data
|
||||
public class UserPageVO {
|
||||
|
||||
@Schema(description="用户ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description="用户名")
|
||||
private String username;
|
||||
|
||||
@Schema(description="用户昵称")
|
||||
private String nickname;
|
||||
|
||||
@Schema(description="手机号")
|
||||
private String mobile;
|
||||
|
||||
@Schema(description="性别")
|
||||
private String genderLabel;
|
||||
|
||||
@Schema(description="用户头像地址")
|
||||
private String avatar;
|
||||
|
||||
@Schema(description="用户邮箱")
|
||||
private String email;
|
||||
|
||||
@Schema(description="用户状态(1:启用;0:禁用)")
|
||||
private Integer status;
|
||||
|
||||
@Schema(description="部门名称")
|
||||
private String deptName;
|
||||
|
||||
@Schema(description="角色名称,多个使用英文逗号(,)分割")
|
||||
private String roleNames;
|
||||
|
||||
@Schema(description="创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date createTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 个人中心用户信息
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/8/13
|
||||
*/
|
||||
@Schema(description = "个人中心用户信息")
|
||||
@Data
|
||||
public class UserProfileVO {
|
||||
|
||||
@Schema(description = "用户ID")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "用户名")
|
||||
private String username;
|
||||
|
||||
@Schema(description = "用户昵称")
|
||||
private String nickname;
|
||||
|
||||
@Schema(description = "头像URL")
|
||||
private String avatar;
|
||||
|
||||
@Schema(description = "性别")
|
||||
private Integer gender;
|
||||
|
||||
@Schema(description = "手机号")
|
||||
private String mobile;
|
||||
|
||||
@Schema(description = "邮箱")
|
||||
private String email;
|
||||
|
||||
@Schema(description = "部门名称")
|
||||
private String deptName;
|
||||
|
||||
@Schema(description = "角色名称")
|
||||
private String roleNames;
|
||||
|
||||
@Schema(description = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date createTime;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 访问量统计VO
|
||||
*
|
||||
* @author Ray
|
||||
* @since 2024/7/2
|
||||
*/
|
||||
@Schema(description = "访问量统计VO")
|
||||
@Getter
|
||||
@Setter
|
||||
public class VisitStatsVO {
|
||||
|
||||
@Schema(description = "统计类型")
|
||||
private String type;
|
||||
|
||||
@Schema(description = "标题")
|
||||
private String title;
|
||||
|
||||
@Schema(description = "今日访问量")
|
||||
private Integer todayCount;
|
||||
|
||||
@Schema(description = "总访问量")
|
||||
private Integer totalCount;
|
||||
|
||||
@Schema(description = "增长率")
|
||||
private BigDecimal growthRate;
|
||||
|
||||
@Schema(description = "统计粒度标签")
|
||||
private String granularityLabel;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.youlai.boot.system.model.vo;
|
||||
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Schema(description = "访问趋势VO")
|
||||
@Getter
|
||||
@Setter
|
||||
public class VisitTrendVO {
|
||||
|
||||
@Schema(description = "日期列表")
|
||||
private List<String> dates;
|
||||
|
||||
@Schema(description = "浏览量(PV)")
|
||||
private List<Integer> pvList;
|
||||
|
||||
@Schema(description = "访客数(UV)")
|
||||
private List<Integer> uvList;
|
||||
|
||||
@Schema(description = "IP数")
|
||||
private List<Integer> ipList;
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user