Class AppointmentUserController

java.lang.Object
com.ehealthsystem.appointment.AppointmentUserController
All Implemented Interfaces:
javafx.fxml.Initializable

public class AppointmentUserController extends Object implements javafx.fxml.Initializable
Method for loading the user information for the appointment creation
  • Field Details

    • usernameLabel

      javafx.scene.control.Label usernameLabel
      attributes with a fx:id assigned in the view
    • emailLabel

      javafx.scene.control.Label emailLabel
    • firstNameLabel

      javafx.scene.control.Label firstNameLabel
    • lastNameLabel

      javafx.scene.control.Label lastNameLabel
    • streetLabel

      javafx.scene.control.Label streetLabel
    • houseNumberLabel

      javafx.scene.control.Label houseNumberLabel
    • zipCodeLabel

      javafx.scene.control.Label zipCodeLabel
    • birthdayLabel

      javafx.scene.control.Label birthdayLabel
    • genderLabel

      javafx.scene.control.Label genderLabel
    • insuranceNameLabel

      javafx.scene.control.Label insuranceNameLabel
    • privateInsuranceLabel

      javafx.scene.control.Label privateInsuranceLabel
    • cancelButton

      javafx.scene.control.Button cancelButton
    • progressBar

      javafx.scene.control.ProgressBar progressBar
  • Constructor Details

    • AppointmentUserController

      public AppointmentUserController()
  • Method Details

    • initialize

      public void initialize(URL url, ResourceBundle resourceBundle)
      First method called when scene is switched. Used to load the user information
      Specified by:
      initialize in interface javafx.fxml.Initializable
      Parameters:
      url -
      resourceBundle -
    • handleCancelButton

      public void handleCancelButton(javafx.event.ActionEvent event) throws IOException
      Switch scene to primary
      Parameters:
      event - event triggered when cancel button is pressed
      Throws:
      IOException - if the FXMLLoader can't find .fxml file
    • handleContinueButton

      public void handleContinueButton(javafx.event.ActionEvent event) throws IOException
      Switch scene to next appointment view
      Parameters:
      event -
      Throws:
      IOException
    • loadUserDetails

      public void loadUserDetails()
      Load user information when button is pressed
    • loadUsername

      private void loadUsername(String username)
      Set Username Text Field to user information in DB
      Parameters:
      username - the username of the user logged in
    • loadEmail

      private void loadEmail(String email)
      Set Email Text Field to user information in DB
      Parameters:
      email - the email of the user logged in
    • loadFirstName

      private void loadFirstName(String firstName)
      Set First Name Text Field to user information in DB
      Parameters:
      firstName - the first name of the user logged in
    • loadLastName

      private void loadLastName(String lastName)
      Set Last Name Text Field to user information in DB
      Parameters:
      lastName - the last name of the user logged in
    • loadStreet

      private void loadStreet(String street)
      Set Street Text Field to user information in DB
      Parameters:
      street - the street of the user logged in
    • loadHouseNo

      private void loadHouseNo(String houseNo)
      Set House Number Text Field to user information in DB
      Parameters:
      houseNo - the house no of the user logged in
    • loadZip

      private void loadZip(String zip)
      Set Zip Text Field to user information in DB
      Parameters:
      zip - the zip code of the user logged in
    • loadBirthday

      private void loadBirthday(LocalDate birthday)
      Set Date Picker to birthday in DB
      Parameters:
      birthday - the birthday of the user logged in
    • loadGender

      private void loadGender(String gender)
      Set Gender Text Field to user information in DB
      Parameters:
      gender - the gender of the user logged in
    • loadInsuranceName

      private void loadInsuranceName(String insuranceName)
      Set the Insurance Name Text Field to user information in the DB
      Parameters:
      insuranceName - the insurance name of the user logged in
    • loadPrivateInsurance

      private void loadPrivateInsurance(boolean privateInsurance)
      Set private insurance Check Box to user information in DB
      Parameters:
      privateInsurance - the insurance type of the user logged in