Пример #1
0
        public ActionResult User_Registraion_Form(User_Info dcc, HttpPostedFileBase postedFile)
        {
            if (ModelState.IsValid)
            {
                string fileName = System.IO.Path.GetFileName(postedFile.FileName);

                //Set the Image File Path.
                string filePath = "~/Uploads/user_img/" + fileName;

                //Save the Image File in Folder.
                postedFile.SaveAs(Server.MapPath(filePath));

                using (var context = new DestCoveryContext())
                {
                    context.Users.Add(dcc);
                    context.SaveChanges();

                    MesageService ms = new MesageService();

                    string msg = "Welcome Sir/Madam !! Thank you for choosing us. Your Accout is active and you can enjoy your service. DESTCOVERY :)";
                    ms.TextLocal(dcc.User_Mobile, msg);
                }

                ViewBag.LOGINMSG = "Registered Successfully. Please Login";

                return(RedirectToAction("login", "Home"));
            }
            else
            {
                return(View());
            }
        }
Пример #2
0
        public ActionResult ContactUs(ContactUs cu)
        {
            string response = "";

            using (var context = new DestCoveryContext())
            {
                context.Contact_Us.Add(cu);
                context.SaveChanges();

                MesageService ms = new MesageService();

                string msg = "Welcome Sir/Madam !! Thank you for choosing us.I hope we will give some amazing experience and We will contact you soon. DESTCOVERY :)";
                response = ms.TextLocal(cu.person_mobile, msg);
            }

            @ViewBag.DISPLAYMSG = "Thank You We will Contact You Soon! ";

            return(View());
        }
Пример #3
0
        public ActionResult CancelBooking(Bookings b, int bookingid, string user_no)
        {
            if (Session["AdminID"] == null)
            {
                return(RedirectToAction("login", "Admin"));
            }
            else
            {
                DestCoveryContext dcc = new DestCoveryContext();
                var data = dcc.Booking_pckg.Where(x => x.Booking_Id == bookingid).FirstOrDefault();
                if (data != null)
                {
                    data.Booking_Status = "Admin Cancel";
                }
                dcc.SaveChanges();

                MesageService ms = new MesageService();

                string msg = "Thank you for choosing us but sorry to inform you unfortunately this Tour / Package is not availble for you. If there’s anything else we can help you with, please let us know. DESTCOVERY :) ";
                ms.TextLocal(user_no, msg);

                return(RedirectToAction("bookingpending", "Admin"));
            }
        }
Пример #4
0
        public ActionResult ConfirmBooking(Bookings b, int bookingid, string user_no)
        {
            if (Session["AdminID"] == null)
            {
                return(RedirectToAction("login", "Admin"));
            }
            else
            {
                DestCoveryContext dcc = new DestCoveryContext();
                var data = dcc.Booking_pckg.Where(x => x.Booking_Id == bookingid).FirstOrDefault();
                if (data != null)
                {
                    data.Booking_Status = "Confirm";
                }
                dcc.SaveChanges();

                MesageService ms = new MesageService();

                string msg = "Welcome Sir/Madam !! Thank you for choosing us. I hope we will give some amazing experience throuout this tour. Let us know how it goes. Best wishes for a safe, happy, and healthy journey!! I hope you continue to enjoy our services! DESTCOVERY :) ";
                ms.TextLocal(user_no, msg);

                return(RedirectToAction("bookingpending", "Admin"));
            }
        }