This is a GUI Java application that can process orders from clients. It works with a MySQL database. Uses the JDBC driver.
Use Cases...
As you can see a lot of stuff can be done like adding shippers, searching for products, orders etc.


This is the diagram of the relational database. A dump file is included in the project. Export it to your MySql Framework. The database was made using MySql WorkBench.

- The Presentation layer consists of 4 classes and is organized on the MVC model:
View: it contains all the methods for constructing the GUIModel: contains the methods that will further communicate with the Model classesController: adds the functionality of the Model class to the ViewTableContent: it is an enum and it is used to store the current state of the table showing on the screen(in the class View there is only 1 table and its content is always changed according to which button is pressed)
- The Model layer contains 1 parent class and 6 child classes. For every table in the database, there is a corresponding class with EXACTLY the same field names and field data types.Category,Client,Supplier,Shipper,Product,Orders– are the child classesAbstractModelis the parent class and it extendsAbstractBLLclass(so every model class extendsAbstractModel<T extends AbstractBLL>where T is the corresponding BLL class for every table. In this way, for every model class, its corresponding BLL class can be stored easily so the programmer does not need to verify it each time for what model class what bll class corresponds…
- The Model Layer(BLL) contains classes that implement the application logic. TheAbstractBLLabstract class contains the methods for communicating with theDAOclasses(update/insert/delete/find). But it also contains methods which can be applied to different model objects before inserting them into the database or after extracting them from the database. For every model class there is a corresponding BLL class which extends the parentAbstractBLLand each of these classes override thegetValidators()method which returns a List with the validators that need to be applied only to that particular model class.- validators: there is another subpackage named
validatorsin the bll package which contains all the classes that are used for validating data: and Email validator, a Phone validator, and a Date validator. These classes implement the interfaceValidatorand add functionality to the one, single method in the interface: validate. - data: for now, this subpackage contains only one class named
OrderFilewhich does not else but creates a .txt file for each order.
- The Infrastructure layer is further divided into 2 more packages:daoandconnection. connection: contains a singleton classConnectionFactorywhich is responsible for accessing the database, retrieving connections and closing connections.dao: contains an abstract class namedAbstractDAOwhich implements all the necessary operations which need to be implemented on a table like: insert, delete, find by id, find all, update. It works with generic model objects. There are 6 otherdaoclasses which are the children ofAbstractDAOand they are the correspondingdaoclasses for the model classes one by one and they add full functionality to the parent class in the sense that the parent class knows with what type of data it is working on.

- The UML diagram in the package
dao:

- The UML diagram in the package
model:

- The UML diagrams in the package
bllwith its 2 subpackages:

- The UML diagram in the package
presentation:

- After the application starts, the end user will see this:

- To view other tables, one button from the top needs to be pressed:

- For operations, use the buttons on the left:

- For updating a row, simply select the cell you want to modify, double click it and then modify to your needs. Then either press enter or double click elsewhere. Then press the
updatebutton. - For inserting a new row, press the
insertbutton, and then introduce the new fields. Be attentive when introducing the values and introduce only valid data. PressOK. If you get the message:Insert Successful, it means that you inserted the row successfully else you will get a warning message alongside a log in the console. Check it to further explanation of the error. - For deleting a row, simply click once a row, and it will be colored in blue. Press the
deletebutton. Whoala. - For searching for specific elements, you have to first choose the field for which you are applying the filter then in the input box, type your data for which you want to search. If the chosen field has a
Stringformat then the option bigger/smaller don’t have any purpose for now. Just press OK. All the rows having the field that contain theStringyou entered will appear. Fornumberformats, use the bigger/smaller button to search for bigger, smaller values. If you do not select any of the 2, only equal values will be showed to you. When searching forDateformat, you can use the bigger/smaller option as well to search for previous dates or dates after a given date. - To show the total number of rows, simply press the
totalsbutton and then enter. For the tableOrdersandProductthere is one more option for selecting the total number of quantities. - GOOD LUCK!














