protected void RoomInsert(int BookingDetailsId)
        {
            RoomDetailstbl rd1 = new RoomDetailstbl()
            {
                RoomDetailsId    = 0,
                BookingDetailsId = 0,
                Adults           = 2,
                Kids             = 2,
                Status           = 1,
                RoomType         = "1stsingle",
                Price            = "1000",
            };
            List <GuestDetailstbl> GDtbl = new List <GuestDetailstbl>();

            gd1.BookingDetailsId = BookingDetailsId;
            gd2.BookingDetailsId = BookingDetailsId;
            gd3.BookingDetailsId = BookingDetailsId;
            gd4.BookingDetailsId = BookingDetailsId;
            GDtbl.Add(gd1);
            GDtbl.Add(gd2);
            GDtbl.Add(gd3);
            GDtbl.Add(gd4);
            rd1.GuestDetails = GDtbl;
            //rd2.GuestDetails = GDtbl;
            //rd3.GuestDetails = GDtbl;
            List <RoomDetailstbl> objRDT = new List <RoomDetailstbl>();
            RoomDetailstbl        objrd  = new RoomDetailstbl();

            objRDT.Add(rd1);
            //objRDT.Add(rd2);
            //objRDT.Add(rd3);
            for (int i = 0; i < objRDT.Count(); i++)
            {
                List <RoomDetailstbl> lrt = new List <RoomDetailstbl>();

                objrd.BookingDetailsId = objRDT[i].BookingDetailsId;
                objrd.RoomType         = objRDT[i].RoomType;
                objrd.Adults           = objRDT[i].Adults;
                objrd.Kids             = objRDT[i].Kids;
                objrd.Status           = objRDT[i].Status;
                objrd.Price            = objRDT[i].Price;
                lrt = objRoomBL.InsertRoom(objrd).ToList();
                //lrt = objRoomBL.InsertRoom(objrd).ToList();
                lrt = objRoomBL.GetMaxRoom(objrd).ToList();
                GuestInsert(lrt.First().RoomDetailsId);
            }
        }
예제 #2
0
 public IEnumerable <RoomDetailstbl> GetMaxRoom(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(9, rd));
 }
예제 #3
0
 public IEnumerable <RoomDetailstbl> GetRoomByStatus(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(8, rd));
 }
예제 #4
0
 public IEnumerable <RoomDetailstbl> UpdateRoomIsActive(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(6, rd));
 }
예제 #5
0
 public IEnumerable <RoomDetailstbl> UpdateStatus(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(7, rd));
 }
예제 #6
0
 public IEnumerable <RoomDetailstbl> DeleteRoom(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(5, rd));
 }
예제 #7
0
 public IEnumerable <RoomDetailstbl> UpdateRoom(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(4, rd));
 }
예제 #8
0
 public IEnumerable <RoomDetailstbl> InsertRoom(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(3, rd));
 }
예제 #9
0
 public IEnumerable <RoomDetailstbl> GetRoombyId(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(2, rd));
 }
예제 #10
0
 public IEnumerable <RoomDetailstbl> GetAllRoom(RoomDetailstbl rd)
 {
     return(objRoomDA.RoomDetails(1, rd));
 }