Beispiel #1
0
        private void dgvBookingList_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (MessageBox.Show("Make a check in?", "", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No)
            {
                return;
            }
            string selectedBookingId = this.dgvBookingList.Rows[e.RowIndex].Cells[0].Value.ToString();

            CheckInBUS.AddCheckInBaseOnBooking(selectedBookingId);
            this.bookingDTOBindingSource.DataSource = BookingBUS.GetBookings();
            this.checkInDTOBindingSource.DataSource = CheckInBUS.GetCheckIns();
        }
Beispiel #2
0
        public MainForm(EmployeeDTO employee)
        {
            this.InitializeComponent();
            this.employee = employee;
            this.comboBoxRoomType.DropDownStyle = ComboBoxStyle.DropDownList;
            this.comboBoxRoomType.Items.AddRange(new object[] { "None", TypeOfRoom.A, TypeOfRoom.B, TypeOfRoom.C, TypeOfRoom.D });

            this.bookingDTOBindingSource.DataSource = BookingBUS.GetBookings();
            this.checkInDTOBindingSource.DataSource = CheckInBUS.GetCheckIns();

            this.ReloadGridViewRoomAndBookingDetail();
        }