public IHttpActionResult UpsertAthleteSizes(List <AthleteSizeUpsert> athleteSizes, string sportId, string athleteId) { try { AthleteSizesService.UpsertAthleteSizes(athleteSizes, sportId, athleteId); return(StatusCode(HttpStatusCode.NoContent)); } catch (Exception ex) { throw ex; } }
public DataTable GetTeamSizes(string sportId) { try { var sportItems = SportsItemService.GetSportItemsBySport(sportId); var teamSizes = AthleteSizesService.GetTeamSizes(sportId); DataTable table = AthleteSizesService.MapTeamSizes(sportItems, teamSizes); return(table); } catch (Exception ex) { throw ex; } }
public IHttpActionResult GetAthleteSizeById(string sportId, string athleteId) { try { var sizes = AthleteSizesService.GetAthleteSizeById(sportId, athleteId); if (sizes == null) { return(NotFound()); } return(Ok(sizes)); } catch (Exception ex) { throw return(ex); } }
public IQueryable <AthleteSizeCountVm> GetTeamSizeCounts(string sportId) { try { var counts = AthleteSizesService.GetTeamSizeCounts(sportId); if (counts == null) { return(NotFound()); } return(Ok(counts)); } catch (Exception ex) { throw ex; } }