In this group project, you will be allowing a user to interact with a basic product ordering database.
*********************************************************
** Welcome to Bangazon! Command Line Ordering System **
*********************************************************
1. Create a customer account
2. Choose active customer
3. Create a payment option
4. Add product to shopping cart
5. Complete an order
6. See product popularity
7. Leave Bangazon!
>
Enter customer name
>
Enter street address
>
Enter city
>
Enter state
>
Enter postal code
>
Enter phone number
>
Which customer will be active?
1. John Q. Public
2. Svetlana Z. Herevazena
>
Enter payment type (e.g. AmEx, Visa, Checking)
>
Enter account number
>
Note: These are examples. Add your own product names, please.
To make it easier to add multiple products, when the user selects a product to order, display the menu of products again. Make sure the last option of Back to main menu so the user can specify that no more products are needed.
1. Diapers
2. Case of Cracking Cola
3. Bicycle
4. AA Batteries
...
9. Done adding products
Please add some products to your order first. Press any key to return to main menu.
Your order total is $149.54. Ready to purchase
(Y/N) >
# If user entered Y
Choose a payment option
1. Amex
2. Visa
>
Your order is complete! Press any key to return to main menu.
# If user entered N, display the main menu again
Once the order is complete, show the main menu again, where the user can start creating another order.
When selecting this option, you will produce a command line report that looks like the following.
Product Orders Customers Revenue
*******************************************************
AA Batteries 100 20 $990.90
Diapers 50 10 $640.95
Case of Cracki... 40 30 $270.96
*******************************************************
Totals: 190 60 $1,902.81
-> Press any key to return to main menu
- The product column must be 18 characters wide, and will display a maximum of 17 characters for the product name.
- The orders column must be 11 characters wide.
- The customers column must be 11 characters wide.
- The revenue column must be 15 characters wide.
You will create a series of prompts that will allow the user to create various types of data in your ordering system.
- Start with writing unit tests. As a group, determine the core functionality of the application. Define classes and methods that you think you need to build. Do that before writing the implementation code for core logic. DO NOT WRITE TESTS FOR THE USER INTERFACE (menu and prompts).
- All classes and methods must be fully documented with docstrings.