Edit a room
Design based on MVC model:
- View classes:
- LoginFrm is the interface to login. It needs a text field to enter the username, a text field to enter password, and a button to login.
- ManagerHomeFrm is the home interface for the Manager. It needs at least a button to go to the room management function.
- ManageRoomFrm is the interface to manage room. It needs at least a button to go to the room edit function.
- SearchRoomFrm is the interface to search the room to edit. It needs a text field to enter the keyword to search room by name, a button to search, and a table to show the list of founded room.
- EditRoomFrm is the interface to edit the attributes of a room. It needs the text fields for: name, type, price, description. a button to update and a button to reset
- Control (DAO – Data Access Object) classes:
- DAO is a general class of DAO. It has only the construction to connect to the DB and provides the common connection for all inherited DAO classes in the system.
- UserDAO is the class for manipulating with DB related to the User object. In this module, it needs a method to verify whether the login information is correct or not, it is checkLogin() method.
- RoomDAO is the class for manipulating with DB related to the Room object. In this module, it needs two methods:
- searchRoom(): to search all rooms whose name contains the entered keyword.
- updateRoom(): to update information a bout the input room.
- Entity classes: User, Room.

Booking room
In this module, the login processing is omitted:
- View classes:
- SellerHomeFrm is the home interface of the Seller. It needs at least a button to go to the booking function.
- SearchFreeRoomFrm is the interface to search available room. It needs two text fields (or date pickers) to enter the check-in and checkout date, a search button and a table to show the results.
- SearchClientFrm is the interface to search and select the client. It needs a text field to enter the keyword to search client by name, a button to search, a table to show the list of founded client, and a button to add new client if the booking client does not exist in the DB.
- AddClientFrm is the interface to add new client. It needs the input text fields to enter the client information: name, address, id card number, telephone, note…
- ConfirmFrm is the interface to confirm the booking information.
- Control (DAO) classes:
- RoomDAO has a method to search available rooms searchFreeRoom().
- ClientDAO has two methods:
- searchClient(): to search client whose name contains the entered key
- addClient(): to add new client into the DB
- BookingDAO has w method to add a new booking addBooking().
- Entity classes: Room, Client, Booking, BookedRoom, and User.

View room statistic
In this module, the login processing is also omitted:
- View classes:
- ManagerHomeFrm is the home interface for the Manager. It needs at least a button to go to the view statistic function.
- SelectStatFrm is the interface to config the statistical report. It has a selection to select the type and the object of the statistical report.
- RoomStatFrm is the interface of the room statistics. It needs two text fields (or date pickers) to set the duration of statistic, a button to view and a table to show the results.
- RoomDetailFrm is the interface to show the detail statistic from a chosen room. It needs a table to show the list of Bill issued during the statistical interval.
- Control (DAO) classes:
- RoomStatDAO has a method getRoomStat() to get the room statistics during the input interval.
- BillDAO has a method getBillbyRoom() to get the list of Bill of a chosen room issued during the statistical interval.
- Entity classes: RoomStat, Bill. RoomStat inherits from Room. Bill needs component classes User and Booking. Booking needs component classes BookedRoom, Client and UsedService. UsedService needs component class Service.
