public async Task <IHttpActionResult> GetCompetitors(int competitionId)
 {
     using (var competitorService = new CompetitorService())
     {
         var competitorColumns = ColumnDefinitionFactory.ExtractColumnDefinitions(typeof(CompetitionInfo));
         var competitors       = competitorService.GetCompetitors(competitionId);
         return(Ok(new CompetitiorInfoDTO()
         {
             Columns = competitorColumns,
             Competitors = competitors
         }));
     }
 }
Exemple #2
0
 public List <ColumnDefinition> GetPlayerViewModelColumns()
 {
     return(ColumnDefinitionFactory.ExtractColumnDefinitions(typeof(TableTennisTournamentPlayerVM)));
 }