#24: Javado& Cleanup
This commit is contained in:
parent
0aea0911b4
commit
864fbd37a8
2 changed files with 18 additions and 5 deletions
|
@ -2,6 +2,9 @@ package de.hitec.nhplus.main;
|
||||||
|
|
||||||
import de.hitec.nhplus.Main;
|
import de.hitec.nhplus.Main;
|
||||||
import de.hitec.nhplus.nurse.Nurse;
|
import de.hitec.nhplus.nurse.Nurse;
|
||||||
|
import de.hitec.nhplus.patient.Patient;
|
||||||
|
import de.hitec.nhplus.treatment.Treatment;
|
||||||
|
import de.hitec.nhplus.medication.Medication;
|
||||||
import javafx.fxml.FXML;
|
import javafx.fxml.FXML;
|
||||||
import javafx.fxml.FXMLLoader;
|
import javafx.fxml.FXMLLoader;
|
||||||
import javafx.scene.control.SelectionModel;
|
import javafx.scene.control.SelectionModel;
|
||||||
|
@ -81,7 +84,7 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the patient page into its tab.
|
* Loads the {@link Patient} page into its tab.
|
||||||
*/
|
*/
|
||||||
private void loadPatientPage() {
|
private void loadPatientPage() {
|
||||||
try {
|
try {
|
||||||
|
@ -99,7 +102,7 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the {@link } page into its tab.
|
* Loads the {@link Treatment} page into its tab.
|
||||||
*/
|
*/
|
||||||
private void loadTreatmentsPage() {
|
private void loadTreatmentsPage() {
|
||||||
try {
|
try {
|
||||||
|
@ -117,7 +120,7 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the nurse page into its tab.
|
* Loads the {@link Nurse} page into its tab.
|
||||||
*/
|
*/
|
||||||
private void loadNursePage() {
|
private void loadNursePage() {
|
||||||
SelectionModel<Tab> selectionModel = nurseTabPane.getSelectionModel();
|
SelectionModel<Tab> selectionModel = nurseTabPane.getSelectionModel();
|
||||||
|
@ -166,6 +169,9 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads the {@link Medication} page into its tab.
|
||||||
|
*/
|
||||||
private void loadMedicationPage()
|
private void loadMedicationPage()
|
||||||
{
|
{
|
||||||
SelectionModel<Tab> selectionModel = medicationTabPane.getSelectionModel();
|
SelectionModel<Tab> selectionModel = medicationTabPane.getSelectionModel();
|
||||||
|
@ -179,7 +185,7 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the medication page into its tab.
|
* Loads the {@link Medication} page into its tab.
|
||||||
*/
|
*/
|
||||||
private void loadAvailableMedicationPage() {
|
private void loadAvailableMedicationPage() {
|
||||||
try {
|
try {
|
||||||
|
@ -196,10 +202,14 @@ public class MainWindowController {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads the deprecated {@link Medication} page into its tab.
|
||||||
|
*/
|
||||||
private void loadDeprecatedMedicationPage(){
|
private void loadDeprecatedMedicationPage(){
|
||||||
try {
|
try {
|
||||||
BorderPane deprecatedMedicationPane = FXMLLoader.load(
|
BorderPane deprecatedMedicationPane = FXMLLoader.load(
|
||||||
Objects.requireNonNull(Main.class.getResource("/de/hitec/nhplus/medication/DeprecatedMedicationView.fxml"))
|
Objects.requireNonNull(Main.class.getResource(
|
||||||
|
"/de/hitec/nhplus/medication/DeprecatedMedicationView.fxml"))
|
||||||
);
|
);
|
||||||
deprecatedMedicationPage.getChildren().setAll(deprecatedMedicationPane);
|
deprecatedMedicationPage.getChildren().setAll(deprecatedMedicationPane);
|
||||||
AnchorPane.setTopAnchor(deprecatedMedicationPane, 0d);
|
AnchorPane.setTopAnchor(deprecatedMedicationPane, 0d);
|
||||||
|
|
|
@ -38,6 +38,9 @@ public class DeprecatedMedicationController {
|
||||||
private final ObservableList<Medication> medications = FXCollections.observableArrayList();
|
private final ObservableList<Medication> medications = FXCollections.observableArrayList();
|
||||||
private MedicationDao dao;
|
private MedicationDao dao;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialization method that is called after the binding of all the fields.
|
||||||
|
*/
|
||||||
public void initialize() {
|
public void initialize() {
|
||||||
this.readAllAndShowInTableView();
|
this.readAllAndShowInTableView();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue