namespace SafeCampus.System;
///
/// 资源
///
[SugarTable("sys_resource", TableDescription = "资源")]
[Tenant(SqlSugarConst.DB_DEFAULT)]
[IgnoreInitTable]
public class SysResource : BaseEntity
{
///
/// 父id
///
[SugarColumn(ColumnName = "ParentId", ColumnDescription = "父id", IsNullable = true)]
public virtual long? ParentId { get; set; }
///
/// 标题
///
[SugarColumn(ColumnName = "Title", ColumnDescription = "标题", Length = 200)]
public virtual string Title { get; set; }
///
/// 别名
///
[SugarColumn(ColumnName = "Name", ColumnDescription = "别名", Length = 200, IsNullable = true)]
public string Name { get; set; }
///
/// 描述
///
[SugarColumn(ColumnName = "Description", ColumnDescription = "描述", Length = 200, IsNullable = true)]
public string Description { get; set; }
///
/// 编码
///
[SugarColumn(ColumnName = "Code", ColumnDescription = "编码", Length = 200, IsNullable = true)]
public virtual string Code { get; set; }
///
/// 分类
///
[SugarColumn(ColumnName = "Category", ColumnDescription = "分类", Length = 200)]
public string Category { get; set; }
///
/// 模块
///
[SugarColumn(ColumnName = "Module", ColumnDescription = "所属模块Id", IsNullable = true)]
public virtual long? Module { get; set; }
///
/// 菜单类型
///
[SugarColumn(ColumnName = "MenuType", ColumnDescription = "菜单类型", Length = 200, IsNullable = true)]
public virtual string MenuType { get; set; }
///
/// 路径
///
[SugarColumn(ColumnName = "Path", ColumnDescription = "路径", IsNullable = true)]
public virtual string Path { get; set; }
///
/// 组件
///
[SugarColumn(ColumnName = "Component", ColumnDescription = "组件", Length = 200, IsNullable = true)]
public string Component { get; set; }
///
/// 图标
///
[SugarColumn(ColumnName = "Icon", ColumnDescription = "图标", Length = 200, IsNullable = true)]
public virtual string Icon { get; set; }
///
/// 是否在菜单中隐藏, 需要高亮的 path (通常用作详情页高亮父级菜单)
///
[SugarColumn(ColumnName = "ActiveMenu", ColumnDescription = "需要高亮的 path (通常用作详情页高亮父级菜单)", Length = 200, IsNullable = true)]
public string ActiveMenu { get; set; }
///
/// 是否在菜单中隐藏 (通常列表详情页需要隐藏)
///
[SugarColumn(ColumnName = "IsHide", ColumnDescription = "是否在菜单中隐藏 (通常列表详情页需要隐藏) ", IsNullable = true)]
public bool IsHide { get; set; }
///
/// 是否在菜单中隐藏 (通常列表详情页需要隐藏)
///
[SugarColumn(ColumnName = "IsFull", ColumnDescription = "菜单是否全屏 (示例:数据大屏页面)", IsNullable = true)]
public bool IsFull { get; set; }
///
/// 菜单是否固定在标签页中 (首页通常是固定项)
///
[SugarColumn(ColumnName = "IsAffix", ColumnDescription = "菜单是否固定在标签页中 (首页通常是固定项)", IsNullable = true)]
public bool IsAffix { get; set; }
///
/// 菜单是否固定在标签页中 (首页通常是固定项)
///
[SugarColumn(ColumnName = "IsKeepAlive", ColumnDescription = " 当前路由是否缓存", IsNullable = true)]
public bool IsKeepAlive { get; set; }
///
/// 是否为首页
///
[SugarColumn(ColumnName = "IsHome", ColumnDescription = " 是否为首页", IsNullable = true)]
public bool IsHome { get; set; }
///
/// 排序码
///
[SugarColumn(ColumnName = "SortCode", ColumnDescription = "排序码", IsNullable = true)]
public int? SortCode { get; set; }
///
/// 菜单元标签
///
[SugarColumn(IsIgnore = true)]
public Meta Meta { get; set; }
///
/// 子节点
///
[SugarColumn(IsIgnore = true)]
public List Children { get; set; }
}
///
/// 菜单元标签
///
public class Meta
{
///
/// 图标
///
public string Icon { get; set; }
///
/// 标题
///
public string Title { get; set; }
///
/// 是否在菜单中隐藏, 需要高亮的 path (通常用作详情页高亮父级菜单)
///
public string ActiveMenu { get; set; }
///
/// 是否在菜单中隐藏 (通常列表详情页需要隐藏)
///
public bool IsHide { get; set; }
///
/// 路由外链时填写的访问地址
///
public string IsLink { get; set; } = "";
///
/// 是否在菜单中隐藏 (通常列表详情页需要隐藏)
///
public bool IsFull { get; set; }
///
/// 菜单是否固定在标签页中 (首页通常是固定项)
///
public bool IsAffix { get; set; }
///
/// 菜单是否固定在标签页中 (首页通常是固定项)
///
public bool IsKeepAlive { get; set; }
}