예제 #1
0
        public ActionResult DeletePost(int id)
        {
            var service = new LeadService();

            service.DeleteLead(id);

            TempData["SaveResult"] = "Your lead was deleted";

            return(RedirectToAction("Index"));
        }
예제 #2
0
        public ActionResult LeadDelete(int id)
        {
            var userId  = Guid.Parse(User.Identity.GetUserId());
            var service = new LeadService(userId);

            service.DeleteLead(id);

            TempData["SaveResult"] = "Your Lead was deleted";

            return(RedirectToAction("LeadIndex"));
        }