public ActionResult GetRecipientTable(UPS.SpaceX.DAL.Recipient recipient) { try { var recipientTable = LookupService.GetRecipientTable(recipient.email); return(PartialView("~/Views/Home/_LookupRecipient.cshtml", recipientTable)); } catch (Exception e) { return(Json(new { Success = false, Data = e.Message }, JsonRequestBehavior.AllowGet)); } }
public ActionResult InsertRecord(UPS.SpaceX.DAL.Recipient recipient) { try { // TODO: Add insert logic here // call BLL which then calls DAL to insert donor UPS.SpaceX.BLL.ReserveService.InsertRecord(recipient); return(RedirectToAction("Index")); } catch (Exception ex) { return(Json(new { Success = false, Data = ex.Message }, JsonRequestBehavior.AllowGet)); // View(); } }