do Display accounting menu Get the menu item from the user switch (menu item) case display_invoice call display_invoice() break case print_invoice call print_invoice() break case search_invoice call search_invoice() break case paid_invoice call paid_invoice() break case quarterly_report call quarterly_report() break case data_to_date_report call data_to_data_report() break case unpaid_invoice_report call unpaid_invoice_report() break while (menu item != exit) return to main menu
do Display dialog box to get the invoice_number if (check_invoice(invoice_number) == valid) invoice = get_invoice(invoice_number) if (invoice == error) Display dialog box reporting the invalid invoise number Display a text box on the screen with the formated data from the invoice else Display dialog box reporting the syntax error while (check_invoice(invoice_number) == invalid) Return the accounting menu
do Display dialog box to get the invoice_number if (check_invoice(invoice_number) == valid) invoice = get_invoice(invoice_number) if (invoice == error) Display dialog box reporting the invalid invoise number Format the invoice and send it to the printer else Display dialog box reporting the syntax error while (check_invoice(invoice_number) == invalid) Return the accounting menu
do Display a text box to the user to get the search parameters if the search parameters are valid find the list of invoices billed by the employee id find the list of invoices billed for the guest id find the list of invoices for the room number find the list of invoices that have the date given cross reference the 4 invoice lists and find the invoices in common display the common invoice list to the user else Display a dialog to let the user know whats wrong while search parameters are invalid
do Display dialog box to get the invoice_number if (check_invoice(invoice_number) == valid) invoice = get_invoice(invoice_number) if (invoice == error) Display a dialog box reporting the invalid invoice number. else if invoice.paid == true then Display a dialog box reporting the that invoice is already paid. else Format the invoice and send it to the printer else Display dialog box reporting the syntax error while (check_invoice(invoice_number) == invalid) Return the accounting menu
Call Generate Report with the start and end dates for the Quarter Display the Quarterly report to the user in a text box. Display the dialog box asking the user if they want to print the report If the dialog box returned yes Send the report to the printer Return to the accounting menu
do Display a text box to the user to get the start and end date while (start date is invalid OR end date is invalid) Call Generate Report with the start and end dates Display the report to the user in a text box Display the dialog box asking the user if they want to print the report If the dialog box returned yes Send the report to the printer Return to the accounting menu
Get the list of invoices from the Invoices datastore. For each record in the list Next record if the date is before the start date or after the end date found = found + 1 Add the record data to the room type total if found equals 0 Display a dialog box reporting that there is no data for the report Generate the report from the totaled data and return it to the calling function
Get the list of invoices from the Invoices datastore. For each record in the list Next record if the invoice is paid Add the record to the display list If the display list is empty Display a dialog box reporting that all invoices are paid else Display A dialog box to the user asking if they want to print the report If the dialog return yes Send the display list to the printer Return the the accounting menu