I have 2 HttpPost. One is called by Json. And another is called when user submits the page.
When User clicks Delete button on page, i call DeletePhone method which deletes the records but problem is it also calls the another [HttpPost](in below code 1st one).
How to stop calling another [HttpPost]?
[HttpPost]
public ActionResult Phones(Phones model)
{
....
}
[HttpPost]
public JsonResult DeletePhone(int documentid)
{
string phoneName = Session["PhoneName"].ToString();
bool result = settings.deletePhone(schemaName);
return Json(result, JsonRequestBehavior.AllowGet);
}