public ActionResult <IEnumerable <string> > GetDirectoryFiles([FromBody] FilesRequest request) { TestTaskDirectory.BL.DirectoryService directoryService = new TestTaskDirectory.BL.DirectoryService(); return(directoryService.GetFilesInfo(request.Directory) .OrderedBy(request.OrderFilesBy)); }
public ActionResult <IEnumerable <GroupedFilesResult> > GetGroupedFiles([FromBody] FilesGroupingRequest request) { TestTaskDirectory.BL.DirectoryService directoryService = new TestTaskDirectory.BL.DirectoryService(); return(directoryService.GetFilesInfo(request.Directory) .GroupedBy(request.GroupFilesBy) .OrderedInGroups(request.OrderFilesBy)); }