mirror of
https://github.com/nsnail/NetAdmin.git
synced 2025-08-06 16:22:28 +08:00
@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
@ -12,12 +9,14 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Api> Children { get; init; }
|
||||
|
||||
/// <inheritdoc cref="EntityBase{T}.Id" />
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127, IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public override string Id { get; init; }
|
||||
|
||||
@ -25,6 +24,7 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 请求方式
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Method { get; init; }
|
||||
|
||||
@ -32,6 +32,7 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 服务名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@ -39,6 +40,7 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 命名空间
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
#pragma warning disable CA1716
|
||||
public virtual string Namespace { get; init; }
|
||||
@ -48,12 +50,14 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ParentId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleApi))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@ -62,6 +66,7 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 服务描述
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
}
|
@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
@ -13,6 +10,7 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@ -20,12 +18,14 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册是否需要人工确认
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool UserRegisterConfirm { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户注册默认部门
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserRegisterDeptId))]
|
||||
public Sys_Dept UserRegisterDept { get; init; }
|
||||
@ -34,12 +34,14 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册默认部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserRegisterDeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户注册默认角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserRegisterRoleId))]
|
||||
public Sys_Role UserRegisterRole { get; init; }
|
||||
@ -48,6 +50,7 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册默认角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserRegisterRoleId { get; init; }
|
||||
}
|
@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
@ -12,6 +9,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Dept> Children { get; init; }
|
||||
@ -20,6 +18,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@ -27,6 +26,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 部门名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@ -34,12 +34,14 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleDept))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@ -47,6 +49,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// <summary>
|
||||
/// 发送给此部门的站内信集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgDept))]
|
||||
public ICollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@ -55,6 +58,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@ -62,6 +66,7 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 部门描述
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
}
|
@ -1,17 +1,16 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 字典目录表
|
||||
/// </summary>
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DicCatalog))]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DicCatalog))]
|
||||
public record Sys_DicCatalog : VersionEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_DicCatalog> Children { get; init; }
|
||||
@ -20,12 +19,14 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 字典编码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Code { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 字典内容集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Sys_DicContent.CatalogId))]
|
||||
public ICollection<Sys_DicContent> Contents { get; init; }
|
||||
@ -34,6 +35,7 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 字典名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@ -41,6 +43,7 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
}
|
@ -1,18 +1,19 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 字典内容表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(CatalogId)}_{nameof(Key)}", $"{nameof(CatalogId)},{nameof(Key)}", true)]
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(CatalogId)}_{nameof(Value)}", $"{nameof(CatalogId)},{nameof(Value)}", true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(CatalogId)}_{nameof(Key)}", $"{nameof(CatalogId)},{nameof(Key)}", true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(CatalogId)}_{nameof(Value)}", $"{nameof(CatalogId)},{nameof(Value)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DicContent))]
|
||||
public record Sys_DicContent : VersionEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 字典目录
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(CatalogId))]
|
||||
public Sys_DicCatalog Catalog { get; init; }
|
||||
@ -21,6 +22,7 @@ public record Sys_DicContent : VersionEntity
|
||||
/// 字典目录编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long CatalogId { get; init; }
|
||||
|
||||
@ -28,6 +30,7 @@ public record Sys_DicContent : VersionEntity
|
||||
/// 键名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Key { get; init; }
|
||||
|
||||
@ -35,6 +38,7 @@ public record Sys_DicContent : VersionEntity
|
||||
/// 键值
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Value { get; init; }
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
using HttpMethods = NetAdmin.Domain.Enums.HttpMethods;
|
||||
|
||||
@ -13,6 +11,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
{
|
||||
/// <inheritdoc cref="IFieldEnabled.Enabled" />
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@ -20,6 +19,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 执行时间计划
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ExecutionCron { get; init; }
|
||||
|
||||
@ -27,6 +27,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpMethods HttpMethod { get; init; }
|
||||
|
||||
@ -34,6 +35,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 作业名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string JobName { get; init; }
|
||||
|
||||
@ -41,6 +43,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行耗时
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long? LastDuration { get; init; }
|
||||
|
||||
@ -48,6 +51,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? LastExecTime { get; init; }
|
||||
|
||||
@ -55,6 +59,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpStatusCode? LastStatusCode { get; init; }
|
||||
|
||||
@ -62,6 +67,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 下次执行时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? NextExecTime { get; init; }
|
||||
|
||||
@ -69,6 +75,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 下次执行时间编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long? NextTimeId { get; init; }
|
||||
|
||||
@ -80,6 +87,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@ -91,6 +99,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeader { get; init; }
|
||||
|
||||
@ -102,6 +111,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@ -109,6 +119,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 作业状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual JobStatues Status { get; init; }
|
||||
|
||||
@ -118,12 +129,14 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 执行用户
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserId))]
|
||||
public Sys_User User { get; init; }
|
||||
@ -132,6 +145,7 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 执行用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserId { get; init; }
|
||||
}
|
@ -1,4 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using HttpMethods = NetAdmin.Domain.Enums.HttpMethods;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -6,10 +5,11 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 计划作业执行记录表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(JobId)}_{nameof(TimeId)}", $"{nameof(JobId)},{nameof(TimeId)}", true)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), nameof(CreatedTime), false)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(JobId), nameof(JobId), false)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(JobId)}_{nameof(TimeId)}", $"{nameof(JobId)},{nameof(TimeId)}", true)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), nameof(CreatedTime), false)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(JobId), nameof(JobId), false)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_JobRecord))]
|
||||
public record Sys_JobRecord : LiteImmutableEntity
|
||||
{
|
||||
@ -17,6 +17,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 执行耗时(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Duration { get; init; }
|
||||
|
||||
@ -24,6 +25,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpMethods HttpMethod { get; init; }
|
||||
|
||||
@ -31,12 +33,14 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// HTTP 状态码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int HttpStatusCode { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 拥有者信息
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(JobId))]
|
||||
public Sys_Job Job { get; init; }
|
||||
@ -45,6 +49,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 作业编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long JobId { get; init; }
|
||||
|
||||
@ -56,6 +61,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@ -67,6 +73,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeader { get; init; }
|
||||
|
||||
@ -74,6 +81,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求的网络地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@ -85,6 +93,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseBody { get; init; }
|
||||
|
||||
@ -96,6 +105,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseHeader { get; init; }
|
||||
|
||||
@ -103,6 +113,7 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 执行时间编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long TimeId { get; init; }
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -7,20 +5,22 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 菜单表
|
||||
/// </summary>
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Menu))]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Menu))]
|
||||
public record Sys_Menu : VersionEntity, IFieldSort
|
||||
{
|
||||
/// <summary>
|
||||
/// 子节点或详情页需要高亮的上级菜单路由地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Active { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Menu> Children { get; init; }
|
||||
@ -29,6 +29,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 背景颜色
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_7)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Color { get; init; }
|
||||
|
||||
@ -36,6 +37,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 组件
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Component { get; init; }
|
||||
|
||||
@ -43,6 +45,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否整页路由
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool FullPageRouting { get; init; }
|
||||
|
||||
@ -50,6 +53,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否隐藏菜单
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Hidden { get; init; }
|
||||
|
||||
@ -57,6 +61,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否隐藏面包屑
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool HiddenBreadCrumb { get; init; }
|
||||
|
||||
@ -64,6 +69,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 图标
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Icon { get; init; }
|
||||
|
||||
@ -71,6 +77,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@ -78,6 +85,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
|
||||
@ -85,6 +93,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单路径
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Path { get; init; }
|
||||
|
||||
@ -92,12 +101,14 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 重定向地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Redirect { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 拥有此菜单的角色集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleMenu))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@ -106,6 +117,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@ -113,6 +125,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 标签
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Tag { get; init; }
|
||||
|
||||
@ -120,6 +133,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单标题
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Title { get; init; }
|
||||
|
||||
@ -127,6 +141,7 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual MenuTypes Type { get; init; }
|
||||
}
|
@ -1,21 +1,19 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 请求日志表
|
||||
/// </summary>
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(ApiId), nameof(ApiId), false)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), nameof(CreatedTime), false)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(UserId), nameof(UserId), false)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_RequestLog))]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(ApiId), nameof(ApiId), false)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), nameof(CreatedTime), false)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(UserId), nameof(UserId), false)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_RequestLog))]
|
||||
public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedClient
|
||||
{
|
||||
/// <summary>
|
||||
/// 接口
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ApiId))]
|
||||
public Sys_Api Api { get; init; }
|
||||
@ -24,16 +22,19 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 接口编号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ApiId { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[Column(Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int? CreatedClientIp { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
@ -43,6 +44,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(Position = -1, DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserAgent { get; init; }
|
||||
|
||||
@ -50,6 +52,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 执行耗时(微秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Duration { get; init; }
|
||||
|
||||
@ -57,6 +60,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 程序响应码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual ErrorCodes ErrorCode { get; init; }
|
||||
|
||||
@ -68,6 +72,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Exception { get; init; }
|
||||
|
||||
@ -75,6 +80,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// HTTP状态码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual int HttpStatusCode { get; init; }
|
||||
|
||||
@ -82,6 +88,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Method { get; init; }
|
||||
|
||||
@ -93,6 +100,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@ -100,6 +108,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 请求content-type
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestContentType { get; init; }
|
||||
|
||||
@ -111,6 +120,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeaders { get; init; }
|
||||
|
||||
@ -118,6 +128,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 请求地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@ -129,6 +140,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseBody { get; init; }
|
||||
|
||||
@ -136,6 +148,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 响应content-type
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseContentType { get; init; }
|
||||
|
||||
@ -147,6 +160,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseHeaders { get; init; }
|
||||
|
||||
@ -154,12 +168,14 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 服务器IP
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual int? ServerIp { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserId))]
|
||||
public Sys_User User { get; init; }
|
||||
@ -168,6 +184,7 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldCreatedCli
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long? UserId { get; init; }
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
using NetAdmin.Domain.Dto.Sys.Role;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
@ -8,27 +6,42 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 角色表
|
||||
/// </summary>
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Role))]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Role))]
|
||||
public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary, IRegister
|
||||
{
|
||||
/// <summary>
|
||||
/// 角色-接口映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleApi))]
|
||||
public ICollection<Sys_Api> Apis { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 仪表板布局
|
||||
/// </summary>
|
||||
#if DBTYPE_SQLSERVER
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string DashboardLayout { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 数据范围
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DataScopes DataScope { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色-部门映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleDept))]
|
||||
public ICollection<Sys_Dept> Depts { get; init; }
|
||||
@ -37,6 +50,7 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否显示仪表板
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool DisplayDashboard { get; init; }
|
||||
|
||||
@ -44,6 +58,7 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@ -51,12 +66,14 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否忽略权限控制
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool IgnorePermissionControl { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色-菜单映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleMenu))]
|
||||
public ICollection<Sys_Menu> Menus { get; init; }
|
||||
@ -65,12 +82,14 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 角色名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 发送给此角色的站内信集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgRole))]
|
||||
public ICollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@ -79,6 +98,7 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@ -86,18 +106,20 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 此角色下的用户集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_UserRole))]
|
||||
public ICollection<Sys_User> Users { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
public virtual void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<CreateRoleReq, Sys_Role>()
|
||||
.Map( //
|
||||
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
@ -11,6 +9,7 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的接口
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Api Api { get; init; }
|
||||
|
||||
@ -18,12 +17,14 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// 接口编号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public string ApiId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@ -31,6 +32,7 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
}
|
@ -1,17 +1,17 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 角色-部门映射表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(DeptId)}", $"{nameof(RoleId)},{nameof(DeptId)}", true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(DeptId)}", $"{nameof(RoleId)},{nameof(DeptId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_RoleDept))]
|
||||
public record Sys_RoleDept : ImmutableEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 关联的部门
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
|
||||
@ -19,12 +19,14 @@ public record Sys_RoleDept : ImmutableEntity
|
||||
/// 可访问的部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long DeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@ -32,6 +34,7 @@ public record Sys_RoleDept : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
}
|
@ -1,17 +1,17 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 角色-菜单映射表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(MenuId)}", $"{nameof(RoleId)},{nameof(MenuId)}", true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(MenuId)}", $"{nameof(RoleId)},{nameof(MenuId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_RoleMenu))]
|
||||
public record Sys_RoleMenu : ImmutableEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 关联的菜单
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Menu Menu { get; init; }
|
||||
|
||||
@ -19,12 +19,14 @@ public record Sys_RoleMenu : ImmutableEntity
|
||||
/// 菜单编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long MenuId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@ -32,6 +34,7 @@ public record Sys_RoleMenu : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long RoleId { get; init; }
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
using NetAdmin.Domain.Dto.Sys.SiteMsg;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
@ -19,12 +17,14 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Content { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-创建者映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(CreatedUserId))]
|
||||
public Sys_User Creator { get; init; }
|
||||
@ -32,6 +32,7 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息-部门映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgDept))]
|
||||
public ICollection<Sys_Dept> Depts { get; init; }
|
||||
@ -39,6 +40,7 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息-标记映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Sys_SiteMsgFlag.SiteMsgId))]
|
||||
public ICollection<Sys_SiteMsgFlag> Flags { get; init; }
|
||||
@ -46,12 +48,14 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息类型
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual SiteMsgTypes MsgType { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-角色映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgRole))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@ -60,6 +64,7 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// 消息摘要
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
|
||||
@ -67,12 +72,14 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// 消息主题
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Title { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-用户映射
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgUser))]
|
||||
public ICollection<Sys_User> Users { get; init; }
|
||||
|
@ -1,18 +1,17 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 站内信-部门映射表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(DeptId)}_{nameof(SiteMsgId)}", $"{nameof(DeptId)},{nameof(SiteMsgId)}"
|
||||
, true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(DeptId)}_{nameof(SiteMsgId)}", $"{nameof(DeptId)},{nameof(SiteMsgId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_SiteMsgDept))]
|
||||
public record Sys_SiteMsgDept : ImmutableEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 关联的部门
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
|
||||
@ -20,12 +19,14 @@ public record Sys_SiteMsgDept : ImmutableEntity
|
||||
/// 部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long DeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@ -33,6 +34,7 @@ public record Sys_SiteMsgDept : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
}
|
@ -1,4 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -6,8 +5,8 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 站内信标记表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(SiteMsgId)}_{nameof(UserId)}", $"{nameof(SiteMsgId)},{nameof(UserId)}"
|
||||
, true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(SiteMsgId)}_{nameof(UserId)}", $"{nameof(SiteMsgId)},{nameof(UserId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_SiteMsgFlag))]
|
||||
public record Sys_SiteMsgFlag : MutableEntity
|
||||
{
|
||||
@ -15,6 +14,7 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long SiteMsgId { get; init; }
|
||||
|
||||
@ -22,6 +22,7 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
|
||||
@ -29,6 +30,7 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 用户站内信状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual UserSiteMsgStatues UserSiteMsgStatus { get; init; }
|
||||
}
|
@ -1,18 +1,17 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 站内信-角色映射表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(SiteMsgId)}", $"{nameof(RoleId)},{nameof(SiteMsgId)}"
|
||||
, true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(RoleId)}_{nameof(SiteMsgId)}", $"{nameof(RoleId)},{nameof(SiteMsgId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_SiteMsgRole))]
|
||||
public record Sys_SiteMsgRole : ImmutableEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@ -20,12 +19,14 @@ public record Sys_SiteMsgRole : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@ -33,6 +34,7 @@ public record Sys_SiteMsgRole : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
}
|
@ -1,18 +1,17 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 站内信-用户映射表
|
||||
/// </summary>
|
||||
[Index($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(UserId)}_{nameof(SiteMsgId)}", $"{nameof(UserId)},{nameof(SiteMsgId)}"
|
||||
, true)]
|
||||
[FreeSql.DataAnnotations.Index( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(UserId)}_{nameof(SiteMsgId)}", $"{nameof(UserId)},{nameof(SiteMsgId)}", true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_SiteMsgUser))]
|
||||
public record Sys_SiteMsgUser : ImmutableEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@ -20,12 +19,14 @@ public record Sys_SiteMsgUser : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的用户
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
@ -33,6 +34,7 @@ public record Sys_SiteMsgUser : ImmutableEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
using NetAdmin.Domain.Dto.Sys.User;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -7,22 +5,24 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 用户基本信息表
|
||||
/// </summary>
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Email), nameof(Email), true)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Mobile), nameof(Mobile), true)]
|
||||
[Index(Chars.FLG_DB_INDEX_PREFIX + nameof(UserName), nameof(UserName), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_User))]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Email), nameof(Email), true)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(Mobile), nameof(Mobile), true)]
|
||||
[FreeSql.DataAnnotations.Index(Chars.FLG_DB_INDEX_PREFIX + nameof(UserName), nameof(UserName), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_User))]
|
||||
public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
{
|
||||
/// <summary>
|
||||
/// 头像链接
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Avatar { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属部门
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(DeptId))]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
@ -31,6 +31,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long DeptId { get; init; }
|
||||
|
||||
@ -38,6 +39,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 邮箱
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Email { get; init; }
|
||||
|
||||
@ -45,6 +47,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@ -52,6 +55,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 手机号码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Mobile { get; init; }
|
||||
|
||||
@ -59,18 +63,21 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 密码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Guid Password { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户档案
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_UserProfile Profile { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_UserRole))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@ -78,6 +85,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// <summary>
|
||||
/// 发送给此用户的站内信集合
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgUser))]
|
||||
public ICollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@ -86,6 +94,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 描述
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; init; }
|
||||
|
||||
@ -93,6 +102,7 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 授权验证Token,全局唯一,可以随时重置(强制下线)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Guid Token { get; init; }
|
||||
|
||||
@ -100,11 +110,12 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string UserName { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
public virtual void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<CreateUserReq, Sys_User>()
|
||||
.Map(d => d.Password, s => s.PasswordText.Pwd().Guid())
|
||||
|
@ -1,4 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.Dto.Sys.UserProfile;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -17,13 +16,15 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
#else
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
#endif
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string AppConfig { get; init; }
|
||||
public virtual string AppConfig { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 出生日期
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? BornDate { get; init; }
|
||||
|
||||
@ -31,6 +32,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 证件号码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CertificateNumber { get; init; }
|
||||
|
||||
@ -38,6 +40,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 证件类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual CertificateTypes? CertificateType { get; init; }
|
||||
|
||||
@ -45,6 +48,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyAddress { get; init; }
|
||||
|
||||
@ -52,6 +56,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int? CompanyArea { get; init; }
|
||||
|
||||
@ -59,6 +64,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作单位
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyName { get; init; }
|
||||
|
||||
@ -66,6 +72,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作电话
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyTelephone { get; init; }
|
||||
|
||||
@ -73,6 +80,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 文化程度
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual Educations? Education { get; init; }
|
||||
|
||||
@ -80,6 +88,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactAddress { get; init; }
|
||||
|
||||
@ -87,13 +96,15 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int? EmergencyContactArea { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 紧急联系人手机号码
|
||||
/// 紧急联系人手机号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactMobile { get; init; }
|
||||
|
||||
@ -101,6 +112,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系人
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactName { get; init; }
|
||||
|
||||
@ -108,6 +120,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 毕业学校
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string GraduateSchool { get; init; }
|
||||
|
||||
@ -115,6 +128,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 身高
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual int? Height { get; init; }
|
||||
|
||||
@ -122,6 +136,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string HomeAddress { get; init; }
|
||||
|
||||
@ -129,6 +144,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int? HomeArea { get; init; }
|
||||
|
||||
@ -136,6 +152,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅电话
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string HomeTelephone { get; init; }
|
||||
|
||||
@ -143,6 +160,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 婚姻状况
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual MarriageStatues? MarriageStatus { get; init; }
|
||||
|
||||
@ -151,6 +169,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// </summary>
|
||||
/// 7
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual Nations? Nation { get; init; }
|
||||
|
||||
@ -158,6 +177,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 籍贯
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public int? NationArea { get; init; }
|
||||
|
||||
@ -165,6 +185,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 政治面貌
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual PoliticalStatues? PoliticalStatus { get; init; }
|
||||
|
||||
@ -172,6 +193,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 职业
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Profession { get; init; }
|
||||
|
||||
@ -179,6 +201,7 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 真实姓名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string RealName { get; init; }
|
||||
|
||||
@ -186,12 +209,14 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 性别
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual Sexes? Sex { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户基本信息
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
|
@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
@ -11,6 +9,7 @@ public record Sys_UserRole : VersionEntity
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@ -18,12 +17,14 @@ public record Sys_UserRole : VersionEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的用户
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
@ -31,6 +32,7 @@ public record Sys_UserRole : VersionEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
}
|
@ -1,4 +1,3 @@
|
||||
using NetAdmin.Domain.DbMaps.Dependency;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
@ -13,6 +12,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_7)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string Code { get; init; }
|
||||
|
||||
@ -20,6 +20,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 目标设备
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string DestDevice { get; init; }
|
||||
|
||||
@ -27,6 +28,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 设备类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeDeviceTypes DeviceType { get; init; }
|
||||
|
||||
@ -34,6 +36,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 发送报告
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public string Report { get; init; }
|
||||
|
||||
@ -41,6 +44,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeStatues Status { get; init; }
|
||||
|
||||
@ -48,6 +52,7 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeTypes Type { get; init; }
|
||||
}
|
Reference in New Issue
Block a user