public ActionResult CreateTournament() { RegisterTournamentModel model = new RegisterTournamentModel(); model.StartDate = DateTime.UtcNow; model.EndDate = DateTime.UtcNow; return View(model); }
public ActionResult CreateTournament(RegisterTournamentModel model) { var tourny = Tournament.CreateTournament(model.TournamentName, model.StartDate, model.EndDate, model.Passcode, RDN.Library.Classes.Account.User.GetMemberId()); return Redirect(Url.Content("~/tournament/view/" + tourny.PrivateKey.ToString().Replace("-", "") + "/" + tourny.Id.ToString().Replace("-", ""))); }