package com.goldenwater.system.domain;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.goldenwater.common.core.domain.BaseEntity;
import com.goldenwater.common.xss.Xss;

/**
 * 系统分类表 SYS_CATE
 * 
 * @author goldenwater
 */
public class SysCate extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 分类编码 */
    private String cateCode;

    /** 父分类编码 */
    private String catePcode;

    /** 分类表名 */
    private String cateTable;

    /** 分类名称 */
    private String cateName;

    /** 分类描述 */
    private String cateDesc;

    /** 显示顺序 */
    private Integer cateSeq;

    /** 分类状态（0正常 1停用） */
    private Integer cateStatus;

    public String getCateCode()
    {
        return cateCode;
    }

    public void setCateCode(String cateCode)
    {
        this.cateCode = cateCode;
    }

    public String getCatePcode()
    {
        return catePcode;
    }

    public void setCatePcode(String catePcode)
    {
        this.catePcode = catePcode;
    }

    public String getCateTable()
    {
        return cateTable;
    }

    public void setCateTable(String cateTable)
    {
        this.cateTable = cateTable;
    }

    @Xss(message = "分类名称不能包含脚本字符")
    @NotBlank(message = "分类名称不能为空")
    @Size(min = 0, max = 100, message = "分类名称不能超过100个字符")
    public String getCateName()
    {
        return cateName;
    }

    public void setCateName(String cateName)
    {
        this.cateName = cateName;
    }

    public String getCateDesc()
    {
        return cateDesc;
    }

    public void setCateDesc(String cateDesc)
    {
        this.cateDesc = cateDesc;
    }

    public Integer getCateSeq()
    {
        return cateSeq;
    }

    public void setCateSeq(Integer cateSeq)
    {
        this.cateSeq = cateSeq;
    }

    public Integer getCateStatus()
    {
        return cateStatus;
    }

    public void setCateStatus(Integer cateStatus)
    {
        this.cateStatus = cateStatus;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("cateCode", getCateCode())
            .append("catePcode", getCatePcode())
            .append("cateTable", getCateTable())
            .append("cateName", getCateName())
            .append("cateDesc", getCateDesc())
            .append("cateSeq", getCateSeq())
            .append("cateStatus", getCateStatus())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}
