Professional Documents
Culture Documents
Server-Side RAD Order Tracking System
Server-Side RAD Order Tracking System
2
1 Description
Write a Spring Boot MVC application that allows a logged-in user to manage orders of
products for customers.
2 Requirements
The application should be written in Spring Boot based on the skeleton application available on
Moodle, and should use the Spring MVC n-tier architecture – Controllers, Services, Repositories,
Views, with the appropriate data/logic in each tier.
Product
o Product ID
o Description
o Quantity In Stock
Customer
o Customer ID
o Customer Name
Order
o Order ID
o Order Quantity
o Order Date
These models have been given in the skeleton code for the project and their dependencies
already set up.
3 Marks
This project is worth 50% of the marks for the module.
4 Submission
A zipped file containing the source code of the entire application should be uploaded to
Moodle before 5:00pm on Friday April 28th 2017.
5 Skeleton
The application should be created by updating the skeleton application available on Moodle.
3
6 Functionality
6.1 Main Screen
When the application starts, the user should see the following screen:
4
6.2 List Products
This screen shows the list of Products in the sales database:
5
6.3 Add New Product
This screen allows the user to add a new Product.
6.3.1 Success Conditions
If all information is entered correctly, the sales database is updated with the new product
information:
And the user is immediately brought to the List Products page, where the product just
entered is shown:
6
6.3.2 Invalid user input conditions
If the product description is blank, or the quantity in stock is less than 0 (assume it will
always be a number – never blank or a string) the following errors should be displayed, and
no product should be added to the sales database.
7
6.4 List Customers
This screen shows the list of Customers in the sales database.
Underneath each Customer is the list of orders they have placed, if any.
8
6.5 Add New Customer
This screen allows the user to add a new Customer.
6.5.1 Success Conditions
If all information is entered correctly, the sales database is updated with the new customer
information:
9
And the user is immediately brought to the List Customers page, where the customer just
entered is shown:
10
6.5.2 Invalid user input conditions
If the customer name is blank the following error should be displayed, and no customer
should be added to the sales database.
11
6.6 List Orders
This screen shows the list of Orders in the sales database, together with the name of the
customer who placed the order and the name of the product that was ordered.
12
6.7 Add New Order
This screen allows the user to add a new Order.
6.7.1 Success Conditions
If all information is entered correctly, the sales database is updated with the new customer
information:
13
And the user is immediately brought to the List Orders page, where the order just entered is
shown:
14
6.7.2 Business Logic for Order Creation:
The Order date (the current date) is automatically inserted by the application – the
user does not have to enter the date.
Before the order was placed the Quantity in Stock for Product 100 was 54 (see Figure
4 List of Products after new product added).
After the order was placed the Quantity in Stock for Product 100 will be 42 (54 – 12).
If the user enters a Quantity for an order greater than the Quantity in Stock the
following error page should be displayed:
15
6.7.3 Invalid user input conditions
If the Order Quantity is less than 1 (assume it will always be a number – never blank or a
string) the following errors should be displayed, and no product should be added to the
sales database.
(Assume the Customer ID and Product ID will never be blank)
If an invalid Customer ID and/or Product ID is entered, the following page should be shown to the
user:
16
Figure 17 Invalid Customer ID and Product Quantity too large error
17
6.8 Security
The application should implement security so that unless a user is logged in they will not be
able to navigate to any URL.
The only page they should be able to see is the index.html:
If user has not logged in and they attempt to access any of the applications URL endpoints, they
should be presented with the following form allowing them to log in:
6.8.1 Logout
There should be a logout button on the List Customers screen (see Figure 6 List of Customers).
18