// PUT api/Judges/5 public JudgeDto Put([FromBody] JudgeDto judge) { var updatedJudge = judge.ConvertFromDto(); JudgeService.Update(updatedJudge); return(updatedJudge.ConvertToDto()); }
public JudgeDto GetShowContests(int id, [FromBody] JudgeDto judge) { var contestId = id; var newJudge = judge.ConvertFromDto(); JudgeService.AddContestJudge(contestId, newJudge); return(newJudge.ConvertToDto()); }
// DELETE api/Judges/5 public void Delete([FromBody] JudgeDto judge) { JudgeService.Delete(judge.ConvertFromDto()); }
// POST api/Judges public void Post([FromBody] JudgeDto judge) { JudgeService.Add(judge.ConvertFromDto()); }