コード例 #1
0
ファイル: HierarchyController.cs プロジェクト: mdjukic/repos
        public async Task <VmPage <VmHierarchy> > GetChildren(int id)
        {
            var result = await _hierarchyService.GetChildren(id);

            return(new VmPage <VmHierarchy>
            {
                Items = VmHierarchy.Build(result),
                PageIndex = 1,
                PageSize = 1,
                TotalCount = result.Count
            });
        }
コード例 #2
0
ファイル: HierarchyController.cs プロジェクト: mdjukic/repos
        public async Task <VmPage <VmHierarchy> > GetHierarchy(int?depth = null)
        {
            var result = await _hierarchyService.GetAll(depth);

            return(new VmPage <VmHierarchy>
            {
                Items = VmHierarchy.Build(result),
                PageIndex = 1,
                PageSize = 1,
                TotalCount = result.Count
            });
        }