Пример #1
0
        public ActionResult PayWishlist(Reservations reservation)
        {
            if (ModelState.IsValid)
            {
                Wishlists wishlistInSession = null;
                if (Session["wishlist"] != null)
                {
                    wishlistInSession = (Wishlists)Session["wishlist"];
                }
                List <WishlistViewModel> wishlist = GetActivitiesFromSession();
                if (wishlist != null)
                {
                    wishListRepo.ReservationOfActivities(wishlist, reservation, wishlistInSession);
                    ViewBag.succes = "Betaling voltooid";
                    return(View("Index", GetActivitiesFromSession()));
                }
            }
            ViewBag.errors = "Betaling mislukt!";
            List <string> methodes = new List <string>();

            methodes.Add("Ideal");
            methodes.Add("Paypal");
            methodes.Add("Creditcard");
            PaymentMethodsDropDown();
            return(View());
        }