From 47fe06a5c3d02b0fcd4567f501d5daba9026b56e Mon Sep 17 00:00:00 2001 From: Alex Date: Sat, 31 Jan 2026 17:52:30 -0700 Subject: [PATCH] Added connection to database - displayed products and suppliers to table but still incomplete --- Petstoredata.sql | 191 ++++++++++++++++-- pom.xml | 6 + src/main/java/module-info.java | 3 +- .../controllers/ProductController.java | 63 +++++- .../controllers/SupplierController.java | 47 ++++- .../petshopdesktop/database/ConnectionDB.java | 45 +++++ .../petshopdesktop/database/ProductDB.java | 42 ++++ .../petshopdesktop/database/SupplierDB.java | 38 ++++ .../petshopdesktop/models/Product.java | 97 +++++++++ .../petshopdesktop/models/Supplier.java | 96 +++++++++ 10 files changed, 594 insertions(+), 34 deletions(-) create mode 100644 src/main/java/org/example/petshopdesktop/database/ConnectionDB.java create mode 100644 src/main/java/org/example/petshopdesktop/database/ProductDB.java create mode 100644 src/main/java/org/example/petshopdesktop/database/SupplierDB.java create mode 100644 src/main/java/org/example/petshopdesktop/models/Product.java create mode 100644 src/main/java/org/example/petshopdesktop/models/Supplier.java diff --git a/Petstoredata.sql b/Petstoredata.sql index 5eb101be..763c21cf 100644 --- a/Petstoredata.sql +++ b/Petstoredata.sql @@ -1,85 +1,236 @@ - DROP DATABASE IF EXISTS Petstoredb; CREATE DATABASE Petstoredb; USE Petstoredb; -INSERT INTO store_location (store_name, address, phone, email) +-- Create Tables + +CREATE TABLE storeLocation ( + storeId INT AUTO_INCREMENT PRIMARY KEY, + storeName VARCHAR(100) NOT NULL, + address VARCHAR(255), + phone VARCHAR(20), + email VARCHAR(100) +); + +CREATE TABLE employee ( + employeeId INT AUTO_INCREMENT PRIMARY KEY, + firstName VARCHAR(50) NOT NULL, + lastName VARCHAR(50) NOT NULL, + email VARCHAR(100), + phone VARCHAR(20), + role VARCHAR(50), + isActive BOOLEAN DEFAULT TRUE +); + +CREATE TABLE employeeStore ( + employeeId INT, + storeId INT, + PRIMARY KEY (employeeId, storeId), + FOREIGN KEY (employeeId) REFERENCES employee(employeeId), + FOREIGN KEY (storeId) REFERENCES storeLocation(storeId) +); + +CREATE TABLE customer ( + customerId INT AUTO_INCREMENT PRIMARY KEY, + firstName VARCHAR(50) NOT NULL, + lastName VARCHAR(50) NOT NULL, + email VARCHAR(100), + phone VARCHAR(20) +); + +CREATE TABLE pet ( + petId INT AUTO_INCREMENT PRIMARY KEY, + petName VARCHAR(50), + petSpecies VARCHAR(50), + petBreed VARCHAR(50), + petAge INT, + petStatus VARCHAR(20), + petPrice DECIMAL(10, 2) +); + +CREATE TABLE adoption ( + adoptionId INT AUTO_INCREMENT PRIMARY KEY, + petId INT, + customerId INT, + adoptionDate DATE, + adoptionStatus VARCHAR(20), + FOREIGN KEY (petId) REFERENCES pet(petId), + FOREIGN KEY (customerId) REFERENCES customer(customerId) +); + +CREATE TABLE supplier ( + supId INT AUTO_INCREMENT PRIMARY KEY, + supCompany VARCHAR(100) NOT NULL, + supContactFirstName VARCHAR(50), + supContactLastName VARCHAR(50), + supEmail VARCHAR(100), + supPhone VARCHAR(20) +); + +CREATE TABLE category ( + categoryId INT AUTO_INCREMENT PRIMARY KEY, + categoryName VARCHAR(100) NOT NULL, + categoryType VARCHAR(50) +); + +CREATE TABLE product ( + prodId INT AUTO_INCREMENT PRIMARY KEY, + prodName VARCHAR(100) NOT NULL, + prodSku VARCHAR(50) UNIQUE, + prodPrice DECIMAL(10, 2), + categoryId INT, + prodDesc TEXT, + FOREIGN KEY (categoryId) REFERENCES category(categoryId) +); + +CREATE TABLE productSupplier ( + supId INT, + prodId INT, + PRIMARY KEY (supId, prodId), + FOREIGN KEY (supId) REFERENCES supplier(supId), + FOREIGN KEY (prodId) REFERENCES product(prodId) +); + +CREATE TABLE inventory ( + inventoryId INT AUTO_INCREMENT PRIMARY KEY, + prodId INT, + quantity INT DEFAULT 0, + FOREIGN KEY (prodId) REFERENCES product(prodId) +); + +CREATE TABLE service ( + serviceId INT AUTO_INCREMENT PRIMARY KEY, + serviceName VARCHAR(100) NOT NULL, + serviceDesc TEXT, + serviceDuration INT, + servicePrice DECIMAL(10, 2) +); + +CREATE TABLE appointment ( + appointmentId INT AUTO_INCREMENT PRIMARY KEY, + serviceId INT, + customerId INT, + appointmentDate DATE, + appointmentTime TIME, + appointmentStatus VARCHAR(20), + FOREIGN KEY (serviceId) REFERENCES service(serviceId), + FOREIGN KEY (customerId) REFERENCES customer(customerId) +); + +CREATE TABLE appointmentPet ( + appointmentId INT, + petId INT, + PRIMARY KEY (appointmentId, petId), + FOREIGN KEY (appointmentId) REFERENCES appointment(appointmentId), + FOREIGN KEY (petId) REFERENCES pet(petId) +); + +CREATE TABLE sale ( + saleId INT AUTO_INCREMENT PRIMARY KEY, + saleDate DATETIME, + totalAmount DECIMAL(10, 2), + paymentMethod VARCHAR(50), + employeeId INT, + storeId INT, + FOREIGN KEY (employeeId) REFERENCES employee(employeeId), + FOREIGN KEY (storeId) REFERENCES storeLocation(storeId) +); + +CREATE TABLE saleItem ( + saleItemId INT AUTO_INCREMENT PRIMARY KEY, + saleId INT, + prodId INT, + quantity INT, + unitPrice DECIMAL(10, 2), + FOREIGN KEY (saleId) REFERENCES sale(saleId), + FOREIGN KEY (prodId) REFERENCES product(prodId) +); + +CREATE TABLE activityLog ( + logId INT AUTO_INCREMENT PRIMARY KEY, + employeeId INT, + activity TEXT, + logTimestamp TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + FOREIGN KEY (employeeId) REFERENCES employee(employeeId) +); + +-- Insert Sample Data + +INSERT INTO storeLocation (storeName, address, phone, email) VALUES ('Downtown Branch', '123 Main St', '123-456-7890', 'downtown@petshop.com'), ('North Branch', '456 North Ave', '987-654-3210', 'north@petshop.com'); - - -INSERT INTO employee (first_name, last_name, email, phone, role, is_active) +INSERT INTO employee (firstName, lastName, email, phone, role, isActive) VALUES ('John', 'Doe', 'john@petshop.com', '111-222-3333', 'Manager', TRUE), ('Sara', 'Smith', 'sara@petshop.com', '444-555-6666', 'Staff', TRUE); -INSERT INTO employee_store (employee_id, store_id) +INSERT INTO employeeStore (employeeId, storeId) VALUES (1, 1), (2, 1), (2, 2); -INSERT INTO customer (first_name, last_name, email, phone) +INSERT INTO customer (firstName, lastName, email, phone) VALUES ('Alex', 'Brown', 'alex@gmail.com', '777-888-9999'), ('Emily', 'Clark', 'emily@gmail.com', '666-555-4444'); -INSERT INTO pet (pet_name, pet_species, pet_breed, pet_age, pet_status, pet_price) +INSERT INTO pet (petName, petSpecies, petBreed, petAge, petStatus, petPrice) VALUES ('Buddy', 'Dog', 'Labrador', 2, 'Available', 500.00), ('Milo', 'Cat', 'Persian', 1, 'Available', 300.00); -INSERT INTO adoption (pet_id, customer_id, adoption_date, adoption_status) +INSERT INTO adoption (petId, customerId, adoptionDate, adoptionStatus) VALUES (1, 1, '2026-01-15', 'Completed'); -INSERT INTO supplier (sup_company, sup_contact_first_name, sup_contact_last_name, sup_email, sup_phone) +INSERT INTO supplier (supCompany, supContactFirstName, supContactLastName, supEmail, supPhone) VALUES ('PetFood Inc', 'Robert', 'King', 'contact@petfood.com', '888-111-2222'); -INSERT INTO category (category_name, category_type) +INSERT INTO category (categoryName, categoryType) VALUES ('Dog Food', 'Product'), ('Cat Toys', 'Product'); -INSERT INTO product (prod_name, prod_sku, prod_price, category_id, prod_desc) +INSERT INTO product (prodName, prodSku, prodPrice, categoryId, prodDesc) VALUES ('Premium Dog Food', 'DF001', 50.00, 1, 'High quality dog food'), ('Cat Toy Ball', 'CT001', 10.00, 2, 'Colorful toy for cats'); -INSERT INTO product_supplier (sup_id, prod_id) +INSERT INTO productSupplier (supId, prodId) VALUES (1, 1), (1, 2); -INSERT INTO inventory (prod_id, quantity) +INSERT INTO inventory (prodId, quantity) VALUES (1, 100), (2, 200); -INSERT INTO service (service_name, service_desc, service_duration, service_price) +INSERT INTO service (serviceName, serviceDesc, serviceDuration, servicePrice) VALUES ('Pet Grooming', 'Full grooming service', 60, 40.00); -INSERT INTO appointment (service_id, customer_id, appointment_date, appointment_time, appointment_status) +INSERT INTO appointment (serviceId, customerId, appointmentDate, appointmentTime, appointmentStatus) VALUES (1, 2, '2026-02-01', '10:30:00', 'Booked'); -INSERT INTO appointment_pet (appointment_id, pet_id) +INSERT INTO appointmentPet (appointmentId, petId) VALUES (1, 2); -INSERT INTO sale (sale_date, total_amount, payment_method, employee_id, store_id) +INSERT INTO sale (saleDate, totalAmount, paymentMethod, employeeId, storeId) VALUES (NOW(), 60.00, 'Card', 2, 1); -INSERT INTO sale_item (sale_id, prod_id, quantity, unit_price) +INSERT INTO saleItem (saleId, prodId, quantity, unitPrice) VALUES (1, 2, 2, 10.00); -INSERT INTO activity_log (employee_id, activity) +INSERT INTO activityLog (employeeId, activity) VALUES (1, 'Created new sale'), (2, 'Booked appointment'); diff --git a/pom.xml b/pom.xml index f068b382..8cb9a1ba 100644 --- a/pom.xml +++ b/pom.xml @@ -38,6 +38,12 @@ ${junit.version} test + + + com.mysql + mysql-connector-j + 9.3.0 + diff --git a/src/main/java/module-info.java b/src/main/java/module-info.java index 88acaa41..4dcea055 100644 --- a/src/main/java/module-info.java +++ b/src/main/java/module-info.java @@ -1,8 +1,9 @@ module org.example.petshopdesktop { requires javafx.controls; requires javafx.fxml; + requires java.sql; - + opens org.example.petshopdesktop.models to javafx.base; opens org.example.petshopdesktop to javafx.fxml; exports org.example.petshopdesktop; exports org.example.petshopdesktop.controllers; diff --git a/src/main/java/org/example/petshopdesktop/controllers/ProductController.java b/src/main/java/org/example/petshopdesktop/controllers/ProductController.java index 27d038e0..3b71614f 100644 --- a/src/main/java/org/example/petshopdesktop/controllers/ProductController.java +++ b/src/main/java/org/example/petshopdesktop/controllers/ProductController.java @@ -1,11 +1,18 @@ package org.example.petshopdesktop.controllers; +import javafx.collections.FXCollections; +import javafx.collections.ObservableList; import javafx.event.ActionEvent; import javafx.fxml.FXML; import javafx.scene.control.Button; import javafx.scene.control.TableColumn; import javafx.scene.control.TableView; import javafx.scene.control.TextField; +import javafx.scene.control.cell.PropertyValueFactory; +import org.example.petshopdesktop.database.ProductDB; +import org.example.petshopdesktop.models.Product; + +import java.sql.SQLException; public class ProductController { @@ -19,29 +26,71 @@ public class ProductController { private Button btnEdit; @FXML - private TableColumn colProductCategory; + private TableColumn colProductCategory; @FXML - private TableColumn colProductDesc; + private TableColumn colProductDesc; @FXML - private TableColumn colProductId; + private TableColumn colProductId; @FXML - private TableColumn colProductName; + private TableColumn colProductName; @FXML - private TableColumn colProductPrice; + private TableColumn colProductPrice; @FXML - private TableColumn colProductSKU; + private TableColumn colProductSKU; @FXML - private TableView tvProducts; + private TableView tvProducts; @FXML private TextField txtSearch; + //data declaration + private ObservableList data = FXCollections.observableArrayList(); //empty + + /** + * Set up the table view for fees and display it when starting up + */ + @FXML + void initialize() { + //set up table columns + colProductId.setCellValueFactory(new PropertyValueFactory("prodId")); + colProductName.setCellValueFactory(new PropertyValueFactory("prodName")); + colProductSKU.setCellValueFactory(new PropertyValueFactory("prodSku")); + colProductPrice.setCellValueFactory(new PropertyValueFactory("prodPrice")); + colProductCategory.setCellValueFactory(new PropertyValueFactory("categoryId")); + colProductDesc.setCellValueFactory(new PropertyValueFactory("prodDesc")); + + displayProducts(); + + //TODO MUST DISPLAY CATEGORY NAME INSTEAD OF ID + + + } + + /** + * Display the products to table view + */ + private void displayProducts(){ + //Erase old content + data.clear(); + + //get Products from database + try{ + data = ProductDB.getProducts(); + } catch (SQLException e) { + throw new RuntimeException(e); + } + + //put data in the table + tvProducts.setItems(data); + } + + @FXML void btnAddClicked(ActionEvent event) { diff --git a/src/main/java/org/example/petshopdesktop/controllers/SupplierController.java b/src/main/java/org/example/petshopdesktop/controllers/SupplierController.java index 409cde3b..07730787 100644 --- a/src/main/java/org/example/petshopdesktop/controllers/SupplierController.java +++ b/src/main/java/org/example/petshopdesktop/controllers/SupplierController.java @@ -1,11 +1,18 @@ package org.example.petshopdesktop.controllers; +import javafx.collections.FXCollections; +import javafx.collections.ObservableList; import javafx.event.ActionEvent; import javafx.fxml.FXML; import javafx.scene.control.Button; import javafx.scene.control.TableColumn; import javafx.scene.control.TableView; import javafx.scene.control.TextField; +import javafx.scene.control.cell.PropertyValueFactory; +import org.example.petshopdesktop.database.SupplierDB; +import org.example.petshopdesktop.models.Supplier; + +import java.sql.SQLException; public class SupplierController { @@ -19,26 +26,54 @@ public class SupplierController { private Button btnEdit; @FXML - private TableColumn colContactPerson; + private TableColumn colContactPerson; @FXML - private TableColumn colSupplierEmail; + private TableColumn colSupplierEmail; @FXML - private TableColumn colSupplierId; + private TableColumn colSupplierId; @FXML - private TableColumn colSupplierName; + private TableColumn colSupplierName; @FXML - private TableColumn colSupplierPhone; + private TableColumn colSupplierPhone; @FXML - private TableView tvSuppliers; + private TableView tvSuppliers; @FXML private TextField txtSearch; + private ObservableList data = FXCollections.observableArrayList(); + + @FXML + void initialize(){ + colSupplierId.setCellValueFactory(new PropertyValueFactory("supId")); + colSupplierName.setCellValueFactory(new PropertyValueFactory("supCompany")); + colContactPerson.setCellValueFactory(new PropertyValueFactory("supContactFirstName")); + colSupplierEmail.setCellValueFactory(new PropertyValueFactory("supEmail")); + colSupplierPhone.setCellValueFactory(new PropertyValueFactory("supPhone")); + + displaySupplier(); + + //TODO MUST DISPLAY FULL NAME INSTEAD OF FIRST NAME ALSO ADD COMMENTS LATER + } + + private void displaySupplier(){ + data.clear(); + + try{ + data = SupplierDB.getSuppliers(); + } catch (SQLException e) { + throw new RuntimeException(e); + } + + tvSuppliers.setItems(data); + } + + @FXML void btnAddClicked(ActionEvent event) { diff --git a/src/main/java/org/example/petshopdesktop/database/ConnectionDB.java b/src/main/java/org/example/petshopdesktop/database/ConnectionDB.java new file mode 100644 index 00000000..2b0bad1d --- /dev/null +++ b/src/main/java/org/example/petshopdesktop/database/ConnectionDB.java @@ -0,0 +1,45 @@ +package org.example.petshopdesktop.database; + +import java.io.FileInputStream; +import java.io.IOException; +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.SQLException; +import java.util.Properties; + +public class ConnectionDB { + /** + * Method to try and connect to the database sing cnnection.properties located in the + * root of C drive + * @return Connection to the database + */ + public static Connection getConnection(){ + String url = ""; + String user = ""; + String password = ""; + + try{ + //Read connection.properties file + FileInputStream fis = new FileInputStream("c:\\connectionpetstore.properties"); //location of connection can be changed here + Properties prop = new Properties(); + prop.load(fis); + url = prop.getProperty("url"); + user = prop.getProperty("user"); + password = prop.getProperty("password"); + } + catch(IOException e){ + throw new RuntimeException("Problem with reading connection info: "+e.getMessage()); + } + + Connection conn = null; + + try{ + //try to get connection with the data taken from connection.properties + conn = DriverManager.getConnection(url,user,password); + return conn; + } + catch (SQLException e) { + throw new RuntimeException("Problem with database connection: "+e.getMessage()); + } + } +} diff --git a/src/main/java/org/example/petshopdesktop/database/ProductDB.java b/src/main/java/org/example/petshopdesktop/database/ProductDB.java new file mode 100644 index 00000000..d113d679 --- /dev/null +++ b/src/main/java/org/example/petshopdesktop/database/ProductDB.java @@ -0,0 +1,42 @@ +package org.example.petshopdesktop.database; + +import javafx.collections.FXCollections; +import javafx.collections.ObservableList; +import org.example.petshopdesktop.models.Product; + +import java.io.FileInputStream; +import java.io.IOException; +import java.sql.*; +import java.util.Properties; + +/** + * A class containing all the methods relating to CRUD on Products table + */ +public class ProductDB { + + public static ObservableList getProducts() throws SQLException{ + //Connect to the database + ObservableList products = FXCollections.observableArrayList(); + Connection conn = ConnectionDB.getConnection(); + + //Execute Query + Statement stmt = conn.createStatement(); + ResultSet rs = stmt.executeQuery("SELECT * FROM product"); + + //While there is still data add products to the list + while(rs.next()){ + Product product = new Product( + rs.getInt(1), + rs.getString(2), + rs.getString(3), + rs.getDouble(4), + rs.getInt(5), + rs.getString(6)); + products.add(product); + } + + //close connection and return products + conn.close(); + return products; + } +} diff --git a/src/main/java/org/example/petshopdesktop/database/SupplierDB.java b/src/main/java/org/example/petshopdesktop/database/SupplierDB.java new file mode 100644 index 00000000..55426d3d --- /dev/null +++ b/src/main/java/org/example/petshopdesktop/database/SupplierDB.java @@ -0,0 +1,38 @@ +package org.example.petshopdesktop.database; + +import javafx.collections.FXCollections; +import javafx.collections.ObservableList; +import org.example.petshopdesktop.models.Product; +import org.example.petshopdesktop.models.Supplier; + +import java.sql.Connection; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Statement; + +public class SupplierDB { + public static ObservableList getSuppliers() throws SQLException { + //Connect to the database + ObservableList suppliers = FXCollections.observableArrayList(); + Connection conn = ConnectionDB.getConnection(); + + //Execute Query + Statement stmt = conn.createStatement(); + ResultSet rs = stmt.executeQuery("SELECT * FROM supplier"); + + //While there is still data add products to the list + while(rs.next()){ + Supplier supplier = new Supplier( + rs.getInt(1), + rs.getString(2), + rs.getString(3), + rs.getString(4), + rs.getString(5), + rs.getString(6)); + suppliers.add(supplier); + } + + conn.close(); + return suppliers; + } +} diff --git a/src/main/java/org/example/petshopdesktop/models/Product.java b/src/main/java/org/example/petshopdesktop/models/Product.java new file mode 100644 index 00000000..62217315 --- /dev/null +++ b/src/main/java/org/example/petshopdesktop/models/Product.java @@ -0,0 +1,97 @@ +package org.example.petshopdesktop.models; + +import javafx.beans.property.SimpleDoubleProperty; +import javafx.beans.property.SimpleIntegerProperty; +import javafx.beans.property.SimpleStringProperty; + +public class Product { + public SimpleIntegerProperty prodId; + public SimpleStringProperty prodName; + public SimpleStringProperty prodSku; + public SimpleDoubleProperty prodPrice; + public SimpleIntegerProperty categoryId; + public SimpleStringProperty prodDesc; + + //constructor + public Product(int prodId, String prodName, String prodSku, double prodPrice, int categoryId, String prodDesc) { + this.prodId = new SimpleIntegerProperty(prodId); + this.prodName = new SimpleStringProperty(prodName); + this.prodSku = new SimpleStringProperty(prodSku); + this.prodPrice = new SimpleDoubleProperty(prodPrice); + this.categoryId = new SimpleIntegerProperty(categoryId); + this.prodDesc = new SimpleStringProperty(prodDesc); + } + + //getter and setters + public int getProdId() { + return prodId.get(); + } + + public SimpleIntegerProperty prodIdProperty() { + return prodId; + } + + public void setProdId(int prodId) { + this.prodId.set(prodId); + } + + public String getProdName() { + return prodName.get(); + } + + public SimpleStringProperty prodNameProperty() { + return prodName; + } + + public void setProdName(String prodName) { + this.prodName.set(prodName); + } + + public String getProdSku() { + return prodSku.get(); + } + + public SimpleStringProperty prodSkuProperty() { + return prodSku; + } + + public void setProdSku(String prodSku) { + this.prodSku.set(prodSku); + } + + public double getProdPrice() { + return prodPrice.get(); + } + + public SimpleDoubleProperty prodPriceProperty() { + return prodPrice; + } + + public void setProdPrice(double prodPrice) { + this.prodPrice.set(prodPrice); + } + + public int getCategoryId() { + return categoryId.get(); + } + + public SimpleIntegerProperty categoryIdProperty() { + return categoryId; + } + + public void setCategoryId(int categoryId) { + this.categoryId.set(categoryId); + } + + public String getProdDesc() { + return prodDesc.get(); + } + + public SimpleStringProperty prodDescProperty() { + return prodDesc; + } + + public void setProdDesc(String prodDesc) { + this.prodDesc.set(prodDesc); + } +} diff --git a/src/main/java/org/example/petshopdesktop/models/Supplier.java b/src/main/java/org/example/petshopdesktop/models/Supplier.java new file mode 100644 index 00000000..5822a977 --- /dev/null +++ b/src/main/java/org/example/petshopdesktop/models/Supplier.java @@ -0,0 +1,96 @@ +package org.example.petshopdesktop.models; + +import javafx.beans.property.SimpleIntegerProperty; +import javafx.beans.property.SimpleStringProperty; + +public class Supplier { + SimpleIntegerProperty supId; + SimpleStringProperty supCompany; + SimpleStringProperty supContactFirstName; + SimpleStringProperty supContactLastName; + SimpleStringProperty supEmail; + SimpleStringProperty supPhone; + + //constructor + public Supplier(int supId, String supCompany, String supContactFirstName, String supContactLastName, String supEmail, String supPhone) { + this.supId = new SimpleIntegerProperty(supId); + this.supCompany = new SimpleStringProperty(supCompany); + this.supContactFirstName = new SimpleStringProperty(supContactFirstName); + this.supContactLastName = new SimpleStringProperty(supContactLastName); + this.supEmail = new SimpleStringProperty(supEmail); + this.supPhone = new SimpleStringProperty(supPhone); + } + + //getter and setter + public int getSupId() { + return supId.get(); + } + + public SimpleIntegerProperty supIdProperty() { + return supId; + } + + public void setSupId(int supId) { + this.supId.set(supId); + } + + public String getSupCompany() { + return supCompany.get(); + } + + public SimpleStringProperty supCompanyProperty() { + return supCompany; + } + + public void setSupCompany(String supCompany) { + this.supCompany.set(supCompany); + } + + public String getSupContactFirstName() { + return supContactFirstName.get(); + } + + public SimpleStringProperty supContactFirstNameProperty() { + return supContactFirstName; + } + + public void setSupContactFirstName(String supContactFirstName) { + this.supContactFirstName.set(supContactFirstName); + } + + public String getSupContactLastName() { + return supContactLastName.get(); + } + + public SimpleStringProperty supContactLastNameProperty() { + return supContactLastName; + } + + public void setSupContactLastName(String supContactLastName) { + this.supContactLastName.set(supContactLastName); + } + + public String getSupEmail() { + return supEmail.get(); + } + + public SimpleStringProperty supEmailProperty() { + return supEmail; + } + + public void setSupEmail(String supEmail) { + this.supEmail.set(supEmail); + } + + public String getSupPhone() { + return supPhone.get(); + } + + public SimpleStringProperty supPhoneProperty() { + return supPhone; + } + + public void setSupPhone(String supPhone) { + this.supPhone.set(supPhone); + } +}