Develop an MVC JavaFX GUI application to display a company's payroll report. The application consists of two windows and a java class.
The employee class will have four field variables:
It will also have the following methods:
public static boolean validateEmployee (Employee emp) {//...}
The first window consists of number of TextFields and a button (Add Employee) to get the following information from the user and store them in an ArrayList:
Employee's first name, last name, hourly rate, and hours worked.
NOTE: You must first call the static method validateEmployee to ensure the object is validated.
If the information is invalid, show a warning dialog letting the user know the information were out of range, otherwise add the record to the array.
This first window will have another button (Show Employee). When clicked a second window will open and. The second window will use a Text Area to view the employees and their gross pay.
Employee Hourly Rate Hours Worked Gross Pay
Adam Knox $6.50 38 $247.00
Bob Brown $5.70 50 $313.50
Ed Smith $7.00 40 $280.00
Final Total $840.50
Separation between GUI and back-end classes: Remember that you should try to keep the GUI (and back-end classes (other non-GUI classes) as separate and clean as possible. This means don't put any GUI code in the back-end classes, and don't put code in the GUI class(es) that really belongs in a back- end class. To that end your project should consist of separate (java, .fxml and controller classes) for each window in addition to an Employee.java.
Enable the user to use a button (Save Employees) button on the first Window to write the list of employees to a CSV file.
Enable the user to use the (Load Employees) button on the first Window to fill the ArrayList with a list of employees from a CSV file.