SysRoleMenuKzt.java 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. package com.ydtech.modules.admin.model;
  2. import com.baomidou.mybatisplus.annotation.IdType;
  3. import com.baomidou.mybatisplus.annotation.TableField;
  4. import com.baomidou.mybatisplus.annotation.TableId;
  5. import com.baomidou.mybatisplus.annotation.TableName;
  6. import lombok.Data;
  7. import java.io.Serializable;
  8. import java.util.Date;
  9. /**
  10. * 控制台角色关联菜单
  11. * @TableName sys_role_menu_kzt
  12. */
  13. @TableName(value ="sys_role_menu_kzt")
  14. @Data
  15. public class SysRoleMenuKzt implements Serializable {
  16. /**
  17. * 编号
  18. */
  19. @TableId(type = IdType.AUTO)
  20. private Long id;
  21. /**
  22. * 角色ID
  23. */
  24. @TableField(value = "role_id")
  25. private Long roleId;
  26. /**
  27. * 菜单ID
  28. */
  29. @TableField(value = "menu_id")
  30. private Long menuId;
  31. /**
  32. * 系统类型
  33. */
  34. @TableField(value = "sys_type")
  35. private String sysType;
  36. /**
  37. * 创建人
  38. */
  39. @TableField(value = "create_by")
  40. private String createBy;
  41. /**
  42. * 创建时间
  43. */
  44. @TableField(value = "create_time")
  45. private Date createTime;
  46. /**
  47. * 更新人
  48. */
  49. @TableField(value = "last_update_by")
  50. private String lastUpdateBy;
  51. /**
  52. * 更新时间
  53. */
  54. @TableField(value = "last_update_time")
  55. private Date lastUpdateTime;
  56. @TableField(exist = false)
  57. private static final long serialVersionUID = 1L;
  58. @Override
  59. public boolean equals(Object that) {
  60. if (this == that) {
  61. return true;
  62. }
  63. if (that == null) {
  64. return false;
  65. }
  66. if (getClass() != that.getClass()) {
  67. return false;
  68. }
  69. SysRoleMenuKzt other = (SysRoleMenuKzt) that;
  70. return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
  71. && (this.getRoleId() == null ? other.getRoleId() == null : this.getRoleId().equals(other.getRoleId()))
  72. && (this.getMenuId() == null ? other.getMenuId() == null : this.getMenuId().equals(other.getMenuId()))
  73. && (this.getSysType() == null ? other.getSysType() == null : this.getSysType().equals(other.getSysType()))
  74. && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
  75. && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
  76. && (this.getLastUpdateBy() == null ? other.getLastUpdateBy() == null : this.getLastUpdateBy().equals(other.getLastUpdateBy()))
  77. && (this.getLastUpdateTime() == null ? other.getLastUpdateTime() == null : this.getLastUpdateTime().equals(other.getLastUpdateTime()));
  78. }
  79. @Override
  80. public int hashCode() {
  81. final int prime = 31;
  82. int result = 1;
  83. result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
  84. result = prime * result + ((getRoleId() == null) ? 0 : getRoleId().hashCode());
  85. result = prime * result + ((getMenuId() == null) ? 0 : getMenuId().hashCode());
  86. result = prime * result + ((getSysType() == null) ? 0 : getSysType().hashCode());
  87. result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
  88. result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
  89. result = prime * result + ((getLastUpdateBy() == null) ? 0 : getLastUpdateBy().hashCode());
  90. result = prime * result + ((getLastUpdateTime() == null) ? 0 : getLastUpdateTime().hashCode());
  91. return result;
  92. }
  93. @Override
  94. public String toString() {
  95. StringBuilder sb = new StringBuilder();
  96. sb.append(getClass().getSimpleName());
  97. sb.append(" [");
  98. sb.append("Hash = ").append(hashCode());
  99. sb.append(", id=").append(id);
  100. sb.append(", roleId=").append(roleId);
  101. sb.append(", menuId=").append(menuId);
  102. sb.append(", sysType=").append(sysType);
  103. sb.append(", createBy=").append(createBy);
  104. sb.append(", createTime=").append(createTime);
  105. sb.append(", lastUpdateBy=").append(lastUpdateBy);
  106. sb.append(", lastUpdateTime=").append(lastUpdateTime);
  107. sb.append(", serialVersionUID=").append(serialVersionUID);
  108. sb.append("]");
  109. return sb.toString();
  110. }
  111. public SysRoleMenuKzt() {
  112. }
  113. public SysRoleMenuKzt(Long id, Long roleId, Long menuId, String sysType, String createBy, Date createTime, String lastUpdateBy, Date lastUpdateTime) {
  114. this.id = id;
  115. this.roleId = roleId;
  116. this.menuId = menuId;
  117. this.sysType = sysType;
  118. this.createBy = createBy;
  119. this.createTime = createTime;
  120. this.lastUpdateBy = lastUpdateBy;
  121. this.lastUpdateTime = lastUpdateTime;
  122. }
  123. }