public ActionResult AddPledge(UserViewModel uvModel)
        {
            UserData ud = new UserData();
            string errorMessage = ud.AddPledge((int)Session["UserId"], uvModel.AmountToPledge);

            uvModel.GetEventsByUserId((int)Session["UserId"]);

            ViewData["ErrorMessage"] = errorMessage;

            return View("UserEvents", uvModel);
        }
        public ActionResult UserEvents(UserViewModel uvModel)
        {
            UserData ud = new UserData();
            string errorMessage = ud.RemoveEventFromUser((int)Session["UserId"], uvModel.EventIdToRemove, (string)Session["UserType"]);

            uvModel.GetEventsByUserId((int)Session["UserId"]);

            // Insert this ViewData object onto the page somewhere so the user knows if there is an error
            // Otherwise the event will disappear from the list
            ViewData["ErrorMessage"] = errorMessage;

            return View("UserEvents", uvModel);
        }
        public ActionResult UserEvents()
        {
            if (Session["UserId"] == null || (int) Session["UserId"] == 0)
            {
                ViewData["ErrorMessage"] = "You must be signed in to view this data";
                return Redirect("~/Account/Login");
            }

            UserViewModel uvModel = new UserViewModel();
            uvModel.GetEventsByUserId((int)Session["UserId"]);

            return View("UserEvents", uvModel);
        }