public ActionResult DeleteConfirmed(int id) { vw_OrgPerson vw_OrgPerson = db.vw_OrgPerson.Find(id); db.vw_OrgPerson.Remove(vw_OrgPerson); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "PersonID,FirstName,LastName,Email,OrgTypeAssignmentID,OrgPersonID,OrganizationName,OrganizationType")] vw_OrgPerson vw_OrgPerson) { if (ModelState.IsValid) { db.Entry(vw_OrgPerson).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(vw_OrgPerson)); }
public ActionResult Create([Bind(Include = "PersonID,FirstName,LastName,Email,OrgTypeAssignmentID,OrgPersonID,OrganizationName,OrganizationType")] vw_OrgPerson vw_OrgPerson) { if (ModelState.IsValid) { db.vw_OrgPerson.Add(vw_OrgPerson); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(vw_OrgPerson)); }
// GET: vw_OrgPerson/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } vw_OrgPerson vw_OrgPerson = db.vw_OrgPerson.Find(id); if (vw_OrgPerson == null) { return(HttpNotFound()); } return(View(vw_OrgPerson)); }