public ActionResult Accept(UPGModal model) { var rnd = new Random(); var no = rnd.Next(1000, 100000000); model.transactionnumber = no.ToString("0000000"); model.transactiontime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); doCheck(model); String data = Helpers.ConvertToQueryString<UPGModal>(model); var idx = model.callbackurl.IndexOf("/", 10); var returnurl = model.callbackurl.Substring(0, idx + 1) + "users"; return Redirect(returnurl); }
private void doCheck(UPGModal model) { String data = Helpers.ConvertToQueryString<UPGModal>(model); HttpWebRequest webRequest = null; HttpWebResponse webResponse = null; try { webRequest = (HttpWebRequest)HttpWebRequest.Create(model.callbackurl + data); webRequest.Method = "get"; webRequest.ContentType = "text/plain; encoding='utf-8'"; //Get Response webResponse = (HttpWebResponse)webRequest.GetResponse(); HttpWebRequest req; req = (HttpWebRequest)WebRequest.Create(model.callbackurl); } catch (Exception e) { System.Diagnostics.Debugger.Log(0, "here", e.Message); } }
private string getParamsFromModel(UPGModal model) { return model.callbackdata; }
public ActionResult Reject(UPGModal modal) { return View(); }
// // GET: /UPG/ public ActionResult Index(UPGModal model) { model.userrefno = model.itemcode; model.showentry = model.transactionamount; return View(model); }