public ActionResult Roll(Guid id) { RollManagement rollManagement = new RollManagement(); var roll = rollManagement.get(id); if (roll == null) { return(new HttpNotFoundResult()); } return(View(roll)); }
public ActionResult RollMore(Guid id) { RollManagement rollManagement = new RollManagement(); var roll = rollManagement.get(id); if (roll == null) { return(new HttpNotFoundResult()); } int newResult = new Random().Next(roll.RollRangeBoundaryBottom, roll.RollRangeBoundaryTop + 1); roll.Result.Add(newResult); return(Redirect("~/Home/Roll/" + id.ToString())); }