package com.ruoyi.system.domain;

import java.util.List;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * 行政区划对象 blade_region
 * 
 * @author dm
 * @date 2023-02-13
 */
@Data
@ApiModel(value = "行政区划对象")
public class BladeRegion extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 区划编号 */
    @ApiModelProperty(value = "区划编号")
    private String code;

    /** 父区划编号 */
    @Excel(name = "父区划编号")
    @ApiModelProperty(value = "父区划编号")
    private String parentCode;

    /** 祖区划编号 */
    @Excel(name = "祖区划编号")
    @ApiModelProperty(value = "祖区划编号")
    private String ancestors;

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

    /** 邮编 */
    @Excel(name = "邮编")
    @ApiModelProperty(value = "邮编")
    private String zipCode;

    /** 省级区划编号 */
    @Excel(name = "省级区划编号")
    @ApiModelProperty(value = "省级区划编号")
    private String provinceCode;

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

    /** 市级区划编号 */
    @Excel(name = "市级区划编号")
    @ApiModelProperty(value = "市级区划编号")
    private String cityCode;

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

    /** 区级区划编号 */
    @Excel(name = "区级区划编号")
    @ApiModelProperty(value = "区级区划编号")
    private String districtCode;

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

    /** 镇级区划编号 */
    @Excel(name = "镇级区划编号")
    @ApiModelProperty(value = "镇级区划编号")
    private String townCode;

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

    /** 村级区划编号 */
    @Excel(name = "村级区划编号")
    @ApiModelProperty(value = "村级区划编号")
    private String villageCode;

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

    /** 层级 */
    @Excel(name = "层级")
    @ApiModelProperty(value = "层级")
    private Integer regionLevel;

    /** 排序 */
    @Excel(name = "排序")
    @ApiModelProperty(value = "排序")
    private Integer sort;

    /** 区级简称 */
    @Excel(name = "区级简称")
    @ApiModelProperty(value = "区级简称")
    private String districtShortName;

    /** 市级简称 */
    @Excel(name = "市级简称")
    @ApiModelProperty(value = "市级简称")
    private String cityShortName;
    
    /**
     * 城市列表
     */
    @TableField(exist = false)
    private List<BladeRegion>areaList;

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("code", getCode())
            .append("parentCode", getParentCode())
            .append("ancestors", getAncestors())
            .append("name", getName())
            .append("zipCode", getZipCode())
            .append("provinceCode", getProvinceCode())
            .append("provinceName", getProvinceName())
            .append("cityCode", getCityCode())
            .append("cityName", getCityName())
            .append("districtCode", getDistrictCode())
            .append("districtName", getDistrictName())
            .append("townCode", getTownCode())
            .append("townName", getTownName())
            .append("villageCode", getVillageCode())
            .append("villageName", getVillageName())
            .append("regionLevel", getRegionLevel())
            .append("sort", getSort())
            .append("remark", getRemark())
            .append("districtShortName", getDistrictShortName())
            .append("cityShortName", getCityShortName())
            .toString();
    }
}
