新增文档分类列表树

This commit is contained in:
hogan
2019-01-25 16:49:09 +08:00
parent a9afd0d23d
commit 96c2a66131
25 changed files with 875 additions and 515 deletions

View File

@ -0,0 +1,22 @@
//using FreeSql.DataAnnotations;
using FreeSql.DataAnnotations;
using System;
namespace FreeSql.Site.Entity
{
public class BaseEntity
{
[Column(IsIdentity = true, IsPrimary = true)]
public int ID { get; set; }
/// <summary>
/// 状态
/// </summary>
public int Status { get; set; }
public DateTime? CreateDt { get; set; }
public string CreateBy { get; set; }
}
}

View File

@ -0,0 +1,16 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace FreeSql.Site.Entity.Common
{
public class TreeNode
{
public string id { get; set; }
public string pid { get; set; }
public string title { get; set; }
}
}

View File

@ -4,11 +4,8 @@ using System;
namespace FreeSql.Site.Entity
{
public class DocumentComment
public class DocumentComment:BaseEntity
{
[Column(IsIdentity = true, IsPrimary = true)]
public int ID { get; set; }
/// <summary>
/// 功能类型(文章、模板、示例等)
/// </summary>
@ -43,16 +40,5 @@ namespace FreeSql.Site.Entity
/// 评论内容
/// </summary>
public string CommentContent { get; set; }
/// <summary>
/// 创建时间
/// </summary>
public DateTime? CreateDt { get; set; }
/// <summary>
/// 创建人
/// </summary>
public string CreateBy { get; set; }
}
}

View File

@ -7,11 +7,8 @@ namespace FreeSql.Site.Entity
/// <summary>
/// 数据库实体
/// </summary>
public class DocumentContent
public class DocumentContent : BaseEntity
{
[Column(IsIdentity = true, IsPrimary = true)]
public int ID { get; set; }
/// <summary>
/// 类型编号
/// </summary>
@ -33,11 +30,6 @@ namespace FreeSql.Site.Entity
[Column(DbType = "text")]
public string DocContent { get; set; }
/// <summary>
/// 状态
/// </summary>
public int Status { get; set; }
/// <summary>
/// 查看次数
/// </summary>
@ -48,15 +40,6 @@ namespace FreeSql.Site.Entity
/// </summary>
public int StarCount { get; set; }
/// <summary>
/// 创建时间
/// </summary>
public DateTime? CreateDt { get; set; }
/// <summary>
/// 创建人
/// </summary>
public string CreateBy { get; set; }
/// <summary>
/// 修改时间

View File

@ -1,16 +1,20 @@
//using FreeSql.DataAnnotations;
using FreeSql.DataAnnotations;
using FreeSql.Site.Entity.Common;
using System;
namespace FreeSql.Site.Entity
{
public class DocumentType
public class DocumentType : BaseEntity
{
[Column(IsIdentity = true, IsPrimary = true)]
public int ID { get; set; }
/// <summary>
/// 类型名称
/// </summary>
public string TypeName { get; set; }
/// <summary>
/// 上级类型名称
/// </summary>
public int? UpID { get; set; }
/// <summary>
@ -18,17 +22,24 @@ namespace FreeSql.Site.Entity
/// </summary>
public string Tag { get; set; }
/// <summary>
/// 状态
/// </summary>
public int Status { get; set; }
public DateTime? CreateDt { get; set; }
public string CreateBy { get; set; }
public DateTime? UpdateDt { get; set; }
public string UpdateBy { get; set; }
}
/// <summary>
/// 类型树形结构
/// </summary>
public class DocumentTypeTreeNode : TreeNode
{
/// <summary>
/// 标签
/// </summary>
public string tag { get; set; }
/// <summary>
/// 创建时间
/// </summary>
public DateTime? createdt { get; set; }
}
}

View File

@ -8,10 +8,8 @@ namespace FreeSql.Site.Entity
/// <summary>
/// 模板示例
/// </summary>
public class TemplateExample
public class TemplateExample : BaseEntity
{
[Column(IsIdentity = true, IsPrimary = true)]
public int ID { get; set; }
/// <summary>
/// 模板图片
@ -49,16 +47,13 @@ namespace FreeSql.Site.Entity
public int StarCount { get; set; }
/// <summary>
/// 状态
/// 修改时间
/// </summary>
public int Status { get; set; }
public DateTime? CreateDt { get; set; }
public string CreateBy { get; set; }
public DateTime? UpdateDt { get; set; }
/// <summary>
/// 修改人
/// </summary>
public string UpdateBy { get; set; }
}
}