mirror of
https://github.com/nsnail/NetAdmin.git
synced 2025-09-17 02:55:34 +08:00
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -21,11 +18,13 @@ public abstract record ImmutableEntity<T> : LiteImmutableEntity<T>, IFieldCreate
|
||||
{
|
||||
/// <inheritdoc cref="IFieldCreatedUser.CreatedUserId" />
|
||||
[Column(CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long? CreatedUserId { get; init; }
|
||||
|
||||
/// <inheritdoc cref="IFieldCreatedUser.CreatedUserName" />
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserName { get; init; }
|
||||
|
||||
|
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -21,11 +18,13 @@ public abstract record LiteImmutableEntity<T> : EntityBase<T>, IFieldCreatedTime
|
||||
{
|
||||
/// <inheritdoc cref="IFieldCreatedTime.CreatedTime" />
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc cref="EntityBase{T}.Id" />
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public override T Id { get; init; }
|
||||
}
|
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -24,6 +21,7 @@ public abstract record LiteMutableEntity<T> : LiteImmutableEntity<T>, IFieldModi
|
||||
|
||||
/// <inheritdoc cref="IFieldModifiedTime.ModifiedTime" />
|
||||
[Column(ServerTime = DateTimeKind.Local, CanInsert = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? ModifiedTime { get; init; }
|
||||
}
|
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -24,6 +21,7 @@ public abstract record LiteVersionEntity<T> : LiteMutableEntity<T>, IFieldVersio
|
||||
|
||||
/// <inheritdoc cref="IFieldVersion.Version" />
|
||||
[Column(IsVersion = true, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long Version { get; init; }
|
||||
}
|
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -24,11 +21,13 @@ public abstract record MutableEntity<T> : LiteMutableEntity<T>, IFieldModifiedUs
|
||||
|
||||
/// <inheritdoc cref="IFieldModifiedUser.ModifiedUserId" />
|
||||
[Column(CanInsert = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public long? ModifiedUserId { get; init; }
|
||||
|
||||
/// <inheritdoc cref="IFieldModifiedUser.ModifiedUserName" />
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanInsert = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public string ModifiedUserName { get; init; }
|
||||
}
|
@@ -1,5 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
|
@@ -1,6 +1,3 @@
|
||||
using NetAdmin.Domain.Attributes;
|
||||
using NetAdmin.Domain.DbMaps.Dependency.Fields;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Dependency;
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -20,11 +17,13 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[Column(CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long? CreatedUserId { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanUpdate = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserName { get; init; }
|
||||
|
||||
@@ -34,11 +33,13 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
|
||||
/// <inheritdoc cref="IFieldModifiedUser.ModifiedUserId" />
|
||||
[Column(CanInsert = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual long? ModifiedUserId { get; init; }
|
||||
|
||||
/// <inheritdoc cref="IFieldModifiedUser.ModifiedUserName" />
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanInsert = false, Position = -1)]
|
||||
[Ignore]
|
||||
[JsonIgnore]
|
||||
public virtual string ModifiedUserName { get; init; }
|
||||
}
|
Reference in New Issue
Block a user