diff --git a/db/nursingHome.db b/db/nursingHome.db index 0cdc030..402e5b3 100644 Binary files a/db/nursingHome.db and b/db/nursingHome.db differ diff --git a/src/main/java/de/hitec/nhplus/nurse/LockedNurseController.java b/src/main/java/de/hitec/nhplus/nurse/LockedNurseController.java index 0f1d932..e722b3e 100644 --- a/src/main/java/de/hitec/nhplus/nurse/LockedNurseController.java +++ b/src/main/java/de/hitec/nhplus/nurse/LockedNurseController.java @@ -109,7 +109,6 @@ public class LockedNurseController { readAllAndShowInTableView(); } - @FXML public void handleMouseClick() { Nurse nurse = tableView.getSelectionModel().getSelectedItem(); @@ -137,5 +136,4 @@ public class LockedNurseController { } readAllAndShowInTableView(); } - } diff --git a/src/main/java/de/hitec/nhplus/treatment/AllTreatmentController.java b/src/main/java/de/hitec/nhplus/treatment/AllTreatmentController.java index 055c4be..4d97ff0 100644 --- a/src/main/java/de/hitec/nhplus/treatment/AllTreatmentController.java +++ b/src/main/java/de/hitec/nhplus/treatment/AllTreatmentController.java @@ -322,6 +322,13 @@ public class AllTreatmentController { }catch (SQLException exception){ exception.printStackTrace(); } + if (selectedItem.calculateDeleteDate().isBefore(LocalDate.now())){ + try { + dao.delete(selectedItem.getId()); + } catch (SQLException e) { + throw new RuntimeException(e); + } + } readAllAndShowInTableView(); } diff --git a/src/main/resources/de/hitec/nhplus/main/MainWindowView.fxml b/src/main/resources/de/hitec/nhplus/main/MainWindowView.fxml index fdb8bef..6a81c28 100644 --- a/src/main/resources/de/hitec/nhplus/main/MainWindowView.fxml +++ b/src/main/resources/de/hitec/nhplus/main/MainWindowView.fxml @@ -7,6 +7,8 @@ tabClosingPolicy="UNAVAILABLE" xmlns="http://javafx.com/javafx/17.0.2-ea" xmlns:fx="http://javafx.com/fxml/1" + minWidth="1200" + minHeight="700" fx:controller="de.hitec.nhplus.main.MainWindowController" > diff --git a/src/main/resources/de/hitec/nhplus/nurse/AllNurseView.fxml b/src/main/resources/de/hitec/nhplus/nurse/AllNurseView.fxml index 10b589a..27c9cea 100644 --- a/src/main/resources/de/hitec/nhplus/nurse/AllNurseView.fxml +++ b/src/main/resources/de/hitec/nhplus/nurse/AllNurseView.fxml @@ -17,6 +17,7 @@ diff --git a/src/main/resources/de/hitec/nhplus/treatment/LockedTreatmentView.fxml b/src/main/resources/de/hitec/nhplus/treatment/LockedTreatmentView.fxml index 2680436..1e943d5 100644 --- a/src/main/resources/de/hitec/nhplus/treatment/LockedTreatmentView.fxml +++ b/src/main/resources/de/hitec/nhplus/treatment/LockedTreatmentView.fxml @@ -21,7 +21,7 @@