using System; using System.Collections.Generic; using System.Linq; using System.Text.Json.Serialization; using SqlSugar; namespace Yi.Framework.Model.Models { /// /// 评论表 /// [SugarTable("Comment")] public partial class CommentEntity:IBaseModelEntity { public CommentEntity() { this.CreateTime = DateTime.Now; this.AgreeNum= 0; this.CommentNum = 0; this.ParentId= 0; } [JsonConverter(typeof(ValueToStringConverter))] [SugarColumn(ColumnName="Id" ,IsPrimaryKey = true )] public long Id { get; set; } /// /// 文章id /// [SugarColumn(ColumnName="ArticleId" )] public long? ArticleId { get; set; } /// /// 被回复用户id /// [SugarColumn(ColumnName="UserId" )] public long? UserId { get; set; } /// /// 评论内容 /// [SugarColumn(ColumnName="Content" )] public string? Content { get; set; } /// /// 点赞数 /// [SugarColumn(ColumnName="AgreeNum" )] public int? AgreeNum { get; set; } /// /// 创建者 /// [SugarColumn(ColumnName="CreateUser" )] public long? CreateUser { get; set; } /// /// 创建时间 /// [SugarColumn(ColumnName="CreateTime" )] public DateTime? CreateTime { get; set; } /// /// 修改者 /// [SugarColumn(ColumnName="ModifyUser" )] public long? ModifyUser { get; set; } /// /// 修改时间 /// [SugarColumn(ColumnName="ModifyTime" )] public DateTime? ModifyTime { get; set; } /// /// 是否删除 /// [SugarColumn(ColumnName="IsDeleted" )] public bool? IsDeleted { get; set; } /// /// 租户Id /// [SugarColumn(ColumnName="TenantId" )] public long? TenantId { get; set; } /// /// 排序字段 /// [SugarColumn(ColumnName="OrderNum" )] public int? OrderNum { get; set; } /// /// 描述 /// [SugarColumn(ColumnName="Remark" )] public string? Remark { get; set; } /// /// 子评论数 /// [SugarColumn(ColumnName="CommentNum" )] public int? CommentNum { get; set; } /// /// 父级评论id /// [SugarColumn(ColumnName="ParentId" )] public long? ParentId { get; set; } } }