add
This commit is contained in:
@ -34,6 +34,7 @@ public class SysDept extends BaseEntity {
|
||||
/**
|
||||
* 父部门ID
|
||||
*/
|
||||
@NotBlank(message = "parentId不能为空")
|
||||
private String parentId;
|
||||
|
||||
/**
|
||||
@ -44,7 +45,8 @@ public class SysDept extends BaseEntity {
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
@Size(min = 1, max = 20, message = "部门名称允许长度: {min}-{max}")
|
||||
@NotBlank(message = "部门名称不能为空")
|
||||
@Size(max = 20, message = "部门名称最大长度: {max}")
|
||||
private String deptName;
|
||||
|
||||
/**
|
||||
@ -57,16 +59,19 @@ public class SysDept extends BaseEntity {
|
||||
/**
|
||||
* 负责人
|
||||
*/
|
||||
@Size(max = 20, message = "负责人名称过长")
|
||||
private String leader;
|
||||
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
@Size(max = 20, message = "手机号过长")
|
||||
private String phone;
|
||||
|
||||
/**
|
||||
* 邮箱
|
||||
*/
|
||||
@Size(max = 30, message = "邮箱号过长")
|
||||
private String email;
|
||||
|
||||
/**
|
||||
|
@ -33,12 +33,14 @@ public class SysPost extends BaseEntity {
|
||||
|
||||
@Excel(name = "岗位名称", width = 20)
|
||||
@Schema(description = "岗位名称")
|
||||
@Size(min = 1, max = 20, message = "岗位名称允许长度: {min}-{max}")
|
||||
@NotBlank(message = "岗位名称不能为空")
|
||||
@Size(max = 20, message = "岗位名称最大长度: {max}")
|
||||
private String postName;
|
||||
|
||||
@Excel(name = "岗位编码", width = 20)
|
||||
@Schema(description = "岗位编码")
|
||||
@Size(min = 1, max = 20, message = "岗位编码允许长度: {min}-{max}")
|
||||
@NotBlank(message = "岗位编码不能为空")
|
||||
@Size(max = 20, message = "岗位编码最大长度: {max}")
|
||||
private String postCode;
|
||||
|
||||
@Excel(name = "岗位排序", width = 20)
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.qiaoba.api.system.entity;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.qiaoba.common.base.entity.BaseEntity;
|
||||
@ -20,35 +21,23 @@ public class SysRole extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
@TableId
|
||||
@Excel(name = "岗位序号", width = 20)
|
||||
private String roleId;
|
||||
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
@Excel(name = "岗位序号", width = 20)
|
||||
private String roleName;
|
||||
|
||||
/**
|
||||
* 角色权限
|
||||
*/
|
||||
@Excel(name = "岗位序号", width = 20)
|
||||
private String roleKey;
|
||||
|
||||
/**
|
||||
* 角色排序
|
||||
*/
|
||||
private String roleSort;
|
||||
@Excel(name = "岗位序号", width = 20)
|
||||
private Integer roleSort;
|
||||
|
||||
/**
|
||||
* 数据范围(1:所有数据权限;2:自定义数据权限;3:本部门数据权限;4:本部门及以下数据权限;5:仅本人数据权限)
|
||||
*/
|
||||
@Excel(name = "数据范围" , width = 20, replace = {"所有数据权限_1" , "自定义数据权限_2" , "本部门数据权限_3" , "本部门及以下数据权限_4" , "仅本人数据权限_5"})
|
||||
private String dataScope;
|
||||
|
||||
/**
|
||||
* 角色状态(1正常 0停用)
|
||||
*/
|
||||
@Excel(name = "状态", width = 20, replace = {"正常_1", "禁用_0"})
|
||||
private String status;
|
||||
|
||||
}
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.qiaoba.api.system.entity.dto;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
@ -19,49 +20,28 @@ public class SysRoleDto implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 角色ID
|
||||
*/
|
||||
@Schema(description = "角色ID")
|
||||
private String roleId;
|
||||
|
||||
/**
|
||||
* 租户ID
|
||||
*/
|
||||
private String tenantId;
|
||||
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
@Schema(description = "角色名称")
|
||||
private String roleName;
|
||||
|
||||
/**
|
||||
* 角色权限
|
||||
*/
|
||||
@Schema(description = "权限字符")
|
||||
private String roleKey;
|
||||
|
||||
/**
|
||||
* 角色排序
|
||||
*/
|
||||
private String roleSort;
|
||||
@Schema(description = "角色排序")
|
||||
private Integer roleSort;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@Schema(description = "备注")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 角色状态(1正常 0停用)
|
||||
*/
|
||||
@Schema(description = "状态(0->禁用,1->正常)")
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 部门组(数据权限)
|
||||
*/
|
||||
@Schema(description = "部门组(数据权限)")
|
||||
private Set<String> deptIds;
|
||||
|
||||
/**
|
||||
* 菜单组
|
||||
*/
|
||||
@Schema(description = "菜单组")
|
||||
private Set<String> menuIds;
|
||||
|
||||
}
|
||||
|
@ -19,13 +19,18 @@ public class SysRoleParam implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "角色名称")
|
||||
private String roleName;
|
||||
|
||||
@Schema(description = "权限字符")
|
||||
private String roleKey;
|
||||
|
||||
@Schema(description = "状态(0->禁用,1->正常)")
|
||||
private String status;
|
||||
|
||||
@Schema(description = "开始时间")
|
||||
private String beginTime;
|
||||
|
||||
@Schema(description = "结束时间")
|
||||
private String endTime;
|
||||
}
|
||||
|
@ -1,6 +1,5 @@
|
||||
package com.qiaoba.api.system.entity.vo;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
@ -20,30 +19,22 @@ public class SysUserVo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Excel(name = "用户ID", width = 25)
|
||||
private String userId;
|
||||
|
||||
@Excel(name = "登录账号", width = 20)
|
||||
private String username;
|
||||
|
||||
@Excel(name = "姓名", width = 20)
|
||||
private String nickname;
|
||||
|
||||
@Excel(name = "部门", width = 20)
|
||||
private String deptName;
|
||||
|
||||
@Excel(name = "性别", replace = {"男_0", "女_1", "未知_2"})
|
||||
private String gender;
|
||||
|
||||
@Excel(name = "手机", width = 20)
|
||||
private String phone;
|
||||
|
||||
@Excel(name = "邮箱", width = 20)
|
||||
private String email;
|
||||
|
||||
@Excel(name = "创建时间", width = 30, format = "yyyy-MM-dd HH:mm:ss")
|
||||
private String status;
|
||||
|
||||
private Date createTime;
|
||||
|
||||
@Excel(name = "状态", replace = {"正常_1", "停用_0"})
|
||||
private String status;
|
||||
}
|
||||
|
@ -55,13 +55,6 @@ public interface SysDeptApiService {
|
||||
*/
|
||||
int deleteById(String deptId);
|
||||
|
||||
/**
|
||||
* 构建前端部门树
|
||||
*
|
||||
* @return tree
|
||||
*/
|
||||
List<Tree<String>> selectDeptTree();
|
||||
|
||||
/**
|
||||
* 根据角色ID查询部门树信息
|
||||
*
|
||||
|
@ -54,7 +54,7 @@ public interface SysRoleApiService {
|
||||
* @param roleId 角色Id
|
||||
* @return > 0 = success
|
||||
*/
|
||||
int deleteById(Long roleId);
|
||||
int deleteById(String roleId);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
@ -72,4 +72,12 @@ public interface SysRoleApiService {
|
||||
*/
|
||||
int authDataScope(DataScopeDto dto);
|
||||
|
||||
/**
|
||||
* 更改状态
|
||||
*
|
||||
* @param roleId roleId
|
||||
* @param status status
|
||||
* @return 结果
|
||||
*/
|
||||
int changeStatus(String roleId, String status);
|
||||
}
|
||||
|
@ -79,12 +79,5 @@ public interface SysUserApiService {
|
||||
*/
|
||||
void handleUserRole(String userId, Set<String> roleIds, boolean isUpdate);
|
||||
|
||||
/**
|
||||
* 查询用户列表
|
||||
*
|
||||
* @param param 查询条件
|
||||
* @return list
|
||||
*/
|
||||
List<SysUserVo> selectVoList(SysUserParam param);
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user