package com.yunfeiyun.agmp.common.web.system.domain;

import com.yunfeiyun.agmp.common.core.domain.BaseEntity;

import java.util.ArrayList;
import java.util.List;

/**
 * 菜单权限表 sysMenuconfig
 *
 * @author 杨晓辉
 */
public class SysMenuConfig extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 菜单标识 */
    private String menucfgId;

    /** 菜单系统标识 */
    private String menucfgSys;

    /** 菜单配置排列 */
    private int menucfgSeq;

    /** 菜单配置状态 */
    private String menucfgStaus;


    /** 子系统系统配置名称 */
    private String sysName;


    /** 菜单标识 */
    private String menuId;

    /** 菜单系统配置名称 */
    private String menuName;

    /** 菜单排列 */
    private int menuSeq;


    /** 父菜单ID */
    private String menuParentid;


    /** 子菜单 */
    private List<SysMenuConfig> children = new ArrayList<SysMenuConfig>();

    public static SysMenuConfig build(String menucfgId , String menuId , String menucfgSys , String menuName , int menuSeq,String menuParentid){
        SysMenuConfig sysMenuConfig = new SysMenuConfig();
        sysMenuConfig.setMenucfgId( menucfgId );
        sysMenuConfig.setMenuId( menuId );
        sysMenuConfig.setMenucfgSys( menucfgSys );
        sysMenuConfig.setMenuName( menuName );
        sysMenuConfig.setMenuSeq( menuSeq );
        sysMenuConfig.setMenuParentid( menuParentid );
        return sysMenuConfig;
    }

    public String getMenucfgId() {
        return menucfgId;
    }

    public void setMenucfgId(String menucfgId) {
        this.menucfgId = menucfgId;
    }

    public String getMenuId() {
        return menuId;
    }

    public void setMenuId(String menuId) {
        this.menuId = menuId;
    }

    public String getMenucfgSys() {
        return menucfgSys;
    }

    public void setMenucfgSys(String menucfgSys) {
        this.menucfgSys = menucfgSys;
    }

    public String getMenuName() {
        return menuName;
    }

    public void setMenuName(String menuName) {
        this.menuName = menuName;
    }
    public int getMenuSeq() {
        return menuSeq;
    }

    public void setMenuSeq(int menuSeq) {
        this.menuSeq = menuSeq;
    }

    public List<SysMenuConfig> getChildren()
    {
        return children;
    }

    public void setChildren(List<SysMenuConfig> children)
    {
        this.children = children;
    }

    public String getMenuParentid()
    {
        return menuParentid;
    }

    public void setMenuParentid(String menuParentid)
    {
        this.menuParentid = menuParentid;
    }

    public int getMenucfgSeq() {
        return menucfgSeq;
    }

    public void setMenucfgSeq(int menucfgSeq) {
        this.menucfgSeq = menucfgSeq;
    }

    public String getSysName() {
        return sysName;
    }

    public void setSysName(String sysName) {
        this.sysName = sysName;
    }

    public String getMenucfgStaus() {
        return menucfgStaus;
    }

    public void setMenucfgStaus(String menucfgStaus) {
        this.menucfgStaus = menucfgStaus;
    }

    public boolean isMenucfgEnabled() {
        return "0".equals(getMenucfgStaus());
    }

}
