示例#1
0
 public ActionResult AddHotel(TypeOfHotelViewModel typeOfHotel)
 {
     if (Request.HttpMethod == "POST")
     {
         var typeOfHotelDto = MappingViewModel.MapTypeOfHotelDTO(typeOfHotel);
         _adminService.AddHotel(typeOfHotelDto);
         return(RedirectToAction("Index", "Home"));
     }
     else
     {
         return(View());
     }
 }