public ActionResult EditComplaintForOPD(int id) { BL_ComplaintForOPD db = new BL_ComplaintForOPD(); ModelState.Clear(); return(View(db.GetComplaint(id))); }
public JsonResult ShowComplaint() { BL_ComplaintForOPD db = new BL_ComplaintForOPD(); return(new JsonResult { Data = db.SelectAllData(), JsonRequestBehavior = JsonRequestBehavior.AllowGet }); }
public ActionResult ComplaintForOPD(ComplaintForOPD obj) { try { BL_ComplaintForOPD Bl_ComplaintForOPD = new BL_ComplaintForOPD(); //if (Bl_reason.CheckReason(obj.ReasonID, obj.ReasonName)) //{ if (Bl_ComplaintForOPD.Save(obj)) { ModelState.Clear(); ViewData["flag"] = "Done"; } // } else { ViewData["flag"] = "Error"; } return(View()); } catch (Exception) { return(View()); } }