public ActionResult Edit(int id, Limcounterpartytype model) { try { InitRepos(true, false); model.Subjecttypes = subjtypesRepo.GetById(model.SubjecttypeId); limRepo.Update(model); return(RedirectToAction("Index")); } catch { return(View()); } }
public ActionResult Create(Limcounterpartytype model) { try { // TODO: Add insert logic here InitRepos(true, false); model.Subjecttypes = subjtypesRepo.GetById(model.SubjecttypeId); limRepo.Create(model); return(RedirectToAction("Index")); } catch { return(View()); } }