public IActionResult Create(ExhibitionEditViewModel model) { var exhibition = new Exhibition(); exhibition.Name = model.Name; exhibition.Description = model.Description; //exhibition.Active = model.Active; exhibition.Active = true; //set exhibition default to active, update in the future if requirments change exhibition = _repo.AddExhibition(exhibition); return(View("Details", exhibition.ToViewModel())); }
public IActionResult Create(ExhibitionEditViewModel model) { var exhibition = new Exhibition(); exhibition.Name = model.Name; exhibition.Description = model.Description; exhibition.WebUrl = model.WebUrl; exhibition.Active = model.Active; exhibition = _repo.AddExhibition(exhibition); return(View("Details", exhibition.ToViewModel())); }