| | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | import javax.validation.constraints.*; |
| | | |
| | | import lombok.Getter; |
| | | import org.apache.commons.lang3.builder.ToStringBuilder; |
| | | import org.apache.commons.lang3.builder.ToStringStyle; |
| | | import com.ruoyi.common.annotation.Excel; |
| | |
| | | private Date loginDate; |
| | | |
| | | /** 部门对象 */ |
| | | @Excels({ |
| | | @Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT), |
| | | @Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT) |
| | | }) |
| | | // @Excels({ |
| | | // @Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT), |
| | | // @Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT) |
| | | // }) |
| | | private SysDept dept; |
| | | |
| | | /** 角色对象 */ |
| | |
| | | |
| | | /** 角色ID */ |
| | | private Long roleId; |
| | | |
| | | |
| | | public Integer getClanId() { |
| | | return clanId; |
| | | } |
| | | |
| | | private Integer clanId; |
| | | |
| | | public void setClanId(Integer clanId) { |
| | | this.clanId = clanId; |
| | | } |
| | | |
| | | public SysUser() |
| | | { |
| | |
| | | public static boolean isAdmin(Long userId) |
| | | { |
| | | //1号用户就是管理员 |
| | | //这里需要修改成管理员,查询数据库 |
| | | return userId != null && 1L == userId; |
| | | } |
| | | |
| | |
| | | public String toString() { |
| | | return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) |
| | | .append("userId", getUserId()) |
| | | .append("deptId", getDeptId()) |
| | | .append("clanId", getClanId()) |
| | | |
| | | .append("deptId", getDeptId()) |
| | | .append("userName", getUserName()) |
| | | .append("nickName", getNickName()) |
| | | .append("email", getEmail()) |