Browse Source

Add IHasCreationTime to IdentityClaimType and IdentityRole entities

pull/21736/head
liangshiwei 2 years ago
parent
commit
ff17ccec26
  1. 5
      modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityClaimType.cs
  2. 4
      modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityRole.cs

5
modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityClaimType.cs

@ -1,10 +1,11 @@
using JetBrains.Annotations; using JetBrains.Annotations;
using System; using System;
using Volo.Abp.Auditing;
using Volo.Abp.Domain.Entities; using Volo.Abp.Domain.Entities;
namespace Volo.Abp.Identity; namespace Volo.Abp.Identity;
public class IdentityClaimType : AggregateRoot<Guid> public class IdentityClaimType : AggregateRoot<Guid>, IHasCreationTime
{ {
public virtual string Name { get; protected set; } public virtual string Name { get; protected set; }
@ -19,6 +20,8 @@ public class IdentityClaimType : AggregateRoot<Guid>
public virtual string Description { get; set; } public virtual string Description { get; set; }
public virtual IdentityClaimValueType ValueType { get; set; } public virtual IdentityClaimValueType ValueType { get; set; }
public virtual DateTime CreationTime { get; protected set; }
protected IdentityClaimType() protected IdentityClaimType()
{ {

4
modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityRole.cs

@ -14,7 +14,7 @@ namespace Volo.Abp.Identity;
/// <summary> /// <summary>
/// Represents a role in the identity system /// Represents a role in the identity system
/// </summary> /// </summary>
public class IdentityRole : AggregateRoot<Guid>, IMultiTenant, IHasEntityVersion public class IdentityRole : AggregateRoot<Guid>, IMultiTenant, IHasEntityVersion, IHasCreationTime
{ {
public virtual Guid? TenantId { get; protected set; } public virtual Guid? TenantId { get; protected set; }
@ -53,6 +53,8 @@ public class IdentityRole : AggregateRoot<Guid>, IMultiTenant, IHasEntityVersion
/// A version value that is increased whenever the entity is changed. /// A version value that is increased whenever the entity is changed.
/// </summary> /// </summary>
public virtual int EntityVersion { get; protected set; } public virtual int EntityVersion { get; protected set; }
public virtual DateTime CreationTime { get; protected set; }
/// <summary> /// <summary>
/// Initializes a new instance of <see cref="IdentityRole"/>. /// Initializes a new instance of <see cref="IdentityRole"/>.

Loading…
Cancel
Save