Management Module Specs


The documented modules are:
  1. Add Room
    • Called By:
      • Management Menu
    • Calls:
      • Get Room Number
      • Get Room Type Name
    • Calling Sequence:
      1. Get New Room Number
      2. Verify Room Number
      3. Get Room Type Name
      4. Verify Room Type Name
      5. Add Information to Room Data Store
    • Inputs:
      • new room number
      • room type name (ie: deluxe, single)
    • Outputs:
      • confirmation that it was added properly
    • Errors:
      1. Room Number already exists
      2. Syntax of Room Number is Invalid (ie: not a number)
      3. Room Type Name doesn't exist yet
  2. Delete Room
    • Called By:
      • Management Menu
    • Calls:
      • Get Room Number
    • Calling Sequence:
      1. Get Room Number
      2. Check to see that room exists
      3. Make sure no one is currently booked in room, and in future
      4. Make sure no room service either
      5. Remove from data store
    • Inputs:
      • Room Number
    • Outputs:
      • Confirmation of deletion
      • On error a message stating who is booked in the room currently.
    • Errors:
      1. Room Number doesn't exist
      2. Room is actually booked
  3. Add Room Type
    • Called By
      • Management Menu
    • Calls:
      • Get Room Type
      • Get Room Rate
    • Calling Sequence:
      1. Get Room Type Name
      2. Verify Room Type Name
      3. Assign Room Type
      4. Get Room Rate
      5. Verify Room Rate
      6. Add to data store
    • Inputs:
      • Room Type Name
      • Room Rate
    • Outputs:
      • Confirmation that it was added correctly
    • Errors:
      1. Room Type Name already exists
      2. Syntax Error on Room Type Name
      3. Room Rate Syntax Errors (ie: not a number)
  4. Delete Room Type
    • Called By:
      • Management Menu
    • Calls:
      • Get Room Type Name
      • Delete Room
    • Calling Sequence:
      1. Get Room Type Name
      2. Verify Room Type Name
      3. Check to see if Rooms still exist of this type
      4. If so, delete those rooms that exist?
    • Inputs:
      • Room Type Name
    • Outputs
      • Confirmation that it was successful
      • A list of rooms that were removed from database also.
    • Errors:
      • Syntax Error for Room Type Name
      • Room Type Name doesn't exist
  5. Modify Room Type
    • Called By:
      • Management Menu
    • Calls:
      • Get Room Type Name
      • Get Room Rate
    • Calling Sequence:
      1. Get Room Type Name
      2. Verify Room Type Name
      3. Get Room Rate
      4. Verify Room Rate
      5. Update data store
    • Inputs:
      • Room Type Name
      • New room rate
    • Outputs:
      • Confirmation
    • Errors:
      • Room Type Name doesn't exist
      • Syntax errors on Room Type Name
      • Syntax errors on Rom Rate
    • Description:
      • This function should only occur during a certain time otherwise the invoicing will get messed up for people who are currently booked.

  6. Modify Room
    • Called By:
      • Management Menu
    • Calls:
      • Get Room Number
      • Get Room Type Name
    • Calling Sequence:
      1. Get Room Number
      2. Verify Room Number
      3. Get Room Type Name
      4. Verify Room Type Name
      5. Make changes
    • Inputs:
      • Room Number
      • New Room Type Name
    • Outputs:
      • Confirmation
    • Errors:
      1. Syntax of Room Number
      2. Room Number doesn't exist
      3. Room Type Name doesn't exist
      4. Room is currently booked thus unchangeable currently
    • Desciption:
      • As here invoices could be modified by accident for a client and should be used with care also.
  7. Add Credit Card
    • Called by:
      • Management
    • Calls:
      • NONE
    • Calling Sequence:
      1. Get a string from user. This is the Credit Card type they wish to add.
      2. Check if it exists already, if it does displays an error message.
      3. Adds the string to the credit card type table in the database.
    • Input:
      • String (The credit card type)
    • Errors:
      • ALLOCATED The string already exists in the table.
      • BLANK The user attempted to add a blank string.
    • Output:
      • Displays a dialog box informing the user of success or failure.
    • Description:
      • The function adds a credit card type to the database it then informs the user if it was successful or if there was a problem with the string.
  8. Delete Credit Card
    • Called by:
      • Management
    • Calls:
      • NONE
    • Calling Sequence:
      1. User selectes the string from a listbox.
      2. User is then prompted with an "are you sure" dialog to give them a chance to avoid deleting the string from the database.
      3. On a yes the string is deleted from the table in the database.
      4. A dialog box is displayed informing the user of the results of their actions.
    • Input:
      • Button click (credit card name is selected by the user)
    • Errors:
      • NONE
    • Output:
      • Dialog box feed back on results of user action.
    • Description:
      • This functions allows the user to select a credit card name and the removes it from the database.
  9. Modify Tax Rate
    • Called by:
      • TAX (sub-menu)
    • Calls:
      • Take_Floating_input
      • Modify_Rate
    • Calling Sequence:
      1. Take_FLoating_Input - (it will check whether the tax rate is valid or not if not it will ask the user input again or cancel to return to main menu. )
      2. Modify_Rate - (it will take two input one is the new tax rate, one is flag to indicate whether it is modify Tax or GST. It will update the tax rate in the data base)
    • Input:
      • TAX Rate
    • Output:
      • no visible output, new tax rate will be updated in the Data Base
    • Errors:
      • syntacically incorrect input(s)
    • Description:
      • It provide a way for the user change the tax rate once the tax rate has been changed. It calls one function to get the tax rate and check whether the tax rate is correct syntax or not. If a proper tax rate has been inputed, it will automatically update the tax rate in the data base.
  10. Modify GST
    • Called by:
      • TAX (sub-menue)
    • Calls:
      • Take_Floating_Input
      • Modify_Rate
    • Calling Sequence:
      1. Take_Floating_Input (it will check whether the tax rate is valid or not if not it will ask the user input again or cancel to return to main menu. )
      2. Modify_Rate (it will take two input one is the new tax rate, one is flag to indicate whether it is modify Tax or GST. It will update the GST in the data base)
    • Input:
      • GST
    • Output:
      • no visible output, new GST will be updated in the Data Base
    • Errors:
      • syntacically incorrect input(s)
    • Description:
      • It provide a way for the user change the GST once the GST has been changed. It calls one function to get the GST and check whether the GST is correct syntax or not. If a proper GST has been inputed, it will automatically update the GST in the data base.
  11. Add Fee
    • Called by:
      • FEE
      Calls:
      • Get_Item_Number
      • Search_item_number
      • Get_Fee_Description
      • Get_Fee
      • Add_Fee
    • Calling Sequence:
      1. Get_Item_Number (it will take the item number as input and check whether it is valid or not, if not it will return an error message)
      2. Search_item_number (this function will search the item number from the data base. if the item number is already exit, then return an error message and return to main menu)
      3. Get_Fee_Description (it will also check the syntax of the description, if incorrect syntac, then it will return an error message and return to main )
      4. Take_Floating_input (it will get the fee and check whether it is valid or not))
      5. Add_Fee (it will add fee into data base)
    • Input:
      • item number
      • fee description
      • fee
    • Output:
      • New fee item will be added into Data Base
    • Errors:
      • syntacically incorrect input(s)
    • Description:
      • It provide a way for the user to add a new fee item into the data base. It calls four functions to get the item number, fee description and fee, then it will verify those input. If correct, it will search the item is alrady exit or not. if not, it will be added into data base.
  12. Delete Fee
    • Called by:
      • FEE
      Calls:
      • Get_Item_Number
      • Search_item_number
      • DELE_Fee
    • Calling Sequence:
      1. Get_Item_number (it will take the item number as input and check whether it is valid or not, if not it will return an error message)
      2. Search_item_number (this function will search the item number from the data base. if the item does exit, then delete the fee, otherwise return a proper error message for the user )
      3. DELE_Fee (it will delete fee from the data base)
    • Input:
      • item number
    • Output:
      • no visible output, the fee item will be deleted in the Data Base
    • Errors:
      • syntacically incorrect input(s)
    • Description:
      • It provide a way for the user to delete a fee item from the data base. It calls two functions to get the item number, then it will verify input. If correct, it will search the item is exit or not. if yes, it will be deleted from data base.
  13. Modify Fee
    • Called by:
      • FEE
    • Calls:
      • Get_Item_Number
      • Search_item_number
      • Take_Floating_input
      • Modify_Fee
    • Calling Sequence:
      1. Get_Item_Number (it will take the item number as input and check whether it is valid or not, if not it will return an error message)
      2. Search_item_number (this function will search the item number from the data base. if the item number does exit, the Fee will be modified)
      3. Take_Floating_input (it will take the modify fee as input and also check the syntax)
      4. Modify_Fee (it will modify the fee in the data base)
    • Input:
      • item number
      • new fee
    • Output:
      • new fee item will be updated in Data Base
    • Errors:
      • syntacically incorrect input(s)
    • Description:
      • It provide a way for the user to modify fee into the data base. It calls three functions to get the item number and fee, then it will verify those input. If correct, it will search the item is alrady exit or not. if yes, it will update into data base.
  14. Add Employee
    • Called by:
      • Employee Sub-Menu
    • Calls:
      • Get new employee info.
      • Verify employee's info.
      • Re-enter password to confirm
    • Calling Sequence:
      1. Get new employee info.
      2. Verify employee's info.
      3. Re-enter password to confirm
    • Input:
      • employee ID
      • employee first name
      • employee last name
      • security type
      • password
    • Ouput:
      • Instance of "employee" to be added to the data store "Employees"
    • Errors:
      • Syntactically incorrect input(s)
      • Employee ID is already in use
    • Description:
      • Add a new employee into the Employee data store. It calles add_employee to add a new instance of employee information. It returns an error message if the employee ID already exist, or a successfull message.
  15. Modify Employee
    • Called by:
      • Employee Sub-Menu
    • Calls:
      • Modify Employee
      Calling Sequence:
      1. Get employee ID
      2. Verify employee ID
      3. Get new name/password/security type
    • Input:
      • employee ID
      • employee first name
      • employee last name
      • security type
      • password
    • Output:
      • (None)
    • Errors:
      • Syntactically incorrect input(s)
      • Employee ID not in used
    • Description:
      • Change the information about an employee. It calls a function to get the employee ID and verify it. If the employee ID does exists, the user can update the information about that employee specified by the employee ID. It returns an error message if the ID doesn't exist in the data store. Otherwise it returns a successfull message in the screen.
  16. Delete Employee
    • Called by:
      • Employee Sub-Menu
    • Calls:
      • Get employee ID
      • Verify employee ID
      • Delete employee
    • Calling Sequence:
      1. Get employee ID
      2. Verify employee ID
      3. Delete employee
    • Input:
      • employee ID read from the data store "Employees"
    • Output:
      • Instance of "employee" to be deleted from the data store "Books"
    • Errors:
      • Syntactically incorrect input(s)
      • Employee ID not in used
    • Description:
      • Delete a employee information from the data store "Employees". It calles a function to get the employee ID. If the employee ID does exists, the specific employeed record will be deleted from the data store "Employees". Otherwise it'll return a error message saying the employee not exist.
  17. Add Security Type
    • Called by:
      • Security Sub-Menu
    • Calls:
      • Get new security type / security name
      • Verify the security type
    • Calling Sequence:
      1. Get new security type / security name
      2. Verify the security type
    • Input:
      • security type
      • security name
    • Ouput:
      • Instance of "security" to be added to the data store "Security"
    • Errors:
      • Syntactically incorrect input(s)
      • Security Type is already in use
    • Description:
      • Add a new security type into the security data store. It calles add security to add a new instance of security type with number and name. It returns an error message if the security type already exist.
  18. Modify Security Type
    • Called by:
      • Employee Sub-Menu
    • Calling:
      • Modify Employee
    • Calling Sequence:
      1. Get security type
      2. Verify security type
      3. Get new security name
    • Input:
      • security type
      • security name
    • Output:
      • (None)
    • Error:
      • Syntactically incorrect input(s)
      • Security type not exist
    • Description:
      • Change the security name of a security type. It calls a function to get the information about a security type by given the specific type#. If the security type does not exist it will return a error message. Otherwise the security name can be changed.
  19. Delete Security Type
    • Called by:
      • Security Sub-Menu
    • Calls:
      • Get security type
      • Verify security type
      • Verify the existing security with employees
      • Delete security
    • Calling Sequence:
      1. Get security type
      2. Verify security type
      3. Verify the existing security with employees
      4. Delete security
    • Input:
      • security type
      • read from the data store "Security"
    • Output:
      • Instance of "security" to be deleted from the data store "Security"
    • Error:
      • Syntactically incorrect input(s)
      • Security type not exist
    • Description:
      • Delete a existing security type from the data store "Security". It calles a function to get the security type. If the security type# does not exist, it'll return a error message. Next it'll check if the security type is still in used by any employees. If yes, return a error message, otherwise the record with the specific security type will be deleted from the data store "Security"