mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-09-18 09:44:28 +08:00
完成用户/角色分配资源
This commit is contained in:
@@ -21,8 +21,7 @@ namespace OpenAuth.Repository.Domain
|
||||
public Application()
|
||||
{
|
||||
this.Name= string.Empty;
|
||||
this.AppId= string.Empty;
|
||||
this.AppKey= string.Empty;
|
||||
this.AppSecret= string.Empty;
|
||||
this.Description= string.Empty;
|
||||
this.Icon= string.Empty;
|
||||
this.CreateTime= DateTime.Now;
|
||||
@@ -30,17 +29,13 @@ namespace OpenAuth.Repository.Domain
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 名称
|
||||
/// 应用名称
|
||||
/// </summary>
|
||||
public string Name { get; set; }
|
||||
/// <summary>
|
||||
/// 应用ID
|
||||
/// </summary>
|
||||
public string AppId { get; set; }
|
||||
/// <summary>
|
||||
/// 应用密钥
|
||||
/// </summary>
|
||||
public string AppKey { get; set; }
|
||||
public string AppSecret { get; set; }
|
||||
/// <summary>
|
||||
/// 应用描述
|
||||
/// </summary>
|
||||
@@ -56,7 +51,7 @@ namespace OpenAuth.Repository.Domain
|
||||
/// <summary>
|
||||
/// 创建日期
|
||||
/// </summary>
|
||||
public System.DateTime? CreateTime { get; set; }
|
||||
public System.DateTime CreateTime { get; set; }
|
||||
/// <summary>
|
||||
/// 创建人
|
||||
/// </summary>
|
||||
|
@@ -21,13 +21,13 @@ namespace OpenAuth.Repository.Domain
|
||||
public Resource()
|
||||
{
|
||||
this.CascadeId= string.Empty;
|
||||
this.Key= string.Empty;
|
||||
this.Name= string.Empty;
|
||||
this.Status= 0;
|
||||
this.SortNo= 0;
|
||||
this.Description= string.Empty;
|
||||
this.ParentName= string.Empty;
|
||||
this.ParentId= string.Empty;
|
||||
this.AppId= string.Empty;
|
||||
this.AppName= string.Empty;
|
||||
this.TypeName= string.Empty;
|
||||
this.TypeId= string.Empty;
|
||||
}
|
||||
@@ -36,18 +36,10 @@ namespace OpenAuth.Repository.Domain
|
||||
/// 节点语义ID
|
||||
/// </summary>
|
||||
public string CascadeId { get; set; }
|
||||
/// <summary>
|
||||
/// 资源英文唯一标识
|
||||
/// </summary>
|
||||
public string Key { get; set; }
|
||||
/// <summary>
|
||||
/// 名称
|
||||
/// </summary>
|
||||
public string Name { get; set; }
|
||||
/// <summary>
|
||||
/// 当前状态
|
||||
/// </summary>
|
||||
public int Status { get; set; }
|
||||
/// <summary>
|
||||
/// 排序号
|
||||
/// </summary>
|
||||
@@ -57,13 +49,21 @@ namespace OpenAuth.Repository.Domain
|
||||
/// </summary>
|
||||
public string Description { get; set; }
|
||||
/// <summary>
|
||||
/// 父节点流水号
|
||||
/// 父节点名称
|
||||
/// </summary>
|
||||
public string ParentName { get; set; }
|
||||
/// <summary>
|
||||
/// 父节点流ID
|
||||
/// </summary>
|
||||
public string ParentId { get; set; }
|
||||
/// <summary>
|
||||
/// 资源所属应用
|
||||
/// 资源所属应用ID
|
||||
/// </summary>
|
||||
public string AppId { get; set; }
|
||||
/// <summary>
|
||||
/// 所属应用名称
|
||||
/// </summary>
|
||||
public string AppName { get; set; }
|
||||
/// <summary>
|
||||
/// 分类名称
|
||||
/// </summary>
|
||||
@@ -72,6 +72,10 @@ namespace OpenAuth.Repository.Domain
|
||||
/// 分类ID
|
||||
/// </summary>
|
||||
public string TypeId { get; set; }
|
||||
/// <summary>
|
||||
/// 是否可用
|
||||
/// </summary>
|
||||
public bool Disable { get; set; }
|
||||
|
||||
}
|
||||
}
|
@@ -32,12 +32,8 @@ namespace OpenAuth.Repository.Mapping
|
||||
.HasColumnName("Name")
|
||||
.HasMaxLength(255)
|
||||
.IsRequired();
|
||||
Property(t => t.AppId)
|
||||
.HasColumnName("AppId")
|
||||
.HasMaxLength(255)
|
||||
.IsOptional();
|
||||
Property(t => t.AppKey)
|
||||
.HasColumnName("AppKey")
|
||||
Property(t => t.AppSecret)
|
||||
.HasColumnName("AppSecret")
|
||||
.HasMaxLength(255)
|
||||
.IsOptional();
|
||||
Property(t => t.Description)
|
||||
@@ -53,7 +49,7 @@ namespace OpenAuth.Repository.Mapping
|
||||
.IsRequired();
|
||||
Property(t => t.CreateTime)
|
||||
.HasColumnName("CreateTime")
|
||||
.IsOptional();
|
||||
.IsRequired();
|
||||
Property(t => t.CreateUser)
|
||||
.HasColumnName("CreateUser")
|
||||
.HasMaxLength(50)
|
||||
|
@@ -32,17 +32,10 @@ namespace OpenAuth.Repository.Mapping
|
||||
.HasColumnName("CascadeId")
|
||||
.HasMaxLength(255)
|
||||
.IsRequired();
|
||||
Property(t => t.Key)
|
||||
.HasColumnName("Key")
|
||||
.HasMaxLength(200)
|
||||
.IsRequired();
|
||||
Property(t => t.Name)
|
||||
.HasColumnName("Name")
|
||||
.HasMaxLength(255)
|
||||
.IsRequired();
|
||||
Property(t => t.Status)
|
||||
.HasColumnName("Status")
|
||||
.IsRequired();
|
||||
Property(t => t.SortNo)
|
||||
.HasColumnName("SortNo")
|
||||
.IsRequired();
|
||||
@@ -50,6 +43,10 @@ namespace OpenAuth.Repository.Mapping
|
||||
.HasColumnName("Description")
|
||||
.HasMaxLength(500)
|
||||
.IsRequired();
|
||||
Property(t => t.ParentName)
|
||||
.HasColumnName("ParentName")
|
||||
.HasMaxLength(50)
|
||||
.IsOptional();
|
||||
Property(t => t.ParentId)
|
||||
.HasColumnName("ParentId")
|
||||
.HasMaxLength(50)
|
||||
@@ -58,6 +55,10 @@ namespace OpenAuth.Repository.Mapping
|
||||
.HasColumnName("AppId")
|
||||
.HasMaxLength(50)
|
||||
.IsOptional();
|
||||
Property(t => t.AppName)
|
||||
.HasColumnName("AppName")
|
||||
.HasMaxLength(50)
|
||||
.IsOptional();
|
||||
Property(t => t.TypeName)
|
||||
.HasColumnName("TypeName")
|
||||
.HasMaxLength(20)
|
||||
@@ -66,6 +67,9 @@ namespace OpenAuth.Repository.Mapping
|
||||
.HasColumnName("TypeId")
|
||||
.HasMaxLength(50)
|
||||
.IsOptional();
|
||||
Property(t => t.Disable)
|
||||
.HasColumnName("Disable")
|
||||
.IsRequired();
|
||||
|
||||
// Relationships
|
||||
}
|
||||
|
Reference in New Issue
Block a user