// GET: Home public ActionResult Index() { Setup.Initialize(); try { List <PersonalDataModel> listdata = PersonalDataManager.GetAll(); return(View(listdata)); } catch (Exception ex) { throw ex; } }
public ActionResult Index(PersonalDataModel model) { try { Setup.Initialize(); PersonalDataManager.Save(model); } catch { return(View()); } return(RedirectToAction("Index", "Home")); }
public ActionResult Delete(string Id) { try { if (string.IsNullOrEmpty(Id)) { PersonalDataManager.Delete(Id); } } catch (Exception ex) { throw ex; } return(RedirectToAction("Index")); }