sunpengfei
2025-08-14 e1dd123ce54dfd2bb770ba017917be2e1a78b1b8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
 
namespace FlexJobApi.Core
{
    /// <summary>
    /// 树形数据
    /// </summary>
    /// <typeparam name="TEntity"></typeparam>
    public interface ITreeData<TEntity>
        where TEntity : CommonEntity, ITreeData<TEntity>, new()
    {
        /// <summary>
        /// 上级Id
        /// </summary>
        Guid? ParentId { get; set; }
 
        /// <summary>
        /// 上级
        /// </summary>
        TEntity Parent { get; set; }
 
        /// <summary>
        /// 下级
        /// </summary>
        List<TEntity> Children { get; set; }
 
        /// <summary>
        /// 字典路径
        /// </summary>
        string Path { get; set; }
 
        /// <summary>
        /// 编号
        /// </summary>
        string Code { get; set; }
    }
}