package org.linlinjava.jz.db.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.linlinjava.jz.db.dto.hm.HmEmployClockExtend;

import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.Arrays;

public class HmEmployClock extends HmEmployClockExtend{
    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.id
     *
     * @mbg.generated
     */
    private Long id;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.work_data
     *
     * @mbg.generated
     */
    private LocalDateTime workData;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.is_restday
     *
     * @mbg.generated
     */
    private Integer isRestday;


    private Integer isHoliday;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.start_work_time
     *
     * @mbg.generated
     */
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm")
    private LocalDateTime startWorkTime;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.end_work_time
     *
     * @mbg.generated
     */
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm")
    private LocalDateTime endWorkTime;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.status
     *
     * @mbg.generated
     */
    private Integer status;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.leave_date
     *
     * @mbg.generated
     */
    private LocalDateTime leaveDate;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.leave_reason
     *
     * @mbg.generated
     */
    private String leaveReason;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.approval_state
     *
     * @mbg.generated
     */
    private Integer approvalState;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.approval_reason
     *
     * @mbg.generated
     */
    private String approvalReason;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.order_no
     *
     * @mbg.generated
     */
    private String orderNo;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.employ_relation_id
     *
     * @mbg.generated
     */
    private Long employRelationId;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.create_time
     *
     * @mbg.generated
     */
    private LocalDateTime createTime;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.update_time
     *
     * @mbg.generated
     */
    private LocalDateTime updateTime;

    /**
     *
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database column hm_employ_clock.remark
     *
     * @mbg.generated
     */
    private String remark;

    private String servantName;

    private Integer star;

    public String getServantName() {
        return servantName;
    }

    public void setServantName(String servantName) {
        this.servantName = servantName;
    }

    public Integer getStar() {
        return star;
    }

    public void setStar(Integer star) {
        this.star = star;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.id
     *
     * @return the value of hm_employ_clock.id
     *
     * @mbg.generated
     */
    public Long getId() {
        return id;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.id
     *
     * @param id the value for hm_employ_clock.id
     *
     * @mbg.generated
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.work_data
     *
     * @return the value of hm_employ_clock.work_data
     *
     * @mbg.generated
     */
    public LocalDateTime getWorkData() {
        return workData;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.work_data
     *
     * @param workData the value for hm_employ_clock.work_data
     *
     * @mbg.generated
     */
    public void setWorkData(LocalDateTime workData) {
        this.workData = workData;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.is_restday
     *
     * @return the value of hm_employ_clock.is_restday
     *
     * @mbg.generated
     */
    public Integer getIsRestday() {
        return isRestday;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.is_restday
     *
     * @param isRestday the value for hm_employ_clock.is_restday
     *
     * @mbg.generated
     */
    public void setIsRestday(Integer isRestday) {
        this.isRestday = isRestday;
    }

    public Integer getIsHoliday() {
        return isHoliday;
    }

    public void setIsHoliday(Integer isHoliday) {
        this.isHoliday = isHoliday;
    }


    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.start_work_time
     *
     * @return the value of hm_employ_clock.start_work_time
     *
     * @mbg.generated
     */
    
    public LocalDateTime getStartWorkTime() {
        return startWorkTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.start_work_time
     *
     * @param startWorkTime the value for hm_employ_clock.start_work_time
     *
     * @mbg.generated
     */
    public void setStartWorkTime(LocalDateTime startWorkTime) {
        this.startWorkTime = startWorkTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.end_work_time
     *
     * @return the value of hm_employ_clock.end_work_time
     *
     * @mbg.generated
     */
    public LocalDateTime getEndWorkTime() {
        return endWorkTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.end_work_time
     *
     * @param endWorkTime the value for hm_employ_clock.end_work_time
     *
     * @mbg.generated
     */
    public void setEndWorkTime(LocalDateTime endWorkTime) {
        this.endWorkTime = endWorkTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.status
     *
     * @return the value of hm_employ_clock.status
     *
     * @mbg.generated
     */
    public Integer getStatus() {
        return status;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.status
     *
     * @param status the value for hm_employ_clock.status
     *
     * @mbg.generated
     */
    public void setStatus(Integer status) {
        this.status = status;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.leave_date
     *
     * @return the value of hm_employ_clock.leave_date
     *
     * @mbg.generated
     */
    public LocalDateTime getLeaveDate() {
        return leaveDate;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.leave_date
     *
     * @param leaveDate the value for hm_employ_clock.leave_date
     *
     * @mbg.generated
     */
    public void setLeaveDate(LocalDateTime leaveDate) {
        this.leaveDate = leaveDate;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.leave_reason
     *
     * @return the value of hm_employ_clock.leave_reason
     *
     * @mbg.generated
     */
    public String getLeaveReason() {
        return leaveReason;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.leave_reason
     *
     * @param leaveReason the value for hm_employ_clock.leave_reason
     *
     * @mbg.generated
     */
    public void setLeaveReason(String leaveReason) {
        this.leaveReason = leaveReason;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.approval_state
     *
     * @return the value of hm_employ_clock.approval_state
     *
     * @mbg.generated
     */
    public Integer getApprovalState() {
        return approvalState;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.approval_state
     *
     * @param approvalState the value for hm_employ_clock.approval_state
     *
     * @mbg.generated
     */
    public void setApprovalState(Integer approvalState) {
        this.approvalState = approvalState;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.approval_reason
     *
     * @return the value of hm_employ_clock.approval_reason
     *
     * @mbg.generated
     */
    public String getApprovalReason() {
        return approvalReason;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.approval_reason
     *
     * @param approvalReason the value for hm_employ_clock.approval_reason
     *
     * @mbg.generated
     */
    public void setApprovalReason(String approvalReason) {
        this.approvalReason = approvalReason;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.order_no
     *
     * @return the value of hm_employ_clock.order_no
     *
     * @mbg.generated
     */
    public String getOrderNo() {
        return orderNo;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.order_no
     *
     * @param orderNo the value for hm_employ_clock.order_no
     *
     * @mbg.generated
     */
    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.employ_relation_id
     *
     * @return the value of hm_employ_clock.employ_relation_id
     *
     * @mbg.generated
     */
    public Long getEmployRelationId() {
        return employRelationId;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.employ_relation_id
     *
     * @param employRelationId the value for hm_employ_clock.employ_relation_id
     *
     * @mbg.generated
     */
    public void setEmployRelationId(Long employRelationId) {
        this.employRelationId = employRelationId;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.create_time
     *
     * @return the value of hm_employ_clock.create_time
     *
     * @mbg.generated
     */
    public LocalDateTime getCreateTime() {
        return createTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.create_time
     *
     * @param createTime the value for hm_employ_clock.create_time
     *
     * @mbg.generated
     */
    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.update_time
     *
     * @return the value of hm_employ_clock.update_time
     *
     * @mbg.generated
     */
    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.update_time
     *
     * @param updateTime the value for hm_employ_clock.update_time
     *
     * @mbg.generated
     */
    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method returns the value of the database column hm_employ_clock.remark
     *
     * @return the value of hm_employ_clock.remark
     *
     * @mbg.generated
     */
    public String getRemark() {
        return remark;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method sets the value of the database column hm_employ_clock.remark
     *
     * @param remark the value for hm_employ_clock.remark
     *
     * @mbg.generated
     */
    public void setRemark(String remark) {
        this.remark = remark;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table hm_employ_clock
     *
     * @mbg.generated
     */
    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", workData=").append(workData);
        sb.append(", isRestday=").append(isRestday);
        sb.append(", startWorkTime=").append(startWorkTime);
        sb.append(", endWorkTime=").append(endWorkTime);
        sb.append(", status=").append(status);
        sb.append(", leaveDate=").append(leaveDate);
        sb.append(", leaveReason=").append(leaveReason);
        sb.append(", approvalState=").append(approvalState);
        sb.append(", approvalReason=").append(approvalReason);
        sb.append(", orderNo=").append(orderNo);
        sb.append(", employRelationId=").append(employRelationId);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", remark=").append(remark);
        sb.append("]");
        return sb.toString();
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table hm_employ_clock
     *
     * @mbg.generated
     */
    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HmEmployClock other = (HmEmployClock) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getWorkData() == null ? other.getWorkData() == null : this.getWorkData().equals(other.getWorkData()))
            && (this.getIsRestday() == null ? other.getIsRestday() == null : this.getIsRestday().equals(other.getIsRestday()))
            && (this.getStartWorkTime() == null ? other.getStartWorkTime() == null : this.getStartWorkTime().equals(other.getStartWorkTime()))
            && (this.getEndWorkTime() == null ? other.getEndWorkTime() == null : this.getEndWorkTime().equals(other.getEndWorkTime()))
            && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
            && (this.getLeaveDate() == null ? other.getLeaveDate() == null : this.getLeaveDate().equals(other.getLeaveDate()))
            && (this.getLeaveReason() == null ? other.getLeaveReason() == null : this.getLeaveReason().equals(other.getLeaveReason()))
            && (this.getApprovalState() == null ? other.getApprovalState() == null : this.getApprovalState().equals(other.getApprovalState()))
            && (this.getApprovalReason() == null ? other.getApprovalReason() == null : this.getApprovalReason().equals(other.getApprovalReason()))
            && (this.getOrderNo() == null ? other.getOrderNo() == null : this.getOrderNo().equals(other.getOrderNo()))
            && (this.getEmployRelationId() == null ? other.getEmployRelationId() == null : this.getEmployRelationId().equals(other.getEmployRelationId()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()));
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table hm_employ_clock
     *
     * @mbg.generated
     */
    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getWorkData() == null) ? 0 : getWorkData().hashCode());
        result = prime * result + ((getIsRestday() == null) ? 0 : getIsRestday().hashCode());
        result = prime * result + ((getStartWorkTime() == null) ? 0 : getStartWorkTime().hashCode());
        result = prime * result + ((getEndWorkTime() == null) ? 0 : getEndWorkTime().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getLeaveDate() == null) ? 0 : getLeaveDate().hashCode());
        result = prime * result + ((getLeaveReason() == null) ? 0 : getLeaveReason().hashCode());
        result = prime * result + ((getApprovalState() == null) ? 0 : getApprovalState().hashCode());
        result = prime * result + ((getApprovalReason() == null) ? 0 : getApprovalReason().hashCode());
        result = prime * result + ((getOrderNo() == null) ? 0 : getOrderNo().hashCode());
        result = prime * result + ((getEmployRelationId() == null) ? 0 : getEmployRelationId().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
        return result;
    }

    /**
     * This enum was generated by MyBatis Generator.
     * This enum corresponds to the database table hm_employ_clock
     *
     * @mbg.generated
     */
    public enum Column {
        id("id", "id", "BIGINT", false),
        workData("work_data", "workData", "TIMESTAMP", false),
        isRestday("is_restday", "isRestday", "INTEGER", false),
        startWorkTime("start_work_time", "startWorkTime", "TIMESTAMP", false),
        endWorkTime("end_work_time", "endWorkTime", "TIMESTAMP", false),
        status("status", "status", "INTEGER", true),
        leaveDate("leave_date", "leaveDate", "TIMESTAMP", false),
        leaveReason("leave_reason", "leaveReason", "VARCHAR", false),
        approvalState("approval_state", "approvalState", "INTEGER", false),
        approvalReason("approval_reason", "approvalReason", "VARCHAR", false),
        orderNo("order_no", "orderNo", "VARCHAR", false),
        employRelationId("employ_relation_id", "employRelationId", "BIGINT", false),
        createTime("create_time", "createTime", "TIMESTAMP", false),
        updateTime("update_time", "updateTime", "TIMESTAMP", false),
        remark("remark", "remark", "VARCHAR", false);

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private static final String BEGINNING_DELIMITER = "`";

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private static final String ENDING_DELIMITER = "`";

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private final String column;

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private final boolean isColumnNameDelimited;

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private final String javaProperty;

        /**
         * This field was generated by MyBatis Generator.
         * This field corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        private final String jdbcType;

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String value() {
            return this.column;
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String getValue() {
            return this.column;
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String getJavaProperty() {
            return this.javaProperty;
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String getJdbcType() {
            return this.jdbcType;
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        Column(String column, String javaProperty, String jdbcType, boolean isColumnNameDelimited) {
            this.column = column;
            this.javaProperty = javaProperty;
            this.jdbcType = jdbcType;
            this.isColumnNameDelimited = isColumnNameDelimited;
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String desc() {
            return this.getEscapedColumnName() + " DESC";
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String asc() {
            return this.getEscapedColumnName() + " ASC";
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public static Column[] excludes(Column ... excludes) {
            ArrayList<Column> columns = new ArrayList<>(Arrays.asList(Column.values()));
            if (excludes != null && excludes.length > 0) {
                columns.removeAll(new ArrayList<>(Arrays.asList(excludes)));
            }
            return columns.toArray(new Column[]{});
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public static Column[] all() {
            return Column.values();
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String getEscapedColumnName() {
            if (this.isColumnNameDelimited) {
                return new StringBuilder().append(BEGINNING_DELIMITER).append(this.column).append(ENDING_DELIMITER).toString();
            } else {
                return this.column;
            }
        }

        /**
         * This method was generated by MyBatis Generator.
         * This method corresponds to the database table hm_employ_clock
         *
         * @mbg.generated
         */
        public String getAliasedEscapedColumnName() {
            return this.getEscapedColumnName();
        }
    }
}