Package scheduler.controller
Class CustomersOverviewController
- java.lang.Object
-
- scheduler.controller.CustomersOverviewController
-
- All Implemented Interfaces:
javafx.fxml.Initializable
public class CustomersOverviewController extends java.lang.Object implements javafx.fxml.Initializable
Controller for the Overview screen
-
-
Field Summary
Fields Modifier and Type Field Description private javafx.scene.control.Button
buttonAddNewCustomer
private javafx.scene.control.Button
buttonAppointments
private javafx.scene.control.Button
buttonCustomers
private javafx.scene.control.Button
buttonLogout
private javafx.scene.control.Button
buttonOpen
private javafx.scene.control.Button
buttonOverview
private javafx.scene.control.Button
buttonReports
private javafx.scene.control.Button
buttonSearch
private javafx.scene.control.TableColumn<Customer,java.lang.String>
labelAddress
private javafx.scene.control.TableColumn<Customer,java.lang.Integer>
labelCountry
private javafx.scene.control.TableColumn<Customer,java.lang.Integer>
labelCustomerID
private javafx.scene.control.TableColumn<Customer,java.lang.Integer>
labelDivisionID
private javafx.scene.control.TableColumn<Customer,java.lang.String>
labelName
private javafx.scene.control.Label
labelNameSelector
private javafx.scene.control.TableColumn<Customer,java.lang.String>
labelPhoneNumber
private javafx.scene.control.TableColumn<Customer,java.lang.String>
labelPostalCode
(package private) javafx.scene.Parent
scene
(package private) javafx.stage.Stage
stage
private javafx.scene.control.TableView<Customer>
tableAllCustomers
private javafx.scene.control.TextField
textfieldSearch
-
Constructor Summary
Constructors Constructor Description CustomersOverviewController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
initialize(java.net.URL url, java.util.ResourceBundle resourceBundle)
Initializes the Customers Overview Controller(package private) void
onClickAddNewCustomer(javafx.event.ActionEvent event)
Loads the Add customer screen when the ADD CUSTOMER button is clicked.(package private) void
onClickAppointments(javafx.event.ActionEvent event)
Navigates the user to the Appointments screen when they click on the APPOINTMENT button on the main menu(package private) void
onClickButtonOpen(javafx.event.ActionEvent event)
Handler for the GET CUSTOMER DETAIL button.(package private) void
onClickCustomers(javafx.event.ActionEvent event)
Navigates the user to the Customers screen when they click on the CUSTOMER button on the main menu(package private) void
onClickCustomerSearch(javafx.event.ActionEvent event)
(package private) void
onClickLogOut(javafx.event.ActionEvent event)
Navigates the user to the Login page where they are automatically logged out, when they click on the LOGOUT button on the main menu.(package private) void
onClickOverview(javafx.event.ActionEvent event)
Navigates the user to the Overview page, when they click on the OVERVIEW button on the main menu.(package private) void
onClickReports(javafx.event.ActionEvent event)
Navigates the user to the Reports page, when they click on the REPORTS button on the main menu.(package private) void
onClickTableItem(javafx.scene.input.MouseEvent event)
-
-
-
Field Detail
-
stage
javafx.stage.Stage stage
-
scene
javafx.scene.Parent scene
-
buttonAddNewCustomer
private javafx.scene.control.Button buttonAddNewCustomer
-
buttonOverview
private javafx.scene.control.Button buttonOverview
-
buttonCustomers
private javafx.scene.control.Button buttonCustomers
-
buttonAppointments
private javafx.scene.control.Button buttonAppointments
-
buttonReports
private javafx.scene.control.Button buttonReports
-
buttonLogout
private javafx.scene.control.Button buttonLogout
-
textfieldSearch
private javafx.scene.control.TextField textfieldSearch
-
buttonSearch
private javafx.scene.control.Button buttonSearch
-
buttonOpen
private javafx.scene.control.Button buttonOpen
-
tableAllCustomers
private javafx.scene.control.TableView<Customer> tableAllCustomers
-
labelCustomerID
private javafx.scene.control.TableColumn<Customer,java.lang.Integer> labelCustomerID
-
labelName
private javafx.scene.control.TableColumn<Customer,java.lang.String> labelName
-
labelAddress
private javafx.scene.control.TableColumn<Customer,java.lang.String> labelAddress
-
labelPostalCode
private javafx.scene.control.TableColumn<Customer,java.lang.String> labelPostalCode
-
labelPhoneNumber
private javafx.scene.control.TableColumn<Customer,java.lang.String> labelPhoneNumber
-
labelCountry
private javafx.scene.control.TableColumn<Customer,java.lang.Integer> labelCountry
-
labelDivisionID
private javafx.scene.control.TableColumn<Customer,java.lang.Integer> labelDivisionID
-
labelNameSelector
private javafx.scene.control.Label labelNameSelector
-
-
Method Detail
-
onClickCustomerSearch
void onClickCustomerSearch(javafx.event.ActionEvent event)
-
onClickAddNewCustomer
void onClickAddNewCustomer(javafx.event.ActionEvent event) throws java.io.IOException
Loads the Add customer screen when the ADD CUSTOMER button is clicked.- Parameters:
event
-- Throws:
java.io.IOException
-
onClickAppointments
void onClickAppointments(javafx.event.ActionEvent event) throws java.io.IOException
Navigates the user to the Appointments screen when they click on the APPOINTMENT button on the main menu- Parameters:
event
-- Throws:
java.io.IOException
-
onClickCustomers
void onClickCustomers(javafx.event.ActionEvent event) throws java.io.IOException
Navigates the user to the Customers screen when they click on the CUSTOMER button on the main menu- Parameters:
event
-- Throws:
java.io.IOException
-
onClickLogOut
void onClickLogOut(javafx.event.ActionEvent event) throws java.io.IOException
Navigates the user to the Login page where they are automatically logged out, when they click on the LOGOUT button on the main menu. They can choose to either login again, or exit the application from the login screen.- Parameters:
event
-- Throws:
java.io.IOException
-
onClickOverview
void onClickOverview(javafx.event.ActionEvent event) throws java.io.IOException
Navigates the user to the Overview page, when they click on the OVERVIEW button on the main menu.- Parameters:
event
-- Throws:
java.io.IOException
-
onClickReports
void onClickReports(javafx.event.ActionEvent event) throws java.io.IOException
Navigates the user to the Reports page, when they click on the REPORTS button on the main menu.- Parameters:
event
-- Throws:
java.io.IOException
-
onClickTableItem
void onClickTableItem(javafx.scene.input.MouseEvent event) throws java.io.IOException
- Throws:
java.io.IOException
-
onClickButtonOpen
void onClickButtonOpen(javafx.event.ActionEvent event) throws java.io.IOException
Handler for the GET CUSTOMER DETAIL button. Validates that a customer has been selected, passes the customer object to the Customer Modify screen, and loads it.- Parameters:
event
-- Throws:
java.io.IOException
-
initialize
public void initialize(java.net.URL url, java.util.ResourceBundle resourceBundle)
Initializes the Customers Overview Controller- Specified by:
initialize
in interfacejavafx.fxml.Initializable
- Parameters:
url
-resourceBundle
-
-
-