// GET: Administrators public ActionResult Index() { AppWebHelper hlp = new AppWebHelper(HttpContext.Request.QueryString[Constants.SPAppWebUrl] as string); List<Administrator> model = hlp.GetAdministrators(); return View(model); }
public ActionResult Delete(int id, FormCollection collection) { try { AppWebHelper hlp = new AppWebHelper( HttpContext.Request.QueryString[Constants.SPAppWebUrl] as string); hlp.DeleteAdministrator(id); return View("Index", hlp.GetAdministrators()); } catch (Exception ex) { LogHelper.Log(ex.Message + ex.StackTrace, LogSeverity.Error); throw; } }