예제 #1
0
        public ActionResult ConfirmProject(int Id)
        {
            ViewBag.EnquiryID           = Id;
            TempData["EnquiryIDClient"] = Id;
            Project p = new Project();

            p.EnquiryID = Id;
            BusinessFlow.Controllers.ProjectsController pdc = new ProjectsController();
            try
            {
                pdc.Create(p);
                new JavaScriptResult {
                    Script = "alert('You are done!');"
                };
            }
            catch
            {
                return(new JavaScriptResult {
                    Script = "alert('You are not done!');"
                });
            }
            return(View());
        }
예제 #2
0
 public ActionResult ConfirmProject(int Id)
 {
     ViewBag.EnquiryID = Id;
     TempData["EnquiryIDClient"] = Id;
     Project p = new Project();
     p.EnquiryID = Id;
     BusinessFlow.Controllers.ProjectsController pdc = new ProjectsController();
     try
     {
         pdc.Create(p);
         new JavaScriptResult { Script = "alert('You are done!');" };
     }
     catch
     {
         return new JavaScriptResult { Script = "alert('You are not done!');" };
     }
     return View();
 }