package com.miaxis.dict.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.miaxis.common.annotation.Excel;
import com.miaxis.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.miaxis.common.core.domain.BaseBusinessEntity;
import lombok.Data;
/**
 * 全国城市对象 dict_city
 *
 * @author miaxis
 * @date 2021-03-18
 */
@Data
@TableName("dict_city")
@ApiModel(value = "DictCity", description = "全国城市对象 dict_city")
public class DictCity {
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @TableId(value = "id")
    @ApiModelProperty(value = "主键")
    private Long id;

    /** 编码 */
    @Excel(name = "编码")
    @TableField("code")
    @ApiModelProperty(value = "编码")
    private String code;

    /** 上级编码 */
    @Excel(name = "上级编码")
    @TableField("parentCode")
    @ApiModelProperty(value = "上级编码")
    private String parentcode;

    /** 名称 */
    @Excel(name = "名称")
    @TableField("name")
    @ApiModelProperty(value = "名称")
    private String name;

    /** 等级1省 2市 3区 4街道 */
    @Excel(name = "等级1省 2市 3区 4街道")
    @TableField("level")
    @ApiModelProperty(value = "等级1省 2市 3区 4街道" ,required = true    )
    private Integer level;

    /** 是否末级 1是 0否 */
    @Excel(name = "是否末级 1是 0否")
    @TableField("last")
    @ApiModelProperty(value = "是否末级 1是 0否")
    private Integer last;

    /** 状态 1正常 2禁用 */
    @Excel(name = "状态 1正常 2禁用")
    @TableField("status")
    @ApiModelProperty(value = "状态 1正常 2禁用")
    private Long status;

    public void setId(Long id){
        this.id = id;
    }

    public Long getId(){
        return id;
    }
    public void setCode(String code){
        this.code = code;
    }

    public String getCode(){
        return code;
    }
    public void setParentcode(String parentcode){
        this.parentcode = parentcode;
    }

    public String getParentcode(){
        return parentcode;
    }
    public void setName(String name){
        this.name = name;
    }

    public String getName(){
        return name;
    }
    public void setLevel(Integer level){
        this.level = level;
    }

    public Integer getLevel(){
        return level;
    }
    public void setLast(Integer last){
        this.last = last;
    }

    public Integer getLast(){
        return last;
    }
    public void setStatus(Long status){
        this.status = status;
    }

    public Long getStatus(){
        return status;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("code", getCode())
            .append("parentcode", getParentcode())
            .append("name", getName())
            .append("level", getLevel())
            .append("last", getLast())
            .append("status", getStatus())
            .toString();
    }
}
