27 lines
634 B
C#
27 lines
634 B
C#
namespace YLErp.Web.Models
|
|
{
|
|
/// <summary>
|
|
/// 用于ztree控件的数据模型
|
|
/// </summary>
|
|
public class ZTreeModel
|
|
{
|
|
public string name { get; set; }
|
|
|
|
public bool open { get; set; }
|
|
|
|
public List<ZTreeModel> children { get; set; }
|
|
|
|
public void AppenChild(ZTreeModel model)
|
|
{
|
|
if (model == null)
|
|
{
|
|
throw new System.ArgumentNullException(nameof(model));
|
|
}
|
|
if (children == null)
|
|
{
|
|
children = new List<ZTreeModel>();
|
|
}
|
|
children.Add(model);
|
|
}
|
|
}
|
|
} |