using SqlSugar; using System; using System.Collections.Generic; namespace Tiobon.Core.Model.Models { /// /// 路由菜单表 /// public class Permission : PermissionRoot { public Permission() { //this.ModulePermission = new List(); //this.RoleModulePermission = new List(); } /// /// 菜单执行Action名 /// [SugarColumn(Length = 50, IsNullable = true)] public string Code { get; set; } /// /// 菜单显示名(如用户页、编辑(按钮)、删除(按钮)) /// [SugarColumn(Length = 50, IsNullable = true)] public string Name { get; set; } /// /// 是否是按钮 /// public bool IsButton { get; set; } = false; /// /// 是否是隐藏菜单 /// [SugarColumn(IsNullable = true)] public bool? IsHide { get; set; } = false; /// /// 是否keepAlive /// [SugarColumn(IsNullable = true)] public bool? IskeepAlive { get; set; } = false; /// /// 按钮事件 /// [SugarColumn(Length = 100, IsNullable = true)] public string Func { get; set; } /// /// 排序 /// public int OrderSort { get; set; } /// /// 菜单图标 /// [SugarColumn(Length = 100, IsNullable = true)] public string Icon { get; set; } /// /// 菜单描述 /// [SugarColumn(Length = 100, IsNullable = true)] public string Description { get; set; } /// /// 激活状态 /// public bool Enabled { get; set; } /// /// 创建ID /// [SugarColumn(IsNullable = true)] public long? CreateId { get; set; } /// /// 创建者 /// [SugarColumn(Length = 50, IsNullable = true)] public string CreateBy { get; set; } /// /// 创建时间 /// [SugarColumn(IsNullable = true)] public DateTime? CreateTime { get; set; } = DateTime.Now; /// /// 修改ID /// [SugarColumn(IsNullable = true)] public long? ModifyId { get; set; } /// /// 修改者 /// [SugarColumn(Length = 50, IsNullable = true)] public string ModifyBy { get; set; } /// /// 修改时间 /// [SugarColumn(IsNullable = true)] public DateTime? ModifyTime { get; set; } = DateTime.Now; /// ///获取或设置是否禁用,逻辑上的删除,非物理删除 /// [SugarColumn(IsNullable = true)] public bool? IsDeleted { get; set; } [SugarColumn(IsIgnore = true)] public List PnameArr { get; set; } = new List(); [SugarColumn(IsIgnore = true)] public List PCodeArr { get; set; } = new List(); [SugarColumn(IsIgnore = true)] public string MName { get; set; } [SugarColumn(IsIgnore = true)] public bool hasChildren { get; set; } = true; [SugarColumn(IsIgnore = true)] public List Children { get; set; } = new List(); [SugarColumn(IsIgnore = true)] public Modules Module { get; set; } //public virtual ICollection ModulePermission { get; set; } //public virtual ICollection RoleModulePermission { get; set; } } }