using SqlSugar; using Volo.Abp.Auditing; using Volo.Abp.Data; using Volo.Abp.Domain.Entities; namespace NPin.Framework.Upms.Domain.Authorization; [SugarTable("Social", "第三方授权表")] public class SocialAggregateRoot: AggregateRoot, ISoftDelete, IHasCreationTime { [SugarColumn(IsPrimaryKey = true)] public override Guid Id { get; protected set; } public Guid UserId { get; set; } public string OpenId { get; set; } public string? UnionId { get; set; } public string Name { get; set; } public string Type { get; set; } public bool IsDeleted { get; } public DateTime CreationTime { get; } [SugarColumn(IsIgnore = true)] public override ExtraPropertyDictionary ExtraProperties { get; protected set; } public SocialAggregateRoot() { } public SocialAggregateRoot(string type, Guid userId, string openId, string? unionId) { UserId = userId; OpenId = openId; UnionId = unionId; Type = type; } public SocialAggregateRoot(string type, Guid userId, string openId, string? unionId, string name): this(type, userId, openId, unionId) { Name = name; } }