public virtual ActionResult Edit(string id, ThemeEditModel t) { var x = Themes.Get(id); if (!ModelState.IsValid) { return(View(t)); } try { t.Apply(x); Themes.Save(x); Notifier.Notify(Severity.Success, "Theme saved.", "You may continue editing this theme.", null); return(Redirect(Request.RawUrl)); } catch (Exception ex) { Notifier.Notify(ex); return(View(x)); } }
public virtual ActionResult Edit(string id) { return(View(ThemeEditModel.FromDomain(Themes.Get(id)))); }