public ActionResult Contact(ConactUs contactUs)
 {
     if (ModelState.IsValid)
     {
         ContactUsService.AddContactUs(contactUs);
         TempData["message"] = "success";
     }
     else
     {
         TempData["error"] = "error";
         TempData["contactus"] = contactUs;
     }
     return RedirectToAction("Contact", "Home", new { controller = "Home", action = "Contact" });
 }
Example #2
0
 public void RemoveContactUs(ConactUs contactUs)
 {
     DataBase.Delete(contactUs);
 }
Example #3
0
 public void AddContactUs(ConactUs contactUs)
 {
     DataBase.Insert(contactUs);
 }