mirror of
				https://github.com/dromara/RuoYi-Vue-Plus.git
				synced 2025-10-31 22:33:48 +08:00 
			
		
		
		
	update 重写系统部分业务导出
This commit is contained in:
		| @@ -1,7 +1,6 @@ | ||||
| package com.ruoyi.common.core.domain.entity; | ||||
|  | ||||
| import com.baomidou.mybatisplus.annotation.*; | ||||
| import com.fasterxml.jackson.annotation.JsonFormat; | ||||
| import lombok.Data; | ||||
| import lombok.NoArgsConstructor; | ||||
| import lombok.experimental.Accessors; | ||||
| @@ -14,7 +13,7 @@ import java.util.*; | ||||
|  | ||||
| /** | ||||
|  * 部门表 sys_dept | ||||
|  *  | ||||
|  * | ||||
|  * @author ruoyi | ||||
|  */ | ||||
|  | ||||
| @@ -22,78 +21,107 @@ import java.util.*; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_dept") | ||||
| public class SysDept implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| public class SysDept implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 部门ID */ | ||||
|     @TableId(value = "dept_id",type = IdType.AUTO) | ||||
|     private Long deptId; | ||||
| 	/** | ||||
| 	 * 部门ID | ||||
| 	 */ | ||||
| 	@TableId(value = "dept_id", type = IdType.AUTO) | ||||
| 	private Long deptId; | ||||
|  | ||||
|     /** 父部门ID */ | ||||
|     private Long parentId; | ||||
| 	/** | ||||
| 	 * 父部门ID | ||||
| 	 */ | ||||
| 	private Long parentId; | ||||
|  | ||||
|     /** 祖级列表 */ | ||||
|     private String ancestors; | ||||
| 	/** | ||||
| 	 * 祖级列表 | ||||
| 	 */ | ||||
| 	private String ancestors; | ||||
|  | ||||
|     /** 部门名称 */ | ||||
|     @NotBlank(message = "部门名称不能为空") | ||||
|     @Size(min = 0, max = 30, message = "部门名称长度不能超过30个字符") | ||||
|     private String deptName; | ||||
| 	/** | ||||
| 	 * 部门名称 | ||||
| 	 */ | ||||
| 	@NotBlank(message = "部门名称不能为空") | ||||
| 	@Size(min = 0, max = 30, message = "部门名称长度不能超过30个字符") | ||||
| 	private String deptName; | ||||
|  | ||||
|     /** 显示顺序 */ | ||||
|     @NotBlank(message = "显示顺序不能为空") | ||||
|     private String orderNum; | ||||
| 	/** | ||||
| 	 * 显示顺序 | ||||
| 	 */ | ||||
| 	@NotBlank(message = "显示顺序不能为空") | ||||
| 	private String orderNum; | ||||
|  | ||||
|     /** 负责人 */ | ||||
|     private String leader; | ||||
| 	/** | ||||
| 	 * 负责人 | ||||
| 	 */ | ||||
| 	private String leader; | ||||
|  | ||||
|     /** 联系电话 */ | ||||
|     @Size(min = 0, max = 11, message = "联系电话长度不能超过11个字符") | ||||
|     private String phone; | ||||
| 	/** | ||||
| 	 * 联系电话 | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 11, message = "联系电话长度不能超过11个字符") | ||||
| 	private String phone; | ||||
|  | ||||
|     /** 邮箱 */ | ||||
|     @Email(message = "邮箱格式不正确") | ||||
|     @Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") | ||||
|     private String email; | ||||
| 	/** | ||||
| 	 * 邮箱 | ||||
| 	 */ | ||||
| 	@Email(message = "邮箱格式不正确") | ||||
| 	@Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") | ||||
| 	private String email; | ||||
|  | ||||
|     /** 部门状态:0正常,1停用 */ | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 部门状态:0正常,1停用 | ||||
| 	 */ | ||||
| 	private String status; | ||||
|  | ||||
|     /** 删除标志(0代表存在 2代表删除) */ | ||||
|     @TableLogic | ||||
|     private String delFlag; | ||||
| 	/** | ||||
| 	 * 删除标志(0代表存在 2代表删除) | ||||
| 	 */ | ||||
| 	@TableLogic | ||||
| 	private String delFlag; | ||||
|  | ||||
|     /** 父部门名称 */ | ||||
|     @TableField(exist = false) | ||||
|     private String parentName; | ||||
| 	/** | ||||
| 	 * 父部门名称 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private String parentName; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
|      | ||||
|     /** 子部门 */ | ||||
|     @TableField(exist = false) | ||||
|     private List<SysDept> children = new ArrayList<SysDept>(); | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** | ||||
|      * 请求参数 | ||||
|      */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 子部门 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private List<SysDept> children = new ArrayList<SysDept>(); | ||||
|  | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -1,10 +1,11 @@ | ||||
| package com.ruoyi.common.core.domain.entity; | ||||
|  | ||||
| import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; | ||||
| import com.alibaba.excel.annotation.ExcelProperty; | ||||
| import com.baomidou.mybatisplus.annotation.*; | ||||
| import com.fasterxml.jackson.annotation.JsonFormat; | ||||
| import com.ruoyi.common.annotation.Excel; | ||||
| import com.ruoyi.common.annotation.Excel.ColumnType; | ||||
| import com.ruoyi.common.annotation.ExcelDictFormat; | ||||
| import com.ruoyi.common.constant.UserConstants; | ||||
| import com.ruoyi.common.convert.ExcelDictConvert; | ||||
| import lombok.Data; | ||||
| import lombok.NoArgsConstructor; | ||||
| import lombok.experimental.Accessors; | ||||
| @@ -18,7 +19,7 @@ import java.util.Map; | ||||
|  | ||||
| /** | ||||
|  * 字典数据表 sys_dict_data | ||||
|  *  | ||||
|  * | ||||
|  * @author ruoyi | ||||
|  */ | ||||
|  | ||||
| @@ -26,82 +27,109 @@ import java.util.Map; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_dict_data") | ||||
| public class SysDictData implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| @ExcelIgnoreUnannotated | ||||
| public class SysDictData implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 字典编码 */ | ||||
|     @Excel(name = "字典编码", cellType = ColumnType.NUMERIC) | ||||
|     @TableId(value = "dict_code",type = IdType.AUTO) | ||||
|     private Long dictCode; | ||||
| 	/** | ||||
| 	 * 字典编码 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典编码") | ||||
| 	@TableId(value = "dict_code", type = IdType.AUTO) | ||||
| 	private Long dictCode; | ||||
|  | ||||
|     /** 字典排序 */ | ||||
|     @Excel(name = "字典排序", cellType = ColumnType.NUMERIC) | ||||
|     private Long dictSort; | ||||
| 	/** | ||||
| 	 * 字典排序 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典排序") | ||||
| 	private Long dictSort; | ||||
|  | ||||
|     /** 字典标签 */ | ||||
|     @Excel(name = "字典标签") | ||||
|     @NotBlank(message = "字典标签不能为空") | ||||
|     @Size(min = 0, max = 100, message = "字典标签长度不能超过100个字符") | ||||
|     private String dictLabel; | ||||
| 	/** | ||||
| 	 * 字典标签 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典标签") | ||||
| 	@NotBlank(message = "字典标签不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "字典标签长度不能超过100个字符") | ||||
| 	private String dictLabel; | ||||
|  | ||||
|     /** 字典键值 */ | ||||
|     @Excel(name = "字典键值") | ||||
|     @NotBlank(message = "字典键值不能为空") | ||||
|     @Size(min = 0, max = 100, message = "字典键值长度不能超过100个字符") | ||||
|     private String dictValue; | ||||
| 	/** | ||||
| 	 * 字典键值 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典键值") | ||||
| 	@NotBlank(message = "字典键值不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "字典键值长度不能超过100个字符") | ||||
| 	private String dictValue; | ||||
|  | ||||
|     /** 字典类型 */ | ||||
|     @Excel(name = "字典类型") | ||||
|     @NotBlank(message = "字典类型不能为空") | ||||
|     @Size(min = 0, max = 100, message = "字典类型长度不能超过100个字符") | ||||
|     private String dictType; | ||||
| 	/** | ||||
| 	 * 字典类型 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典类型") | ||||
| 	@NotBlank(message = "字典类型不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "字典类型长度不能超过100个字符") | ||||
| 	private String dictType; | ||||
|  | ||||
|     /** 样式属性(其他样式扩展) */ | ||||
|     @Size(min = 0, max = 100, message = "样式属性长度不能超过100个字符") | ||||
|     private String cssClass; | ||||
| 	/** | ||||
| 	 * 样式属性(其他样式扩展) | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 100, message = "样式属性长度不能超过100个字符") | ||||
| 	private String cssClass; | ||||
|  | ||||
|     /** 表格字典样式 */ | ||||
|     private String listClass; | ||||
| 	/** | ||||
| 	 * 表格字典样式 | ||||
| 	 */ | ||||
| 	private String listClass; | ||||
|  | ||||
|     /** 是否默认(Y是 N否) */ | ||||
|     @Excel(name = "是否默认", readConverterExp = "Y=是,N=否") | ||||
|     private String isDefault; | ||||
| 	/** | ||||
| 	 * 是否默认(Y是 N否) | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "是否默认", converter = ExcelDictConvert.class) | ||||
| 	@ExcelDictFormat(dictType = "sys_yes_no") | ||||
| 	private String isDefault; | ||||
|  | ||||
|     /** 状态(0正常 1停用) */ | ||||
|     @Excel(name = "状态", readConverterExp = "0=正常,1=停用") | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 状态(0正常 1停用) | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "状态", converter = ExcelDictConvert.class) | ||||
| 	@ExcelDictFormat(dictType = "sys_common_status") | ||||
| 	private String status; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** 备注 */ | ||||
|     private String remark; | ||||
| 	/** | ||||
| 	 * 备注 | ||||
| 	 */ | ||||
| 	private String remark; | ||||
|  | ||||
|     /** | ||||
|      * 请求参数 | ||||
|      */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
|     public boolean getDefault() | ||||
|     { | ||||
|         return UserConstants.YES.equals(this.isDefault) ? true : false; | ||||
|     } | ||||
| 	public boolean getDefault() { | ||||
| 		return UserConstants.YES.equals(this.isDefault) ? true : false; | ||||
| 	} | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -1,9 +1,10 @@ | ||||
| package com.ruoyi.common.core.domain.entity; | ||||
|  | ||||
| import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; | ||||
| import com.alibaba.excel.annotation.ExcelProperty; | ||||
| import com.baomidou.mybatisplus.annotation.*; | ||||
| import com.fasterxml.jackson.annotation.JsonFormat; | ||||
| import com.ruoyi.common.annotation.Excel; | ||||
| import com.ruoyi.common.annotation.Excel.ColumnType; | ||||
| import com.ruoyi.common.annotation.ExcelDictFormat; | ||||
| import com.ruoyi.common.convert.ExcelDictConvert; | ||||
| import lombok.Data; | ||||
| import lombok.NoArgsConstructor; | ||||
| import lombok.experimental.Accessors; | ||||
| @@ -17,7 +18,7 @@ import java.util.Map; | ||||
|  | ||||
| /** | ||||
|  * 字典类型表 sys_dict_type | ||||
|  *  | ||||
|  * | ||||
|  * @author ruoyi | ||||
|  */ | ||||
|  | ||||
| @@ -25,56 +26,73 @@ import java.util.Map; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_dict_type") | ||||
| public class SysDictType implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| @ExcelIgnoreUnannotated | ||||
| public class SysDictType implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 字典主键 */ | ||||
|     @Excel(name = "字典主键", cellType = ColumnType.NUMERIC) | ||||
|     @TableId(value = "dict_id",type = IdType.AUTO) | ||||
|     private Long dictId; | ||||
| 	/** | ||||
| 	 * 字典主键 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典主键") | ||||
| 	@TableId(value = "dict_id", type = IdType.AUTO) | ||||
| 	private Long dictId; | ||||
|  | ||||
|     /** 字典名称 */ | ||||
|     @Excel(name = "字典名称") | ||||
|     @NotBlank(message = "字典名称不能为空") | ||||
|     @Size(min = 0, max = 100, message = "字典类型名称长度不能超过100个字符") | ||||
|     private String dictName; | ||||
| 	/** | ||||
| 	 * 字典名称 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典名称") | ||||
| 	@NotBlank(message = "字典名称不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "字典类型名称长度不能超过100个字符") | ||||
| 	private String dictName; | ||||
|  | ||||
|     /** 字典类型 */ | ||||
|     @Excel(name = "字典类型") | ||||
|     @NotBlank(message = "字典类型不能为空") | ||||
|     @Size(min = 0, max = 100, message = "字典类型类型长度不能超过100个字符") | ||||
|     private String dictType; | ||||
| 	/** | ||||
| 	 * 字典类型 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "字典类型") | ||||
| 	@NotBlank(message = "字典类型不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "字典类型类型长度不能超过100个字符") | ||||
| 	private String dictType; | ||||
|  | ||||
|     /** 状态(0正常 1停用) */ | ||||
|     @Excel(name = "状态", readConverterExp = "0=正常,1=停用") | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 状态(0正常 1停用) | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "状态", converter = ExcelDictConvert.class) | ||||
| 	@ExcelDictFormat(dictType = "sys_common_status") | ||||
| 	private String status; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** 备注 */ | ||||
|     private String remark; | ||||
| 	/** | ||||
| 	 * 备注 | ||||
| 	 */ | ||||
| 	private String remark; | ||||
|  | ||||
|     /** | ||||
|      * 请求参数 | ||||
|      */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -13,7 +13,7 @@ import java.util.*; | ||||
|  | ||||
| /** | ||||
|  * 菜单权限表 sys_menu | ||||
|  *  | ||||
|  * | ||||
|  * @author ruoyi | ||||
|  */ | ||||
|  | ||||
| @@ -21,88 +21,129 @@ import java.util.*; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_menu") | ||||
| public class SysMenu implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| public class SysMenu implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 菜单ID */ | ||||
|     @TableId(value = "menu_id",type = IdType.AUTO) | ||||
|     private Long menuId; | ||||
| 	/** | ||||
| 	 * 菜单ID | ||||
| 	 */ | ||||
| 	@TableId(value = "menu_id", type = IdType.AUTO) | ||||
| 	private Long menuId; | ||||
|  | ||||
|     /** 菜单名称 */ | ||||
|     @NotBlank(message = "菜单名称不能为空") | ||||
|     @Size(min = 0, max = 50, message = "菜单名称长度不能超过50个字符") | ||||
|     private String menuName; | ||||
| 	/** | ||||
| 	 * 菜单名称 | ||||
| 	 */ | ||||
| 	@NotBlank(message = "菜单名称不能为空") | ||||
| 	@Size(min = 0, max = 50, message = "菜单名称长度不能超过50个字符") | ||||
| 	private String menuName; | ||||
|  | ||||
|     /** 父菜单名称 */ | ||||
|     @TableField(exist = false) | ||||
|     private String parentName; | ||||
| 	/** | ||||
| 	 * 父菜单名称 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private String parentName; | ||||
|  | ||||
|     /** 父菜单ID */ | ||||
|     private Long parentId; | ||||
| 	/** | ||||
| 	 * 父菜单ID | ||||
| 	 */ | ||||
| 	private Long parentId; | ||||
|  | ||||
|     /** 显示顺序 */ | ||||
|     @NotBlank(message = "显示顺序不能为空") | ||||
|     private String orderNum; | ||||
| 	/** | ||||
| 	 * 显示顺序 | ||||
| 	 */ | ||||
| 	@NotBlank(message = "显示顺序不能为空") | ||||
| 	private String orderNum; | ||||
|  | ||||
|     /** 路由地址 */ | ||||
|     @Size(min = 0, max = 200, message = "路由地址不能超过200个字符") | ||||
|     private String path; | ||||
| 	/** | ||||
| 	 * 路由地址 | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 200, message = "路由地址不能超过200个字符") | ||||
| 	private String path; | ||||
|  | ||||
|     /** 组件路径 */ | ||||
|     @Size(min = 0, max = 200, message = "组件路径不能超过255个字符") | ||||
|     private String component; | ||||
| 	/** | ||||
| 	 * 组件路径 | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 200, message = "组件路径不能超过255个字符") | ||||
| 	private String component; | ||||
|  | ||||
|     /** 是否为外链(0是 1否) */ | ||||
|     private String isFrame; | ||||
| 	/** | ||||
| 	 * 是否为外链(0是 1否) | ||||
| 	 */ | ||||
| 	private String isFrame; | ||||
|  | ||||
|     /** 是否缓存(0缓存 1不缓存) */ | ||||
|     private String isCache; | ||||
| 	/** | ||||
| 	 * 是否缓存(0缓存 1不缓存) | ||||
| 	 */ | ||||
| 	private String isCache; | ||||
|  | ||||
|     /** 类型(M目录 C菜单 F按钮) */ | ||||
|     @NotBlank(message = "菜单类型不能为空") | ||||
|     private String menuType; | ||||
| 	/** | ||||
| 	 * 类型(M目录 C菜单 F按钮) | ||||
| 	 */ | ||||
| 	@NotBlank(message = "菜单类型不能为空") | ||||
| 	private String menuType; | ||||
|  | ||||
|     /** 显示状态(0显示 1隐藏) */ | ||||
|     private String visible; | ||||
|      | ||||
|     /** 菜单状态(0显示 1隐藏) */ | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 显示状态(0显示 1隐藏) | ||||
| 	 */ | ||||
| 	private String visible; | ||||
|  | ||||
|     /** 权限字符串 */ | ||||
|     @Size(min = 0, max = 100, message = "权限标识长度不能超过100个字符") | ||||
|     private String perms; | ||||
| 	/** | ||||
| 	 * 菜单状态(0显示 1隐藏) | ||||
| 	 */ | ||||
| 	private String status; | ||||
|  | ||||
|     /** 菜单图标 */ | ||||
|     private String icon; | ||||
| 	/** | ||||
| 	 * 权限字符串 | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 100, message = "权限标识长度不能超过100个字符") | ||||
| 	private String perms; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 菜单图标 | ||||
| 	 */ | ||||
| 	private String icon; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 备注 */ | ||||
|     private String remark; | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** 请求参数 */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 备注 | ||||
| 	 */ | ||||
| 	private String remark; | ||||
|  | ||||
|     /** 子菜单 */ | ||||
|     @TableField(exist = false) | ||||
|     private List<SysMenu> children = new ArrayList<SysMenu>(); | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
| 	/** | ||||
| 	 * 子菜单 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private List<SysMenu> children = new ArrayList<SysMenu>(); | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -1,9 +1,10 @@ | ||||
| package com.ruoyi.common.core.domain.entity; | ||||
|  | ||||
| import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; | ||||
| import com.alibaba.excel.annotation.ExcelProperty; | ||||
| import com.baomidou.mybatisplus.annotation.*; | ||||
| import com.fasterxml.jackson.annotation.JsonFormat; | ||||
| import com.ruoyi.common.annotation.Excel; | ||||
| import com.ruoyi.common.annotation.Excel.ColumnType; | ||||
| import com.ruoyi.common.annotation.ExcelDictFormat; | ||||
| import com.ruoyi.common.convert.ExcelDictConvert; | ||||
| import lombok.Data; | ||||
| import lombok.NoArgsConstructor; | ||||
| import lombok.experimental.Accessors; | ||||
| @@ -25,102 +26,133 @@ import java.util.Map; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_role") | ||||
| public class SysRole implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| @ExcelIgnoreUnannotated | ||||
| public class SysRole implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 角色ID */ | ||||
|     @Excel(name = "角色序号", cellType = ColumnType.NUMERIC) | ||||
|     @TableId(value = "role_id",type = IdType.AUTO) | ||||
|     private Long roleId; | ||||
| 	/** | ||||
| 	 * 角色ID | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "角色序号") | ||||
| 	@TableId(value = "role_id", type = IdType.AUTO) | ||||
| 	private Long roleId; | ||||
|  | ||||
|     /** 角色名称 */ | ||||
|     @Excel(name = "角色名称") | ||||
|     @NotBlank(message = "角色名称不能为空") | ||||
|     @Size(min = 0, max = 30, message = "角色名称长度不能超过30个字符") | ||||
|     private String roleName; | ||||
| 	/** | ||||
| 	 * 角色名称 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "角色名称") | ||||
| 	@NotBlank(message = "角色名称不能为空") | ||||
| 	@Size(min = 0, max = 30, message = "角色名称长度不能超过30个字符") | ||||
| 	private String roleName; | ||||
|  | ||||
|     /** 角色权限 */ | ||||
|     @Excel(name = "角色权限") | ||||
|     @NotBlank(message = "权限字符不能为空") | ||||
|     @Size(min = 0, max = 100, message = "权限字符长度不能超过100个字符") | ||||
|     private String roleKey; | ||||
| 	/** | ||||
| 	 * 角色权限 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "角色权限") | ||||
| 	@NotBlank(message = "权限字符不能为空") | ||||
| 	@Size(min = 0, max = 100, message = "权限字符长度不能超过100个字符") | ||||
| 	private String roleKey; | ||||
|  | ||||
|     /** 角色排序 */ | ||||
|     @Excel(name = "角色排序") | ||||
|     @NotBlank(message = "显示顺序不能为空") | ||||
|     private String roleSort; | ||||
| 	/** | ||||
| 	 * 角色排序 | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "角色排序") | ||||
| 	@NotBlank(message = "显示顺序不能为空") | ||||
| 	private String roleSort; | ||||
|  | ||||
|     /** 数据范围(1:所有数据权限;2:自定义数据权限;3:本部门数据权限;4:本部门及以下数据权限;5:仅本人数据权限) */ | ||||
|     @Excel(name = "数据范围", readConverterExp = "1=所有数据权限,2=自定义数据权限,3=本部门数据权限,4=本部门及以下数据权限,5=仅本人数据权限") | ||||
|     private String dataScope; | ||||
| 	/** | ||||
| 	 * 数据范围(1:所有数据权限;2:自定义数据权限;3:本部门数据权限;4:本部门及以下数据权限;5:仅本人数据权限) | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "数据范围", converter = ExcelDictConvert.class) | ||||
| 	@ExcelDictFormat(readConverterExp = "1=所有数据权限,2=自定义数据权限,3=本部门数据权限,4=本部门及以下数据权限,5=仅本人数据权限") | ||||
| 	private String dataScope; | ||||
|  | ||||
|     /** 菜单树选择项是否关联显示( 0:父子不互相关联显示 1:父子互相关联显示) */ | ||||
|     private boolean menuCheckStrictly; | ||||
| 	/** | ||||
| 	 * 菜单树选择项是否关联显示( 0:父子不互相关联显示 1:父子互相关联显示) | ||||
| 	 */ | ||||
| 	private boolean menuCheckStrictly; | ||||
|  | ||||
|     /** 部门树选择项是否关联显示(0:父子不互相关联显示 1:父子互相关联显示 ) */ | ||||
|     private boolean deptCheckStrictly; | ||||
| 	/** | ||||
| 	 * 部门树选择项是否关联显示(0:父子不互相关联显示 1:父子互相关联显示 ) | ||||
| 	 */ | ||||
| 	private boolean deptCheckStrictly; | ||||
|  | ||||
|     /** 角色状态(0正常 1停用) */ | ||||
|     @Excel(name = "角色状态", readConverterExp = "0=正常,1=停用") | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 角色状态(0正常 1停用) | ||||
| 	 */ | ||||
| 	@ExcelProperty(value = "角色状态", converter = ExcelDictConvert.class) | ||||
| 	@ExcelDictFormat(dictType = "sys_common_status") | ||||
| 	private String status; | ||||
|  | ||||
|     /** 删除标志(0代表存在 2代表删除) */ | ||||
|     @TableLogic | ||||
|     private String delFlag; | ||||
| 	/** | ||||
| 	 * 删除标志(0代表存在 2代表删除) | ||||
| 	 */ | ||||
| 	@TableLogic | ||||
| 	private String delFlag; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** 备注 */ | ||||
|     private String remark; | ||||
| 	/** | ||||
| 	 * 备注 | ||||
| 	 */ | ||||
| 	private String remark; | ||||
|  | ||||
|     /** | ||||
|      * 请求参数 | ||||
|      */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
|     /** 用户是否存在此角色标识 默认不存在 */ | ||||
|     @TableField(exist = false) | ||||
|     private boolean flag = false; | ||||
| 	/** | ||||
| 	 * 用户是否存在此角色标识 默认不存在 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private boolean flag = false; | ||||
|  | ||||
|     /** 菜单组 */ | ||||
|     @TableField(exist = false) | ||||
|     private Long[] menuIds; | ||||
| 	/** | ||||
| 	 * 菜单组 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Long[] menuIds; | ||||
|  | ||||
|     /** 部门组(数据权限) */ | ||||
|     @TableField(exist = false) | ||||
|     private Long[] deptIds; | ||||
| 	/** | ||||
| 	 * 部门组(数据权限) | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Long[] deptIds; | ||||
|  | ||||
|     public SysRole(Long roleId) | ||||
|     { | ||||
|         this.roleId = roleId; | ||||
|     } | ||||
| 	public SysRole(Long roleId) { | ||||
| 		this.roleId = roleId; | ||||
| 	} | ||||
|  | ||||
|     public boolean isAdmin() | ||||
|     { | ||||
|         return isAdmin(this.roleId); | ||||
|     } | ||||
| 	public boolean isAdmin() { | ||||
| 		return isAdmin(this.roleId); | ||||
| 	} | ||||
|  | ||||
|     public static boolean isAdmin(Long roleId) | ||||
|     { | ||||
|         return roleId != null && 1L == roleId; | ||||
|     } | ||||
| 	public static boolean isAdmin(Long roleId) { | ||||
| 		return roleId != null && 1L == roleId; | ||||
| 	} | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -31,139 +31,183 @@ import java.util.Map; | ||||
| @NoArgsConstructor | ||||
| @Accessors(chain = true) | ||||
| @TableName("sys_user") | ||||
| public class SysUser implements Serializable | ||||
| { | ||||
|     private static final long serialVersionUID = 1L; | ||||
| public class SysUser implements Serializable { | ||||
| 	private static final long serialVersionUID = 1L; | ||||
|  | ||||
|     /** 用户ID */ | ||||
|     @Excel(name = "用户序号", cellType = ColumnType.NUMERIC, prompt = "用户编号") | ||||
|     @TableId(value = "user_id",type = IdType.AUTO) | ||||
|     private Long userId; | ||||
| 	/** | ||||
| 	 * 用户ID | ||||
| 	 */ | ||||
| 	@Excel(name = "用户序号", cellType = ColumnType.NUMERIC, prompt = "用户编号") | ||||
| 	@TableId(value = "user_id", type = IdType.AUTO) | ||||
| 	private Long userId; | ||||
|  | ||||
|     /** 部门ID */ | ||||
|     @Excel(name = "部门编号", type = Type.IMPORT) | ||||
|     private Long deptId; | ||||
| 	/** | ||||
| 	 * 部门ID | ||||
| 	 */ | ||||
| 	@Excel(name = "部门编号", type = Type.IMPORT) | ||||
| 	private Long deptId; | ||||
|  | ||||
|     /** 用户账号 */ | ||||
|     @NotBlank(message = "用户账号不能为空") | ||||
|     @Size(min = 0, max = 30, message = "用户账号长度不能超过30个字符") | ||||
|     @Excel(name = "登录名称") | ||||
|     private String userName; | ||||
| 	/** | ||||
| 	 * 用户账号 | ||||
| 	 */ | ||||
| 	@NotBlank(message = "用户账号不能为空") | ||||
| 	@Size(min = 0, max = 30, message = "用户账号长度不能超过30个字符") | ||||
| 	@Excel(name = "登录名称") | ||||
| 	private String userName; | ||||
|  | ||||
|     /** 用户昵称 */ | ||||
|     @Size(min = 0, max = 30, message = "用户昵称长度不能超过30个字符") | ||||
|     @Excel(name = "用户名称") | ||||
|     private String nickName; | ||||
| 	/** | ||||
| 	 * 用户昵称 | ||||
| 	 */ | ||||
| 	@Size(min = 0, max = 30, message = "用户昵称长度不能超过30个字符") | ||||
| 	@Excel(name = "用户名称") | ||||
| 	private String nickName; | ||||
|  | ||||
|     /** 用户邮箱 */ | ||||
|     @Email(message = "邮箱格式不正确") | ||||
|     @Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") | ||||
|     @Excel(name = "用户邮箱") | ||||
|     private String email; | ||||
| 	/** | ||||
| 	 * 用户邮箱 | ||||
| 	 */ | ||||
| 	@Email(message = "邮箱格式不正确") | ||||
| 	@Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") | ||||
| 	@Excel(name = "用户邮箱") | ||||
| 	private String email; | ||||
|  | ||||
|     /** 手机号码 */ | ||||
|     @Excel(name = "手机号码") | ||||
|     private String phonenumber; | ||||
| 	/** | ||||
| 	 * 手机号码 | ||||
| 	 */ | ||||
| 	@Excel(name = "手机号码") | ||||
| 	private String phonenumber; | ||||
|  | ||||
|     /** 用户性别 */ | ||||
|     @Excel(name = "用户性别", readConverterExp = "0=男,1=女,2=未知") | ||||
|     private String sex; | ||||
| 	/** | ||||
| 	 * 用户性别 | ||||
| 	 */ | ||||
| 	@Excel(name = "用户性别", readConverterExp = "0=男,1=女,2=未知") | ||||
| 	private String sex; | ||||
|  | ||||
|     /** 用户头像 */ | ||||
|     private String avatar; | ||||
| 	/** | ||||
| 	 * 用户头像 | ||||
| 	 */ | ||||
| 	private String avatar; | ||||
|  | ||||
|     /** 密码 */ | ||||
|     private String password; | ||||
| 	/** | ||||
| 	 * 密码 | ||||
| 	 */ | ||||
| 	private String password; | ||||
|  | ||||
|     @JsonIgnore | ||||
|     @JsonProperty | ||||
|     public String getPassword() { | ||||
|         return password; | ||||
|     } | ||||
| 	@JsonIgnore | ||||
| 	@JsonProperty | ||||
| 	public String getPassword() { | ||||
| 		return password; | ||||
| 	} | ||||
|  | ||||
|     /** 盐加密 */ | ||||
|     private String salt; | ||||
| 	/** | ||||
| 	 * 盐加密 | ||||
| 	 */ | ||||
| 	private String salt; | ||||
|  | ||||
|     /** 帐号状态(0正常 1停用) */ | ||||
|     @Excel(name = "帐号状态", readConverterExp = "0=正常,1=停用") | ||||
|     private String status; | ||||
| 	/** | ||||
| 	 * 帐号状态(0正常 1停用) | ||||
| 	 */ | ||||
| 	@Excel(name = "帐号状态", readConverterExp = "0=正常,1=停用") | ||||
| 	private String status; | ||||
|  | ||||
|     /** 删除标志(0代表存在 2代表删除) */ | ||||
|     @TableLogic | ||||
|     private String delFlag; | ||||
| 	/** | ||||
| 	 * 删除标志(0代表存在 2代表删除) | ||||
| 	 */ | ||||
| 	@TableLogic | ||||
| 	private String delFlag; | ||||
|  | ||||
|     /** 最后登录IP */ | ||||
|     @Excel(name = "最后登录IP", type = Type.EXPORT) | ||||
|     private String loginIp; | ||||
| 	/** | ||||
| 	 * 最后登录IP | ||||
| 	 */ | ||||
| 	@Excel(name = "最后登录IP", type = Type.EXPORT) | ||||
| 	private String loginIp; | ||||
|  | ||||
|     /** 最后登录时间 */ | ||||
|     @Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", type = Type.EXPORT) | ||||
|     private Date loginDate; | ||||
| 	/** | ||||
| 	 * 最后登录时间 | ||||
| 	 */ | ||||
| 	@Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", type = Type.EXPORT) | ||||
| 	private Date loginDate; | ||||
|  | ||||
|     /** 创建者 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     private String createBy; | ||||
| 	/** | ||||
| 	 * 创建者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	private String createBy; | ||||
|  | ||||
|     /** 创建时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date createTime; | ||||
| 	/** | ||||
| 	 * 创建时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT) | ||||
| 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
| 	private Date createTime; | ||||
|  | ||||
|     /** 更新者 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     private String updateBy; | ||||
| 	/** | ||||
| 	 * 更新者 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	private String updateBy; | ||||
|  | ||||
|     /** 更新时间 */ | ||||
|     @TableField(fill = FieldFill.INSERT_UPDATE) | ||||
|     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
|     private Date updateTime; | ||||
| 	/** | ||||
| 	 * 更新时间 | ||||
| 	 */ | ||||
| 	@TableField(fill = FieldFill.INSERT_UPDATE) | ||||
| 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") | ||||
| 	private Date updateTime; | ||||
|  | ||||
|     /** 备注 */ | ||||
|     private String remark; | ||||
| 	/** | ||||
| 	 * 备注 | ||||
| 	 */ | ||||
| 	private String remark; | ||||
|  | ||||
|     /** | ||||
|      * 请求参数 | ||||
|      */ | ||||
|     @TableField(exist = false) | ||||
|     private Map<String, Object> params = new HashMap<>(); | ||||
| 	/** | ||||
| 	 * 请求参数 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Map<String, Object> params = new HashMap<>(); | ||||
|  | ||||
|     /** 部门对象 */ | ||||
|     @Excels({ | ||||
|         @Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT), | ||||
|         @Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT) | ||||
|     }) | ||||
|     @TableField(exist = false) | ||||
|     private SysDept dept; | ||||
| 	/** | ||||
| 	 * 部门对象 | ||||
| 	 */ | ||||
| 	@Excels({ | ||||
| 		@Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT), | ||||
| 		@Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT) | ||||
| 	}) | ||||
| 	@TableField(exist = false) | ||||
| 	private SysDept dept; | ||||
|  | ||||
|     /** 角色对象 */ | ||||
|     @TableField(exist = false) | ||||
|     private List<SysRole> roles; | ||||
| 	/** | ||||
| 	 * 角色对象 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private List<SysRole> roles; | ||||
|  | ||||
|     /** 角色组 */ | ||||
|     @TableField(exist = false) | ||||
|     private Long[] roleIds; | ||||
| 	/** | ||||
| 	 * 角色组 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Long[] roleIds; | ||||
|  | ||||
|     /** 岗位组 */ | ||||
|     @TableField(exist = false) | ||||
|     private Long[] postIds; | ||||
| 	/** | ||||
| 	 * 岗位组 | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Long[] postIds; | ||||
|  | ||||
| 	/** 角色ID */ | ||||
| 	/** | ||||
| 	 * 角色ID | ||||
| 	 */ | ||||
| 	@TableField(exist = false) | ||||
| 	private Long roleId; | ||||
|  | ||||
|     public SysUser(Long userId) | ||||
|     { | ||||
|         this.userId = userId; | ||||
|     } | ||||
| 	public SysUser(Long userId) { | ||||
| 		this.userId = userId; | ||||
| 	} | ||||
|  | ||||
|     public boolean isAdmin() | ||||
|     { | ||||
|         return isAdmin(this.userId); | ||||
|     } | ||||
| 	public boolean isAdmin() { | ||||
| 		return isAdmin(this.userId); | ||||
| 	} | ||||
|  | ||||
|     public static boolean isAdmin(Long userId) | ||||
|     { | ||||
|         return userId != null && 1L == userId; | ||||
|     } | ||||
| 	public static boolean isAdmin(Long userId) { | ||||
| 		return userId != null && 1L == userId; | ||||
| 	} | ||||
|  | ||||
| } | ||||
|   | ||||
| @@ -46,7 +46,7 @@ public class ExcelUtils { | ||||
| 			response.addHeader("Access-Control-Allow-Origin", "*"); | ||||
| 			response.addHeader("Access-Control-Expose-Headers", "Content-Disposition"); | ||||
| 			FileUtils.setAttachmentResponseHeader(response, URLEncoder.encode(filename, StandardCharsets.UTF_8.toString())); | ||||
| 			response.setContentType("application/vnd.ms-excel;charset=UTF-8"); | ||||
| 			response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8"); | ||||
| 			ServletOutputStream os = response.getOutputStream(); | ||||
| 			EasyExcel.write(os, clazz) | ||||
| 				.autoCloseStream(false) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user