Example #1
0
 public async Task <JsonResult> LPGetByID()
 {
     try {
         var id   = Guid.Parse(Request.Form["id"]);
         var oid  = Guid.Parse(Request.Form["oid"]);
         var data = LeadPageService.GetByID(id, oid);
         var api  = Guid.Parse(Request.Form["aid"]);
         var vms  = LeadPageService.SetSubdata(data, api);
         return(Success(vms));
     } catch { return(Failed(MessageUtilityService.ServerError())); }
 }
Example #2
0
 public async Task <JsonResult> LPInsert()
 {
     try {
         var id    = Guid.Parse(Request.Form["id"]);
         var title = Request.Form["title"];
         var desc  = Request.Form["desc"];
         var oid   = Guid.Parse(Request.Form["oid"]);
         var bgid  = Guid.Parse(Request.Form["bgid"]);
         var mid   = Guid.Parse(Request.Form["mid"]);
         var tdid  = Guid.Parse(Request.Form["tdid"]);
         if (LeadPageService.Insert(id, title, desc, oid, bgid, mid, tdid))
         {
             return(Success(id.ToString()));
         }
         return(Failed(MessageUtilityService.FailedInsert("Lead Pages")));
     } catch { return(Failed(MessageUtilityService.ServerError())); }
 }