package com.uas.search.console.model; import java.util.Objects; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Id; import javax.persistence.Table; /** * 商城采购订单明细 * * @author sunyj * @since 2016年10月14日 上午10:27:53 */ @Entity @Table(name = "trade$purchase_detail") public class PurchaseDetailSimpleInfo { @Id @Column(name = "id") private Long id; /** * 明细序号 detailNO */ @Column(name = "detno") private Short detno; /** * 采购单明细编号,因易与id命名混淆,其他类、lucenne建索引时该字段难以区分,特以此命名 */ @Column(name = "detail_id", unique = true) private String code; /** * 原厂型号 */ @Column(name = "cmp_code") private String cmpCode; /** * 器件所属类目 */ @Column(name = "ki_name") private String kiName; /** * 器件所属品牌 */ @Column(name = "br_name") private String brName; /** * 采购单明细状态 */ @Column(name = "detail_status") private Integer status; public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getCode() { return code; } public void setCode(String code) { this.code = code; } public Short getDetno() { return detno; } public void setDetno(Short detno) { this.detno = detno; } public String getCmpCode() { return cmpCode; } public void setCmpCode(String cmpCode) { this.cmpCode = cmpCode; } public String getKiName() { return kiName; } public void setKiName(String kiName) { this.kiName = kiName; } public String getBrName() { return brName; } public void setBrName(String brName) { this.brName = brName; } public Integer getStatus() { return status; } public void setStatus(Integer status) { this.status = status; } public boolean equals(Object otherObject) { if (this == otherObject) { return true; } if (otherObject == null || getClass() != otherObject.getClass() || !(otherObject instanceof PurchaseDetailSimpleInfo)) { return false; } PurchaseDetailSimpleInfo other = (PurchaseDetailSimpleInfo) otherObject; return Objects.equals(id, other.getId()) && Objects.equals(code, other.getCode()) && Objects.equals(detno, other.getDetno()) && Objects.equals(cmpCode, other.getCmpCode()) && Objects.equals(kiName, other.getKiName()) && Objects.equals(brName, other.getBrName()) && Objects.equals(status, other.getStatus()); } @Override public String toString() { return "PurchaseDetailSimpleInfo [id=" + id + ", detno=" + detno + ", code=" + code + ", cmpCode=" + cmpCode + ", kiName=" + kiName + ", brName=" + brName + ", status=" + status + "]"; } }