jinpengyong
2023-08-25 f9f8f90ac63d6ce3274410d3721b173f40db6e41
screen-manage/src/main/java/com/moral/api/entity/VersionSensorUnit.java
@@ -7,6 +7,7 @@
import java.time.LocalDateTime;
import java.io.Serializable;
import java.util.Date;
import java.util.Objects;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -77,10 +78,22 @@
     */
    private String isDelete;
    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        VersionSensorUnit that = (VersionSensorUnit) o;
        return Objects.equals(sensorCode, that.sensorCode) &&
                Objects.equals(unitKey, that.unitKey) &&
                Objects.equals(upper, that.upper) &&
                Objects.equals(lower, that.lower);
    }
    @Override
    protected Serializable pkVal() {
        return this.id;
    public int hashCode() {
        return Objects.hash(super.hashCode(), sensorCode, unitKey, upper, lower);
    }
}