package org.jeecg.modules.system.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;

import java.io.Serializable;

/**
 * @Description: nation_depart
 * @Author: jeecg-boot
 * @Date:   2022-02-28
 * @Version: V1.0
 */
@Data
@TableName("nation_depart")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="nation_depart对象", description="nation_depart")
public class NationDepart implements Serializable {
    private static final long serialVersionUID = 1L;

	/**主键*/
	@TableId(type = IdType.AUTO)
    @ApiModelProperty(value = "主键")
    private Integer id;
	/**国家组织机构编码*/
	@Excel(name = "国家组织机构编码", width = 15)
    @ApiModelProperty(value = "国家组织机构编码")
    private String orgCode;
	/**组织机构名称*/
	@Excel(name = "组织机构名称", width = 15)
    @ApiModelProperty(value = "组织机构名称")
    private String orgName;
	/**部门简称*/
	@Excel(name = "部门简称", width = 15)
    @ApiModelProperty(value = "部门简称")
    private String orgSname;
	/**统一社会信用代码*/
	@Excel(name = "统一社会信用代码", width = 15)
    @ApiModelProperty(value = "统一社会信用代码")
    private String orgCcCode;
	/**上级部门编码(nation_dept_code)*/
	@Excel(name = "上级部门编码(nation_dept_code)", width = 15)
    @ApiModelProperty(value = "上级部门编码(nation_dept_code)")
    private String parentOrgCode;
	/**上级部门名称(nation_dept_name)*/
	@Excel(name = "上级部门名称(nation_dept_name)", width = 15)
    @ApiModelProperty(value = "上级部门名称(nation_dept_name)")
    private String parentOrgName;
	/**部门类型*/
	@Excel(name = "部门类型", width = 15)
    @ApiModelProperty(value = "部门类型")
    private String orgType;
	/**注册地址*/
	@Excel(name = "注册地址", width = 15)
    @ApiModelProperty(value = "注册地址")
    private String regAddress;
	/**经营开始日期*/
	@Excel(name = "经营开始日期", width = 15)
    @ApiModelProperty(value = "经营开始日期")
    private String regDate;
	/**经营结束日期*/
	@Excel(name = "经营结束日期", width = 15)
    @ApiModelProperty(value = "经营结束日期")
    private String businessLicenseEnd;
	/**区划编码*/
	@Excel(name = "区划编码", width = 15)
    @ApiModelProperty(value = "区划编码")
    private String regionCode;
	/**部门顺序*/
	@Excel(name = "部门顺序", width = 15)
    @ApiModelProperty(value = "部门顺序")
    private String deptOrder;
	/**部门状态*/
	@Excel(name = "部门状态", width = 15)
    @ApiModelProperty(value = "部门状态")
    private String deptStatus;
	/**是否垂管*/
	@Excel(name = "是否垂管", width = 15)
    @ApiModelProperty(value = "是否垂管")
    private String isPituitary;
	/**部门等级*/
	@Excel(name = "部门等级", width = 15)
    @ApiModelProperty(value = "部门等级")
    private String orgLevel;
	/**联系方式*/
	@Excel(name = "联系方式", width = 15)
    @ApiModelProperty(value = "联系方式")
    private String orgPhone;
	/** 联系人*/
	@Excel(name = " 联系人", width = 15)
    @ApiModelProperty(value = " 联系人")
    private String orgPerson;
	/**8位部门编码*/
	@Excel(name = "8位部门编码", width = 15)
    @ApiModelProperty(value = "8位部门编码")
    private String subCode;

	@TableField(exist = false)
	private String oldOrgCode;

	@TableField(exist = false)
	private String orgCodeKey;



    public void copyBean(NationDepart nationDepart) {
        this.setOrgCode(nationDepart.getOrgCode());
        this.setOrgName(nationDepart.getOrgName());
        this.setOrgSname(nationDepart.getOrgSname());
        this.setOrgCcCode(nationDepart.getOrgCcCode());
        this.setParentOrgCode(nationDepart.getParentOrgCode());
        this.setParentOrgName(nationDepart.getParentOrgName());
        this.setOrgType(nationDepart.getOrgType());
        this.setRegAddress(nationDepart.getRegAddress());
        this.setRegDate(nationDepart.getRegDate());
        this.setRegionCode(nationDepart.getRegionCode());
        this.setIsPituitary(nationDepart.getIsPituitary());
        this.setOrgPhone(nationDepart.getOrgPhone());
        this.setOrgPerson(nationDepart.getOrgPerson());

    }
}
