Пример #1
0
        //8. edit existing rooom

        private void editRoomsButton_Click(object sender, RoutedEventArgs e)
        {
            if (meetingRoomsListBox.SelectedItem != null)
            {
                meetingRoomsListBox.Items.Refresh();
                _roomModel = meetingRoomsListBox.SelectedItem as MeetingRoom;
                ECBRoomForm roomForm = new ECBRoomForm();
                roomForm.roomFormEdit(_roomModel, RefreshRooms);
                roomForm.Show();
                roomForm.refreshListRooms(RefreshRooms);
                showRoomsInListBox();
            }
        }
Пример #2
0
        //7. create new room

        private void newRoomsButton_Click(object sender, RoutedEventArgs e)
        {
            if (meetingCentresListBox.SelectedItem != null)
            {
                ECBRoomForm ecbRoom = new ECBRoomForm();
                ecbRoom.Show();
                _meetingCentreModel = meetingCentresListBox.SelectedItem as MeetingCentre;
                ecbRoom.roomFormNew(_meetingCentreModel);
                ecbRoom.refreshListRooms(RefreshRooms);
            }
            else
            {
                MessageBox.Show("Please first select the center where you want to create your room.");
            }
        }