public virtual IActionResult ApiCapabilitiesByFrameworkByFrameworkIdGet([FromRoute][Required] string frameworkId, [FromQuery] int?pageIndex, [FromQuery] int?pageSize) { IEnumerable <Capability> capabilities; int totalPages; try { capabilities = _datastore.ByFramework(frameworkId); capabilities = _datastore.GetPagingValues(pageIndex, pageSize, capabilities, out totalPages); if (capabilities == null) { return(StatusCode(404)); } } catch (Crm.CrmApiException ex) { return(StatusCode((int)ex.HttpStatus, ex.Message)); } return(new ObjectResult(new PaginatedListCapabilities() { Items = capabilities.ToList(), PageSize = pageSize ?? Paging.DefaultPageSize, TotalPages = totalPages, PageIndex = pageIndex ?? Paging.DefaultIndex })); }
public IQueryable <Capability> ByFramework(string frameworkId) { return(_datastore.ByFramework(frameworkId)); }