예제 #1
0
        public ActionResult ScheduleSlot(string date)
        {
            TeeTimeBooking ttb = new TeeTimeBooking();

            ttb.ScheduledTime = DateTime.Parse(date);
            return(View(ttb));
        }
예제 #2
0
        public void BookTeeTime(TeeTimeBooking teetime)
        {
            using (SquawCreekDeVryEntities db = new SquawCreekDeVryEntities())
            {
                TeeTime tt = new TeeTime();
                tt.BookedBy        = teetime.BookedBy;
                tt.Cart            = teetime.Cart;
                tt.Id              = Guid.NewGuid();
                tt.Member          = teetime.Member;
                tt.NumberOfPlayers = teetime.NumberOfPlayers;
                tt.Paid            = false;
                tt.ScheduleTime    = teetime.ScheduledTime;
                tt.Created         = DateTime.Now;

                db.TeeTimes.Add(tt);
                db.SaveChanges();
            }
        }
예제 #3
0
 public ActionResult ScheduleSlot(TeeTimeBooking teetime)
 {
     m_teeTimeBO.BookTeeTime(teetime);
     return(View("BookSuccess"));
 }