// GET: api/M_Companies/5 public M_CompanyViewModel Get(int id) { return(M_CompanyRepo.GetById(id)); }
//GET View public ActionResult View(int id) { return(PartialView("_View", M_CompanyRepo.GetById(id))); }
//GET DELETE public ActionResult Delete(int id) { return(PartialView("_Delete", M_CompanyRepo.GetById(id))); }
//POST CREATE //[HttpPost] //public ActionResult Create(M_CompanyViewModel model) //{ // if (ModelState.IsValid) // { // Responses responses = (M_CompanyRepo.Update(model)); // if (responses.Success) // { // return Json(new { success = true }, JsonRequestBehavior.AllowGet); // } // else // { // return Json(new { success = false, message = "Error msg" }, JsonRequestBehavior.AllowGet); // } // } // return Json(new { success = false, message = "Invalid" }, JsonRequestBehavior.AllowGet); //} //GET Edit public ActionResult Edit(int Id) { return(PartialView("_Edit", M_CompanyRepo.GetById(Id))); }