package com.mortals.xhx.module.position.model;
import java.util.List;
import java.util.ArrayList;
import java.math.BigDecimal;
import cn.hutool.core.date.DateUtil;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.mortals.framework.annotation.Excel;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.position.model.vo.PositionVo;
import lombok.Data;
/**
* 职位信息实体对象
*
* @author zxfei
* @date 2023-09-18
*/
@Data
public class PositionEntity extends PositionVo {
    private static final long serialVersionUID = 1L;

    /**
    * 分组id
    */
    private Long groupId;
    /**
    * 分组名称
    */
    private String groupName;
    /**
    * 职位编码
    */
    private String positionCode;
    /**
    * 职位名称
    */
    private String positionName;
    /**
    * 节点类型(1.分组,2.职位)
    */
    private Integer type;
    /**
    * 备注
    */
    private String remark;
    @Override
    public int hashCode() {
         return this.getId().hashCode();
    }
    @Override
    public boolean equals(Object obj) {
        if (obj == null) return false;
        if (obj instanceof PositionEntity) {
            PositionEntity tmp = (PositionEntity) obj;
            if (this.getId() == tmp.getId()) {
                 return true;
            }
        }
        return false;
    }

    public void initAttrValue(){
            this.groupId = 0L;
            this.groupName = "";
            this.positionCode = "";
            this.positionName = "";
            this.type = 1;
            this.remark = "";
    }
}