PurchaseDetailSimpleInfo.java 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. package com.uas.search.console.model;
  2. import java.util.Objects;
  3. import javax.persistence.Column;
  4. import javax.persistence.Entity;
  5. import javax.persistence.Id;
  6. import javax.persistence.Table;
  7. /**
  8. * 商城采购订单明细
  9. *
  10. * @author sunyj
  11. * @since 2016年10月14日 上午10:27:53
  12. */
  13. @Entity
  14. @Table(name = "trade$purchase_detail")
  15. public class PurchaseDetailSimpleInfo {
  16. @Id
  17. @Column(name = "id")
  18. private Long id;
  19. /**
  20. * 明细序号 detailNO
  21. */
  22. @Column(name = "detno")
  23. private Short detno;
  24. /**
  25. * 采购单明细编号,因易与id命名混淆,其他类、lucenne建索引时该字段难以区分,特以此命名
  26. */
  27. @Column(name = "detail_id", unique = true)
  28. private String code;
  29. /**
  30. * 原厂型号
  31. */
  32. @Column(name = "cmp_code")
  33. private String cmpCode;
  34. /**
  35. * 器件所属类目
  36. */
  37. @Column(name = "ki_name")
  38. private String kiName;
  39. /**
  40. * 器件所属品牌
  41. */
  42. @Column(name = "br_name")
  43. private String brName;
  44. /**
  45. * 采购单明细状态
  46. */
  47. @Column(name = "detail_status")
  48. private Integer status;
  49. public Long getId() {
  50. return id;
  51. }
  52. public void setId(Long id) {
  53. this.id = id;
  54. }
  55. public String getCode() {
  56. return code;
  57. }
  58. public void setCode(String code) {
  59. this.code = code;
  60. }
  61. public Short getDetno() {
  62. return detno;
  63. }
  64. public void setDetno(Short detno) {
  65. this.detno = detno;
  66. }
  67. public String getCmpCode() {
  68. return cmpCode;
  69. }
  70. public void setCmpCode(String cmpCode) {
  71. this.cmpCode = cmpCode;
  72. }
  73. public String getKiName() {
  74. return kiName;
  75. }
  76. public void setKiName(String kiName) {
  77. this.kiName = kiName;
  78. }
  79. public String getBrName() {
  80. return brName;
  81. }
  82. public void setBrName(String brName) {
  83. this.brName = brName;
  84. }
  85. public Integer getStatus() {
  86. return status;
  87. }
  88. public void setStatus(Integer status) {
  89. this.status = status;
  90. }
  91. public boolean equals(Object otherObject) {
  92. if (this == otherObject) {
  93. return true;
  94. }
  95. if (otherObject == null || getClass() != otherObject.getClass()
  96. || !(otherObject instanceof PurchaseDetailSimpleInfo)) {
  97. return false;
  98. }
  99. PurchaseDetailSimpleInfo other = (PurchaseDetailSimpleInfo) otherObject;
  100. return Objects.equals(id, other.getId()) && Objects.equals(code, other.getCode())
  101. && Objects.equals(detno, other.getDetno()) && Objects.equals(cmpCode, other.getCmpCode())
  102. && Objects.equals(kiName, other.getKiName()) && Objects.equals(brName, other.getBrName())
  103. && Objects.equals(status, other.getStatus());
  104. }
  105. @Override
  106. public String toString() {
  107. return "PurchaseDetailSimpleInfo [id=" + id + ", detno=" + detno + ", code=" + code + ", cmpCode=" + cmpCode
  108. + ", kiName=" + kiName + ", brName=" + brName + ", status=" + status + "]";
  109. }
  110. }