public ActionResult Create(Wish wish)
        {
            if (ModelState.IsValid)
            {
                //adding a prefix to the wish string
                //string TheWish = "I wish to " + wish.KidWish;


                service.Add(wish);
                service.Commit();



                // return RedirectToAction("Details" , new { id = wish.WishID});
                return(RedirectToAction("WishesFundRaisedByAFundRaiser"));
            }

            ViewBag.KidID = new SelectList(KidService.GetMany(), "KidID", "KidFistName", wish.KidID);
            return(View(wish));
        }
        // GET: CarPool
        public ActionResult Index(string searchString, int[] array, int?i)
        {
            des = new List <CarPool>();
            List <Kid> Kids = ServicePar.GetMany().ToList();

            ViewBag.MyKid = new SelectList(Kids, "IdKid", "FirstName");

            List <User> Parents = Service.GetMany().ToList();

            ViewBag.MyParent = new SelectList(Parents, "IdUser", "prenom");

            List <User> Parentn = Service.GetMany().ToList();

            ViewBag.MyParentn = new SelectList(Parentn, "IdUser", "nom");

            List <GeoLocation> geo = db.GeoLocations.ToList <GeoLocation>();

            ViewBag.Geo = geo;

            ViewBag.UserGeo = (from s in db.GeoLocations      // outer sequence
                               join st in db.Users            //inner sequence
                               on s.ParentFK equals st.idUser // key selector

                               select new
            {                    // result selector
                idUser = s.ParentFK,
                NomUser = st.nom,
                PrenomUser = st.prenom,
                AddressUser = s.Address,
                Lat = s.lat,
                Lng = s.lng
            }).ToList();

            var    userId = (int)Session["idu"];
            int    id     = ps.GetById(userId).idUser;
            String nom    = ps.GetById(userId).nom;
            String prenom = ps.GetById(userId).prenom;
            String mail   = ps.GetById(userId).email;

            ViewBag.home   = mail;
            ViewBag.nom    = nom;
            ViewBag.prenom = prenom;
            ViewBag.id     = id;



            //  var Carpool = db.CarPools;
            //  var daily = Carpool.Where(z => z.Daily == true).ToString();
            //  var everyweekday = Carpool.Where(z => z.EveryWeekDay == true).ToString();
            //  var weekly = Carpool.Where(z => z.Weekly == true).ToString();
            //  ViewBag.weekly = new SelectList(weekly);
            //  ViewBag.everyweekday = new SelectList(everyweekday);
            //  ViewBag.weekly = new SelectList(daily);

            var carps = new List <CarPoolModel>();

            foreach (CarPool c in sc.SearchParentByTo(searchString))
            {
                CarPoolModel cs = new CarPoolModel()
                {
                    Id           = c.Id,
                    Title        = c.Title,
                    From         = c.From,
                    To           = c.To,
                    Time         = c.Time,
                    Date         = c.Date,
                    Message      = c.Message,
                    idKid        = c.idKid,
                    Daily        = c.Daily,
                    Weekly       = c.Weekly,
                    EveryWeekDay = c.EveryWeekDay,
                    UntilDate    = c.UntilDate,
                    NbPlaceDispo = c.NbPlaceDispo,
                    idParent     = c.idParent,
                };

                carps.Add(cs);
            }
            if (searchString == null)
            {
                //just load the main index
                return(View(carps.ToPagedList(i ?? 1, 7)));
            }
            else
            {
                return(View(carps.Where(car => car.To == (searchString)).ToPagedList(i ?? 1, 7)));
            }
        }