public ActionResult GetRoutes() { DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetRoutes", "routes")); return(View()); }
protected void Page_Load(object sender, EventArgs e) { // our helper class to get data DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetAllRoutesForMap", "locations")); }
protected void Page_Load(object sender, EventArgs e) { // our helper class to get data DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetRoutes", "routes")); }
protected void Page_Load(object sender, EventArgs e) { string sessionID = Request.QueryString["sessionID"]; // our helper class to get data DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetRouteForMap", "locations", new SqlParameter("@sessionID", sessionID))); }
protected void Page_Load(object sender, EventArgs e) { string sessionID = Request.QueryString["sessionID"]; // our helper class to get data DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetRouteForMap", "locations", new SqlParameter("@sessionID", sessionID))); }
public ActionResult GetRouteForMap() { string sessionID = Request.QueryString["sessionID"]; string phoneNumber = Request.QueryString["phoneNumber"]; // our helper class to get data DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "application/json"); Response.Write(reader.getJsonString("prcGetRouteForMap", "locations", new SqlParameter("@sessionID", sessionID), new SqlParameter("@phoneNumber", phoneNumber))); return(View()); }
public ActionResult DeleteRoute() { string sessionID = Request.QueryString["sessionID"]; string phoneNumber = Request.QueryString["phoneNumber"]; // our helper class to get data //DbXmlReader reader = new DbXmlReader(); DbJsonReader reader = new DbJsonReader(); Response.AppendHeader("Content-Type", "text/xml"); // actually we are getting a response back here, but the result will be a deleted route on the webpage Response.Write(reader.getJsonString("prcDeleteRoute", "routes", new SqlParameter("@sessionID", sessionID), new SqlParameter("@phoneNumber", phoneNumber))); return(View()); }