DeptServiceGetSelfAndChildrenRecursive Method

获取指定父部门的所有子部门(递归查询,结果包含父部门)。

Definition

Namespace: QuickAdmin.Service.Admin
Assembly: QuickAdmin.Net (in QuickAdmin.Net.dll) Version: 2.0.10
C#
public virtual IList<SysDept> GetSelfAndChildrenRecursive(
	long parentId,
	int? maxLevel = null
)

Parameters

parentId  long
父部门 Id 值。
maxLevel  int?  (Optional)
指示最大返回从 parentId 开始的第几层数据。从 1 开始,即 parentId 为第一层, 传入小于 1 的数值与传入 null 的效果一样,不会限制返回层级。

Return Value

IListSysDept
包含父部门及其所有递归子纪录的列表。若未找到返回一个 Count 为 0 的列表。

Implements

IDeptServiceGetSelfAndChildrenRecursive(long, int?)

Remarks

maxLevel 从 1 开始,即 parentId 为第一层。

See Also