public async Task <IActionResult> UpdateConcert([FromBody] ConcertPayload payload) { var concert = await SingleOrError(_concertsRepo.FindOne(EntityId)); await _concertsRepo.Update(concert, payload); return(Ok()); }
public async Task <IActionResult> SetAttendance([FromRoute] int concertId, [FromBody] bool attending) { var concert = await SingleOrError(_concertsRepo .FindOne(new ConcertIdentifier(GroupId, concertId)) .Include(_ => _.Attendances.Where(a => a.UserId == RequestingUserId))); await _concertsRepo.SetUserAttendance(concert, RequestingUserId, attending); return(Ok()); }