├── src
└── main
│ ├── resources
│ ├── styles
│ │ ├── Styles.css
│ │ ├── chart.css
│ │ ├── tableAlign.css
│ │ ├── progressIndicator.css
│ │ ├── pagination.css
│ │ ├── hiddenTabs.css
│ │ ├── header.css
│ │ ├── tableHeader.css
│ │ ├── message.css
│ │ ├── warning.css
│ │ ├── login.css
│ │ ├── popup.css
│ │ ├── accordian.css
│ │ ├── table.css
│ │ ├── tabbedPane4.css
│ │ ├── tabbedPane.css
│ │ └── tabbedPaneTheme2.css
│ ├── imgs
│ │ ├── bg1.jpg
│ │ ├── bg2.png
│ │ ├── bg3.jpg
│ │ ├── bg4.jpg
│ │ ├── bg5.jpg
│ │ ├── bg6.jpg
│ │ ├── msgread.png
│ │ ├── noUser.png
│ │ ├── profile.png
│ │ ├── refund.png
│ │ ├── msgunread.png
│ │ └── profilePics
│ │ │ ├── p1.png
│ │ │ ├── p2.png
│ │ │ ├── p3.png
│ │ │ ├── user001ProfPic.png
│ │ │ ├── user012ProfPic.png
│ │ │ ├── user016ProfPic.png
│ │ │ ├── user018ProfPic.png
│ │ │ ├── user020ProfPic.png
│ │ │ └── user021ProfPic.png
│ └── fxml
│ │ ├── Popover.fxml
│ │ ├── Error.fxml
│ │ ├── Popover2.fxml
│ │ ├── Warning.fxml
│ │ ├── adminMessage.fxml
│ │ ├── ProgressIndicator.fxml
│ │ ├── CurrentUserSummary.fxml
│ │ ├── AllMessages.fxml
│ │ ├── UserOptionPopOver.fxml
│ │ ├── PrescriptionListPopup.fxml
│ │ ├── PopupAsk.fxml
│ │ ├── Logout.fxml
│ │ ├── LabReportPreview.fxml
│ │ ├── ReadMessage.fxml
│ │ ├── PatientAccountSuccess.fxml
│ │ ├── AppointmentSuccess.fxml
│ │ └── RefundTable.fxml
│ └── java
│ ├── Doctor
│ ├── Appointment.java
│ ├── Availability.java
│ ├── Message.java
│ ├── PopoverController.java
│ └── NewDoctorTimeSlotController.java
│ ├── com
│ └── hms
│ │ └── hms_test_2
│ │ ├── ErrorController.java
│ │ ├── WarningController.java
│ │ ├── SuccessIndicatorController.java
│ │ ├── MainApp.java
│ │ ├── SystemConfiguration.java
│ │ ├── PopupAskController.java
│ │ ├── LogoutController.java
│ │ ├── CurrentUserSummaryController.java
│ │ ├── AllMessages.java
│ │ ├── ReadMessageController.java
│ │ ├── NewMessageController.java
│ │ ├── Validate.java
│ │ └── AllMessagesController.java
│ ├── LabAssistant
│ ├── LabReport.java
│ ├── Prescription.java
│ ├── PrescriptionListController.java
│ └── LabReportPreviewController.java
│ ├── Admin
│ ├── AdminMessageController.java
│ ├── UserAccount.java
│ ├── NewUserController.java
│ ├── UserOptionPopOverController.java
│ └── SysUserController.java
│ ├── Receptionist
│ ├── Popover2Controller.java
│ ├── AppointmentSuccessController.java
│ ├── PatientAccountSuccessController.java
│ ├── DoctorDetail.java
│ └── AllAppointmentsController.java
│ ├── Cashier
│ ├── BillPreviewController.java
│ ├── Refund.java
│ ├── Bill.java
│ └── RefundController.java
│ └── Pharmacist
│ └── Drug.java
├── screenshots
├── screenshots.png
├── componentInteractions.png
└── componentInteractions2.png
├── config.properties
├── .gitignore
├── README.md
└── pom.xml
/src/main/resources/styles/Styles.css:
--------------------------------------------------------------------------------
1 | .button {
2 | -fx-font-weight: bold;
3 | }
4 |
--------------------------------------------------------------------------------
/src/main/resources/styles/chart.css:
--------------------------------------------------------------------------------
1 | .chart-pie-label {
2 | -fx-font-size: 10px ;
3 | }
4 |
--------------------------------------------------------------------------------
/src/main/resources/styles/tableAlign.css:
--------------------------------------------------------------------------------
1 | #history .table-column {
2 | -fx-alignment: CENTER;
3 | }
4 |
--------------------------------------------------------------------------------
/src/main/resources/styles/progressIndicator.css:
--------------------------------------------------------------------------------
1 | #saveSuccess .percentage {
2 | -fx-fill: #ffffff ;
3 | }
4 |
--------------------------------------------------------------------------------
/src/main/resources/styles/pagination.css:
--------------------------------------------------------------------------------
1 |
2 | .pagination {
3 | -fx-page-information-visible:false;
4 | }
5 |
6 |
--------------------------------------------------------------------------------
/screenshots/screenshots.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/screenshots/screenshots.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg1.jpg
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg2.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg3.jpg
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg4.jpg
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg5.jpg
--------------------------------------------------------------------------------
/src/main/resources/imgs/bg6.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/bg6.jpg
--------------------------------------------------------------------------------
/src/main/resources/imgs/msgread.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/msgread.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/noUser.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/noUser.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profile.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profile.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/refund.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/refund.png
--------------------------------------------------------------------------------
/screenshots/componentInteractions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/screenshots/componentInteractions.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/msgunread.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/msgunread.png
--------------------------------------------------------------------------------
/screenshots/componentInteractions2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/screenshots/componentInteractions2.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/p1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/p1.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/p2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/p2.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/p3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/p3.png
--------------------------------------------------------------------------------
/src/main/resources/styles/hiddenTabs.css:
--------------------------------------------------------------------------------
1 | .tab-pane {
2 | -fx-tab-max-height: 0 ;
3 | }
4 | .tab-pane .tab-header-area {
5 | visibility: hidden ;
6 | }
7 |
--------------------------------------------------------------------------------
/src/main/resources/styles/header.css:
--------------------------------------------------------------------------------
1 | .label{
2 | -fx-background-color: #222;
3 | -fx-border-width: 0 0 0 2; -fx-border-color: #222 #222 #080808 #222 ;
4 | }
5 |
--------------------------------------------------------------------------------
/config.properties:
--------------------------------------------------------------------------------
1 | #Database Properties
2 | dbClassName=org.mariadb.jdbc.Driver
3 | connection=jdbc:mysql://127.0.0.1/
4 | user=heshan
5 | password=pass
6 | database=test_HMS2
7 |
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user001ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user001ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user012ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user012ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user016ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user016ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user018ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user018ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user020ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user020ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/imgs/profilePics/user021ProfPic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/stellarloop/Health-Care-Facility/HEAD/src/main/resources/imgs/profilePics/user021ProfPic.png
--------------------------------------------------------------------------------
/src/main/resources/styles/tableHeader.css:
--------------------------------------------------------------------------------
1 | .column-header-background { visibility: hidden; -fx-padding: -1em; }
2 |
3 | .table-row-cell {
4 | -fx-cell-size: 55px;
5 | }
6 |
7 | #reportTable{
8 | -fx-cell-size: 25px;
9 | }
--------------------------------------------------------------------------------
/src/main/resources/styles/message.css:
--------------------------------------------------------------------------------
1 | #borderLeft{
2 | -fx-background-color: #333333;
3 | -fx-border-radius: 0 5 5 0;
4 | -fx-background-insets: 2, 2, 2, 2;
5 | -fx-border-color: #eee;
6 | -fx-border-width: 0 3 3 0;
7 | }
8 |
9 | #borderRight{
10 | -fx-background-color: #333333;
11 | -fx-border-radius: 5 0 0 5;
12 | -fx-background-insets: 2, 2, 2, 2;
13 | -fx-border-color: #eee;
14 | -fx-border-width: 3 0 0 3;
15 | }
16 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Maven target directory
2 | target/
3 |
4 | # Maven Wrapper files (include only the wrapper directory if using Maven Wrapper)
5 | !.mvn/wrapper/
6 | !.mvn/wrapper/*
7 | !.mvn/wrapper/maven-wrapper.properties
8 | !.mvn/wrapper/maven-wrapper.jar
9 | !.mvn/wrapper/maven-wrapper-download-url
10 | .mvn/
11 |
12 | # OS-specific files
13 | .DS_Store
14 | Thumbs.db
15 |
16 | # IDE-specific files
17 | *.iml
18 | .idea/
19 | .vscode/
20 | nbactions.xml
21 | nb-configuration.xml
--------------------------------------------------------------------------------
/src/main/resources/styles/warning.css:
--------------------------------------------------------------------------------
1 | #border{
2 | -fx-border-color: #FF5F6C;
3 | -fx-border-width: 2 2 0 2;
4 | -fx-border-radius: 2 2 2 2;
5 | -fx-background-insets: 0, 1, 2;
6 |
7 | }
8 |
9 | #border2{
10 | -fx-border-color: #FF5F6C;
11 | -fx-border-width: 2 2 0 2;
12 | -fx-border-radius: 2 2 2 2;
13 | -fx-background-insets: 0, 1, 2;
14 | -fx-background-color: #fff;
15 | }
16 |
17 | #iconBox{
18 | -fx-background-color: #FF5F6C;
19 | }
20 | /*
21 | .popover > .border {
22 | -fx-fill: green;
23 | -fx-stroke: red;
24 | -fx-cursor: hand;
25 | -fx-stroke-width: 5;
26 | }
27 | */
28 |
--------------------------------------------------------------------------------
/src/main/resources/styles/login.css:
--------------------------------------------------------------------------------
1 | #background{
2 |
3 | -fx-background-color: #333333;
4 | }
5 |
6 | #loginBox{
7 |
8 | -fx-background-color: #eeeeee;
9 | -fx-border-radius: 5;
10 | -fx-background-insets: 2, 1, 2, 2;
11 | -fx-border-color: #eee;
12 | -fx-border-width: 3 3 3 3;
13 | }
14 |
15 | #borderTop{
16 | -fx-background-color: #333333;
17 | -fx-border-radius: 5;
18 | -fx-background-insets: 2, 1, 2, 2;
19 | -fx-border-color: #eee;
20 | -fx-border-width: 3 0 0 3;
21 | }
22 |
23 | #borderBottom{
24 | -fx-background-color: #333333;
25 | -fx-border-radius: 5;
26 | -fx-background-insets: 2, 1, 2, 2;
27 | -fx-border-color: #eee;
28 | -fx-border-width: 0 3 3 0;
29 | }
--------------------------------------------------------------------------------
/src/main/java/Doctor/Appointment.java:
--------------------------------------------------------------------------------
1 | package Doctor;
2 |
3 | import java.util.GregorianCalendar;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Appointment {
10 |
11 | GregorianCalendar startTime;
12 | GregorianCalendar endTime;
13 |
14 | public Appointment(GregorianCalendar start, GregorianCalendar end) {
15 | setStartTime(start);
16 | setEndTime(end);
17 | }
18 |
19 | public GregorianCalendar getStartTime() {
20 | return startTime;
21 | }
22 |
23 | public void setStartTime(GregorianCalendar startTime) {
24 | this.startTime = startTime;
25 | }
26 |
27 | public GregorianCalendar getEndTime() {
28 | return endTime;
29 | }
30 |
31 | public void setEndTime(GregorianCalendar endTime) {
32 | this.endTime = endTime;
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/ErrorController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import java.io.IOException;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.control.Label;
7 | import javafx.scene.layout.AnchorPane;
8 |
9 | /**
10 | *
11 | * @author heshan
12 | */
13 | public class ErrorController extends AnchorPane {
14 |
15 | public ErrorController() {
16 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/Error.fxml"));
17 | fxmlLoader.setRoot(this);
18 | fxmlLoader.setController(this);
19 |
20 | try {
21 | fxmlLoader.load();
22 | } catch (IOException exception) {
23 | throw new RuntimeException(exception);
24 | }
25 | }
26 |
27 | @FXML
28 | Label formatLabel;
29 |
30 | public void addMessage(String message) {
31 | formatLabel.setText(message);
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/WarningController.java:
--------------------------------------------------------------------------------
1 |
2 | package com.hms.hms_test_2;
3 |
4 | import java.io.IOException;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.scene.control.Label;
8 | import javafx.scene.layout.AnchorPane;
9 |
10 | /**
11 | *
12 | * @author heshan
13 | */
14 | public class WarningController extends AnchorPane {
15 |
16 | public WarningController() {
17 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/Warning.fxml"));
18 | fxmlLoader.setRoot(this);
19 | fxmlLoader.setController(this);
20 |
21 | try {
22 | fxmlLoader.load();
23 | } catch (IOException exception) {
24 | throw new RuntimeException(exception);
25 | }
26 | }
27 |
28 | @FXML
29 | Label formatLabel;
30 |
31 | public void addMessage(String message) {
32 |
33 | formatLabel.setText("Format: " + message);
34 |
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/src/main/java/LabAssistant/LabReport.java:
--------------------------------------------------------------------------------
1 | package LabAssistant;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class LabReport {
10 | private final SimpleStringProperty constituent = new SimpleStringProperty("");
11 | private final SimpleStringProperty result = new SimpleStringProperty("");
12 |
13 | public LabReport() {
14 | this("", "");
15 | }
16 |
17 | public LabReport(String constituent, String result) {
18 | setConstituent(constituent);
19 | setResult(result);
20 | }
21 |
22 | public String getConstituent() {
23 | return constituent.get();
24 | }
25 |
26 | public void setConstituent(String value) {
27 | constituent.set(value);
28 | }
29 |
30 | public String getResult() {
31 | return result.get();
32 | }
33 |
34 | public void setResult(String value) {
35 | result.set(value);
36 | }
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/java/Admin/AdminMessageController.java:
--------------------------------------------------------------------------------
1 | package Admin;
2 |
3 | import java.io.IOException;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.control.TextArea;
7 | import javafx.scene.control.TextField;
8 | import javafx.scene.layout.AnchorPane;
9 |
10 | /**
11 | *
12 | * @author heshan
13 | */
14 | public class AdminMessageController extends AnchorPane {
15 |
16 | public AdminMessageController() {
17 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/adminMessage.fxml"));
18 | fxmlLoader.setRoot(this);
19 | fxmlLoader.setController(this);
20 |
21 | try {
22 | fxmlLoader.load();
23 | } catch (IOException exception) {
24 | throw new RuntimeException(exception);
25 | }
26 | }
27 |
28 | @FXML
29 | TextField receiver;
30 | @FXML
31 | TextArea message;
32 |
33 | public void setPaceholders() {
34 | receiver.setPromptText("Receiver");
35 | message.setPromptText("Type Message Here");
36 | }
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/Popover.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/SuccessIndicatorController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import java.io.IOException;
4 | import javafx.event.ActionEvent;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.scene.control.Button;
8 | import javafx.scene.layout.AnchorPane;
9 | import javafx.stage.Stage;
10 |
11 | public class SuccessIndicatorController extends AnchorPane {
12 |
13 | public SuccessIndicatorController() {
14 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/ProgressIndicator.fxml"));
15 | fxmlLoader.setRoot(this);
16 | fxmlLoader.setController(this);
17 |
18 | try {
19 | fxmlLoader.load();
20 | } catch (IOException exception) {
21 | throw new RuntimeException(exception);
22 | }
23 | }
24 |
25 | @FXML
26 | public Button saveSuccess;
27 |
28 | @FXML
29 | public void saveSuccessExit(ActionEvent event) {
30 |
31 | Stage stage;
32 | if (event.getSource() == saveSuccess) {
33 | stage = (Stage) saveSuccess.getScene().getWindow();
34 | stage.close();
35 | }
36 | }
37 | }
--------------------------------------------------------------------------------
/src/main/java/Doctor/Availability.java:
--------------------------------------------------------------------------------
1 | package Doctor;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Availability {
10 | private final SimpleStringProperty date = new SimpleStringProperty("");
11 | private final SimpleStringProperty time = new SimpleStringProperty("");
12 | private final SimpleStringProperty id = new SimpleStringProperty("");
13 |
14 | public Availability() {
15 | this("", "", "");
16 | }
17 |
18 | public Availability(String date, String time, String id) {
19 | setDate(date);
20 | setTime(time);
21 | setId(id);
22 | }
23 |
24 | public String getDate() {
25 | return date.get();
26 | }
27 |
28 | public void setDate(String value) {
29 | date.set(value);
30 | }
31 |
32 | public String getTime() {
33 | return time.get();
34 | }
35 |
36 | public void setTime(String value) {
37 | time.set(value);
38 | }
39 |
40 | public String getId() {
41 | return id.get();
42 | }
43 |
44 | public void setId(String value) {
45 | id.set(value);
46 | }
47 |
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/Receptionist/Popover2Controller.java:
--------------------------------------------------------------------------------
1 | package Receptionist;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import javafx.collections.ObservableList;
8 | import javafx.scene.layout.AnchorPane;
9 | import javafx.stage.Stage;
10 |
11 | /**
12 | *
13 | * @author heshan
14 | */
15 | public class Popover2Controller extends AnchorPane {
16 |
17 | public Popover2Controller() {
18 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/Popover2.fxml"));
19 | fxmlLoader.setRoot(this);
20 | fxmlLoader.setController(this);
21 |
22 | try {
23 | fxmlLoader.load();
24 | } catch (IOException exception) {
25 | throw new RuntimeException(exception);
26 | }
27 | }
28 |
29 | @FXML
30 | private ListView daysList;
31 |
32 | public void fillDaysList(ObservableList items) {
33 | daysList.setItems(items);
34 | }
35 |
36 | @FXML
37 | public void closePopUp() {
38 | Stage stage = (Stage) daysList.getScene().getWindow();
39 | stage.close();
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/src/main/java/Admin/UserAccount.java:
--------------------------------------------------------------------------------
1 | package Admin;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class UserAccount {
10 | private final SimpleStringProperty user = new SimpleStringProperty("");
11 | private final SimpleStringProperty lastLogin = new SimpleStringProperty("");
12 | private final SimpleStringProperty online = new SimpleStringProperty("");
13 |
14 | public UserAccount() {
15 | this("", "", "");
16 | }
17 |
18 | public UserAccount(String user, String lastLogin, String online) {
19 | setUser(user);
20 | setLastLogin(lastLogin);
21 | setOnline(online);
22 | }
23 |
24 | public void setUser(String val) {
25 | user.set(val);
26 | }
27 |
28 | public void setLastLogin(String val) {
29 | lastLogin.set(val);
30 | }
31 |
32 | public void setOnline(String val) {
33 | online.set(val);
34 | }
35 |
36 | public String getUser() {
37 | return user.get();
38 | }
39 |
40 | public String getLastLogin() {
41 | return lastLogin.get();
42 | }
43 |
44 | public String getOnline() {
45 | return online.get();
46 | }
47 |
48 | }
49 |
--------------------------------------------------------------------------------
/src/main/java/Doctor/Message.java:
--------------------------------------------------------------------------------
1 | package Doctor;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Message {
10 | private final SimpleStringProperty sender = new SimpleStringProperty("");
11 | private final SimpleStringProperty subject = new SimpleStringProperty("");
12 | private final SimpleStringProperty message = new SimpleStringProperty("");
13 |
14 | public Message() {
15 | this("", "", "");
16 | }
17 |
18 | public Message(String sender, String subject, String message) {
19 | setSender(sender);
20 | setSubject(subject);
21 | setMessage(message);
22 | }
23 |
24 | public String getSender() {
25 | return sender.get();
26 | }
27 |
28 | public void setSender(String value) {
29 | sender.set(value);
30 | }
31 |
32 | public String getSubject() {
33 | return subject.get();
34 | }
35 |
36 | public void setSubject(String value) {
37 | subject.set(value);
38 | }
39 |
40 | public String getMessage() {
41 | return message.get();
42 | }
43 |
44 | public void setMessage(String value) {
45 | message.set(value);
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/Error.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/MainApp.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.application.Application;
4 | import javafx.geometry.Rectangle2D;
5 | import javafx.scene.Scene;
6 | import javafx.stage.Screen;
7 | import javafx.stage.Stage;
8 | import javafx.stage.StageStyle;
9 |
10 | public class MainApp extends Application {
11 |
12 | @Override
13 | public void start(Stage stage) throws Exception {
14 | LoginController login = new LoginController();
15 | stage.setScene(new Scene(login));
16 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
17 | // set Stage boundaries to visible bounds of the main screen
18 | stage.setX(primaryScreenBounds.getMinX());
19 | stage.setY(primaryScreenBounds.getMinY());
20 | stage.setWidth(primaryScreenBounds.getWidth());
21 | stage.setHeight(primaryScreenBounds.getHeight());
22 | stage.initStyle(StageStyle.UNDECORATED);
23 | stage.show();
24 | }
25 |
26 | /**
27 | * The main() method is ignored in correctly deployed JavaFX application.
28 | * main() serves only as fallback in case the application can not be
29 | * launched through deployment artifacts, e.g., in IDEs with limited FX
30 | * support. NetBeans ignores main().
31 | *
32 | * @param args the command line arguments
33 | */
34 | public static void main(String[] args) {
35 | launch(args);
36 | }
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/Popover2.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/src/main/java/Admin/NewUserController.java:
--------------------------------------------------------------------------------
1 | package Admin;
2 |
3 | import java.io.IOException;
4 | import javafx.event.ActionEvent;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.scene.control.Button;
8 | import javafx.scene.control.TextField;
9 | import javafx.scene.layout.AnchorPane;
10 | import javafx.stage.Stage;
11 |
12 | /**
13 | *
14 | * @author heshan
15 | */
16 | class NewUserController extends AnchorPane {
17 |
18 | public NewUserController() {
19 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/NewUser.fxml"));
20 | fxmlLoader.setRoot(this);
21 | fxmlLoader.setController(this);
22 |
23 | try {
24 | fxmlLoader.load();
25 | } catch (IOException exception) {
26 | throw new RuntimeException(exception);
27 | }
28 | }
29 |
30 | @FXML
31 | private TextField userName;
32 | @FXML
33 | private TextField userid;
34 | @FXML
35 | private TextField password;
36 |
37 | public void loadData(String username, String id, String pass) {
38 | userName.setText(username);
39 | userid.setText(id);
40 | password.setText(pass);
41 | }
42 |
43 | @FXML
44 | private Button closeUser;
45 |
46 | @FXML
47 | private void closeUserWindow(ActionEvent event) {
48 |
49 | Stage stage;
50 | if (event.getSource() == closeUser) {
51 | stage = (Stage) closeUser.getScene().getWindow();
52 | stage.close();
53 | }
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/LabAssistant/Prescription.java:
--------------------------------------------------------------------------------
1 | package LabAssistant;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Prescription {
10 | private final SimpleStringProperty prescID = new SimpleStringProperty("");
11 | private final SimpleStringProperty date = new SimpleStringProperty("");
12 | private final SimpleStringProperty doctor = new SimpleStringProperty("");
13 | private final SimpleStringProperty prescription = new SimpleStringProperty("");
14 |
15 | public Prescription() {
16 | this("", "", "", "");
17 | }
18 |
19 | public Prescription(String prescID, String date, String doctor, String prescription) {
20 | setPrescID(prescID);
21 | setDate(date);
22 | setDoctor(doctor);
23 | setPrescription(prescription);
24 | }
25 |
26 | public String getPrescID() {
27 | return prescID.get();
28 | }
29 |
30 | public void setPrescID(String value) {
31 | prescID.set(value);
32 | }
33 |
34 | public String getDate() {
35 | return date.get();
36 | }
37 |
38 | public void setDate(String value) {
39 | date.set(value);
40 | }
41 |
42 | public String getDoctor() {
43 | return doctor.get();
44 | }
45 |
46 | public void setDoctor(String value) {
47 | doctor.set(value);
48 | }
49 |
50 | public String getPrescription() {
51 | return prescription.get();
52 | }
53 |
54 | public void setPrescription(String value) {
55 | prescription.set(value);
56 | }
57 | }
58 |
--------------------------------------------------------------------------------
/src/main/java/Admin/UserOptionPopOverController.java:
--------------------------------------------------------------------------------
1 | package Admin;
2 |
3 | import java.io.IOException;
4 | import javafx.fxml.FXML;
5 | import javafx.fxml.FXMLLoader;
6 | import javafx.scene.chart.AreaChart;
7 | import javafx.scene.chart.NumberAxis;
8 | import javafx.scene.chart.XYChart;
9 | import javafx.scene.layout.AnchorPane;
10 |
11 | /**
12 | *
13 | * @author heshan
14 | */
15 | class UserOptionPopOverController extends AnchorPane {
16 |
17 | public UserOptionPopOverController() {
18 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/UserOptionPopOver.fxml"));
19 | fxmlLoader.setRoot(this);
20 | fxmlLoader.setController(this);
21 |
22 | try {
23 | fxmlLoader.load();
24 | } catch (IOException exception) {
25 | throw new RuntimeException(exception);
26 | }
27 | }
28 |
29 | @FXML
30 | private NumberAxis yAxis;
31 | @FXML
32 | private AreaChart onlineChart;
33 |
34 | /**
35 | * Area chart Fill info about the users that currently logged in
36 | */
37 | @FXML
38 | public void fillAreaChart() {
39 |
40 | XYChart.Series users = new XYChart.Series<>();
41 | users.setName("Users");
42 | users.getData().add(new XYChart.Data<>("8.00", 0));
43 | users.getData().add(new XYChart.Data<>("8.15", 1));
44 | users.getData().add(new XYChart.Data<>("8.30", 2));
45 | users.getData().add(new XYChart.Data<>("8.45", 1));
46 | users.getData().add(new XYChart.Data<>("9.00", 2));
47 | onlineChart.getData().add(users);
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/src/main/java/Receptionist/AppointmentSuccessController.java:
--------------------------------------------------------------------------------
1 | package Receptionist;
2 |
3 | import java.io.IOException;
4 | import javafx.event.ActionEvent;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.scene.control.*;
8 | import javafx.scene.layout.AnchorPane;
9 | import javafx.stage.Stage;
10 |
11 | public class AppointmentSuccessController extends AnchorPane {
12 |
13 | public AppointmentSuccessController() {
14 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/AppointmentSuccess.fxml"));
15 | fxmlLoader.setRoot(this);
16 | fxmlLoader.setController(this);
17 |
18 | try {
19 | fxmlLoader.load();
20 | } catch (IOException exception) {
21 | throw new RuntimeException(exception);
22 | }
23 | }
24 |
25 | @FXML
26 | private Label patientID;
27 | @FXML
28 | private Label consultant;
29 | @FXML
30 | private Label date;
31 | @FXML
32 | private Label appID;
33 |
34 | public void fillAppointmentData(String patientId, String consult, String appDate, String appId) {
35 | patientID.setText(" " + patientId);
36 | consultant.setText(" " + consult);
37 | date.setText(" " + appDate);
38 | appID.setText(" " + appId);
39 |
40 | }
41 |
42 | @FXML
43 | public Button saveSuccess;
44 |
45 | @FXML
46 | public void saveSuccessExit(ActionEvent event) {
47 |
48 | Stage stage;
49 | if (event.getSource() == saveSuccess) {
50 | stage = (Stage) saveSuccess.getScene().getWindow();
51 | stage.close();
52 | }
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/Warning.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
19 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/src/main/java/Receptionist/PatientAccountSuccessController.java:
--------------------------------------------------------------------------------
1 | package Receptionist;
2 |
3 | import java.io.IOException;
4 | import javafx.event.ActionEvent;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.scene.control.Button;
8 | import javafx.scene.control.Label;
9 | import javafx.scene.layout.AnchorPane;
10 | import javafx.stage.Stage;
11 |
12 | public class PatientAccountSuccessController extends AnchorPane {
13 |
14 | public PatientAccountSuccessController() {
15 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/PatientAccountSuccess.fxml"));
16 | fxmlLoader.setRoot(this);
17 | fxmlLoader.setController(this);
18 |
19 | try {
20 | fxmlLoader.load();
21 | } catch (IOException exception) {
22 | throw new RuntimeException(exception);
23 | }
24 | }
25 |
26 | @FXML
27 | private Label patientID;
28 | @FXML
29 | private Label name;
30 | @FXML
31 | private Label mobile;
32 | @FXML
33 | private Label gender;
34 |
35 | public void fillPatientData(String patientId, String pName, String pAge, String pGender) {
36 | patientID.setText(" " + patientId);
37 | name.setText(" " + pName);
38 | mobile.setText(" " + pAge);
39 | gender.setText(" " + pGender);
40 |
41 | }
42 |
43 | @FXML
44 | public Button saveSuccess;
45 |
46 | @FXML
47 | public void saveSuccessExit(ActionEvent event) {
48 |
49 | Stage stage;
50 | if (event.getSource() == saveSuccess) {
51 | stage = (Stage) saveSuccess.getScene().getWindow();
52 | stage.close();
53 | }
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/SystemConfiguration.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import java.io.FileInputStream;
4 | import java.io.FileOutputStream;
5 | import java.io.IOException;
6 | import java.util.Properties;
7 |
8 | public class SystemConfiguration {
9 |
10 | private static SystemConfiguration instance;
11 | private Properties properties;
12 | private final String configFilePath = "config.properties";
13 |
14 | private SystemConfiguration() {
15 | properties = new Properties();
16 | loadConfig();
17 | }
18 |
19 | public static synchronized SystemConfiguration getInstance() {
20 | if (instance == null) {
21 | instance = new SystemConfiguration();
22 | }
23 | return instance;
24 | }
25 |
26 | private void loadConfig() {
27 | try (FileInputStream fis = new FileInputStream(configFilePath)) {
28 | properties.load(fis);
29 | } catch (IOException e) {
30 | e.printStackTrace();
31 | throw new RuntimeException("Failed to load configuration file.");
32 | }
33 | }
34 |
35 | public synchronized String getConfig(String key) {
36 | return properties.getProperty(key);
37 | }
38 |
39 | public synchronized void updateConfig(String key, String value) {
40 | properties.setProperty(key, value);
41 | }
42 |
43 | public synchronized void saveConfig() {
44 | try (FileOutputStream fos = new FileOutputStream(configFilePath)) {
45 | properties.store(fos, "Updated configuration");
46 | } catch (IOException e) {
47 | e.printStackTrace();
48 | throw new RuntimeException("Failed to save configuration file.");
49 | }
50 | }
51 |
52 | public synchronized void reloadConfig() {
53 | loadConfig();
54 | }
55 | }
--------------------------------------------------------------------------------
/src/main/java/Cashier/BillPreviewController.java:
--------------------------------------------------------------------------------
1 | package Cashier;
2 |
3 | import java.io.IOException;
4 | import javafx.scene.control.Button;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.stage.Stage;
8 | import javafx.scene.control.*;
9 | import javafx.event.ActionEvent;
10 | import javafx.scene.layout.AnchorPane;
11 |
12 | public class BillPreviewController extends AnchorPane {
13 |
14 | public BillPreviewController() {
15 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/BillPreview.fxml"));
16 | fxmlLoader.setRoot(this);
17 | fxmlLoader.setController(this);
18 |
19 | try {
20 | fxmlLoader.load();
21 | } catch (IOException exception) {
22 | throw new RuntimeException(exception);
23 | }
24 | }
25 |
26 | @FXML
27 | public Button saveSuccess;
28 |
29 | @FXML
30 | public void saveSuccessExit(ActionEvent event) {
31 |
32 | Stage stage;
33 | if (event.getSource() == saveSuccess) {
34 | stage = (Stage) saveSuccess.getScene().getWindow();
35 | stage.close();
36 | }
37 | }
38 |
39 | @FXML
40 | private Label name;
41 | @FXML
42 | private Label service;
43 | @FXML
44 | private Label vat;
45 | @FXML
46 | private Label bill;
47 | @FXML
48 | private Label date;
49 | @FXML
50 | private Label billID;
51 |
52 | public void fillBillPreview(String patientName, String serviceFee, String VAT, String billVal, String currDate,
53 | String billId) {
54 | name.setText(" " + patientName);
55 | service.setText(" " + serviceFee);
56 | vat.setText(" " + VAT);
57 | bill.setText(" " + billVal);
58 | date.setText(" " + currDate);
59 | billID.setText(" " + billId);
60 | }
61 |
62 | }
63 |
--------------------------------------------------------------------------------
/src/main/resources/styles/popup.css:
--------------------------------------------------------------------------------
1 | #anchor{
2 | /*-fx-background-color: #eee;*/
3 | -fx-background-color: rgba(0, 0, 0, 0.6);
4 | }
5 |
6 |
7 | #box{
8 | -fx-background-color: #eee;
9 | -fx-border-radius: 3;
10 | -fx-background-insets: 2, 1, 2, 2;
11 | /*-fx-background-radius: 3 3 3 3, 3 3 3 3, 3 3 3 3;*/
12 | -fx-text-fill: #333;
13 | -fx-padding: 5 5 5 5;
14 | -fx-border-color: #eee;
15 | -fx-border-width: 3 3 3 3;
16 | /*-fx-background-color: linear-gradient(#0798bc 25%, #ffffff 50%, #0798bc 25%);*/
17 | }
18 |
19 | #box2{
20 | -fx-background-color: #eee;
21 | -fx-border-radius: 3;
22 | -fx-background-insets: 2, 1, 2, 2;
23 | /*-fx-background-radius: 3 3 3 3, 3 3 3 3, 3 3 3 3;*/
24 | -fx-text-fill: #333;
25 | -fx-padding: 5 5 5 5;
26 | -fx-border-color: #999;
27 | -fx-border-width: 1 1 1 1;
28 | /*-fx-background-color: linear-gradient(#0798bc 25%, #ffffff 50%, #0798bc 25%);*/
29 | }
30 |
31 |
32 | #box3{
33 | -fx-border-radius: 3;
34 | -fx-background-insets: 2, 1, 2, 2;
35 | -fx-border-width: 3 3 3 3;
36 | /*-fx-background-color: linear-gradient(#0798bc 25%, #ffffff 50%, #0798bc 25%);*/
37 | }
38 |
39 | #box4{
40 | -fx-background-color: #fff;
41 | -fx-border-radius: 3;
42 | -fx-background-insets: 2, 1, 2, 2;
43 | /*-fx-background-radius: 3 3 3 3, 3 3 3 3, 3 3 3 3;*/
44 | -fx-text-fill: #333;
45 | -fx-padding: 5 5 5 5;
46 | -fx-border-color: #fff;
47 | -fx-border-width: 3 3 3 3;
48 | /*-fx-background-color: linear-gradient(#0798bc 25%, #ffffff 50%, #0798bc 25%);*/
49 | }
50 |
51 |
52 | #background{
53 |
54 | -fx-background-color: #fff;
55 |
56 | /*-fx-background-radius: 3 3 3 3, 3 3 3 3, 3 3 3 3;*/
57 | -fx-text-fill: #333;
58 |
59 | }
60 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/adminMessage.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
20 |
21 |
22 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/src/main/java/Receptionist/DoctorDetail.java:
--------------------------------------------------------------------------------
1 |
2 | package Receptionist;
3 |
4 | import javafx.beans.property.SimpleStringProperty;
5 |
6 | /**
7 | *
8 | * @author heshan
9 | */
10 | public class DoctorDetail {
11 | private final SimpleStringProperty doctorID = new SimpleStringProperty("");
12 | private final SimpleStringProperty doctorName = new SimpleStringProperty("");
13 | private final SimpleStringProperty area = new SimpleStringProperty("");
14 | private final SimpleStringProperty availability = new SimpleStringProperty("");
15 | private final SimpleStringProperty days = new SimpleStringProperty("");
16 |
17 | public DoctorDetail() {
18 | this("", "", "", "", "");
19 | }
20 |
21 | public DoctorDetail(String doctorID, String doctorName, String area, String availability, String days) {
22 | setDoctorID(doctorID);
23 | setDoctorName(doctorName);
24 | setArea(area);
25 | setAvailability(availability);
26 | setDays(days);
27 | }
28 |
29 | public String getDoctorID() {
30 | return doctorID.get();
31 | }
32 |
33 | public void setDoctorID(String value) {
34 | doctorID.set(value);
35 | }
36 |
37 | public String getDoctorName() {
38 | return doctorName.get();
39 | }
40 |
41 | public void setDoctorName(String value) {
42 | doctorName.set(value);
43 | }
44 |
45 | public String getArea() {
46 | return area.get();
47 | }
48 |
49 | public void setArea(String value) {
50 | area.set(value);
51 | }
52 |
53 | public String getAvailability() {
54 | return availability.get();
55 | }
56 |
57 | public void setAvailability(String value) {
58 | availability.set(value);
59 | }
60 |
61 | public String getDays() {
62 | return days.get();
63 | }
64 |
65 | public void setDays(String value) {
66 | days.set(value);
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/src/main/java/Cashier/Refund.java:
--------------------------------------------------------------------------------
1 | package Cashier;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 | import javafx.scene.image.ImageView;
5 |
6 | /**
7 | *
8 | * @author heshan
9 | */
10 | public class Refund {
11 | private final SimpleStringProperty patientID = new SimpleStringProperty("");
12 | private final SimpleStringProperty date = new SimpleStringProperty("");
13 | private final SimpleStringProperty billID = new SimpleStringProperty("");
14 | private final SimpleStringProperty service = new SimpleStringProperty("");
15 | private final SimpleStringProperty bill = new SimpleStringProperty("");
16 | private ImageView refund;
17 |
18 | public Refund(String patientID, String date, String billID, String service, String bill, ImageView refund) {
19 | setPatientID(patientID);
20 | setDate(date);
21 | setBillID(billID);
22 | setService(service);
23 | setBill(bill);
24 | setRefund(refund);
25 | }
26 |
27 | public String getPatientID() {
28 | return patientID.get();
29 | }
30 |
31 | public void setPatientID(String value) {
32 | patientID.set(value);
33 | }
34 |
35 | public String getDate() {
36 | return date.get();
37 | }
38 |
39 | public void setDate(String value) {
40 | date.set(value);
41 | }
42 |
43 | public String getBillID() {
44 | return billID.get();
45 | }
46 |
47 | public void setBillID(String value) {
48 | billID.set(value);
49 | }
50 |
51 | public String getService() {
52 | return service.get();
53 | }
54 |
55 | public void setService(String value) {
56 | service.set(value);
57 | }
58 |
59 | public String getBill() {
60 | return bill.get();
61 | }
62 |
63 | public void setBill(String value) {
64 | bill.set(value);
65 | }
66 |
67 | public ImageView getRefund() {
68 | return this.refund;
69 | }
70 |
71 | public void setRefund(ImageView value) {
72 | refund = value;
73 | }
74 |
75 | }
76 |
--------------------------------------------------------------------------------
/src/main/java/Pharmacist/Drug.java:
--------------------------------------------------------------------------------
1 | package Pharmacist;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Drug {
10 | private final SimpleStringProperty name = new SimpleStringProperty("");
11 | private final SimpleStringProperty type = new SimpleStringProperty("");
12 | private final SimpleStringProperty unit = new SimpleStringProperty("");
13 | private final SimpleStringProperty price = new SimpleStringProperty("");
14 | final SimpleStringProperty amount = new SimpleStringProperty("");
15 | private final SimpleStringProperty suppliers = new SimpleStringProperty("");
16 |
17 | public Drug() {
18 | this("", "", "", "", "", "");
19 | }
20 |
21 | public Drug(String drugName, String drugType, String drugUnit, String unitPrice, String amount, String suppliers) {
22 | setName(drugName);
23 | setType(drugType);
24 | setUnit(drugUnit);
25 | setPrice(unitPrice);
26 | setAmount(amount);
27 | setSuppliers(suppliers);
28 | }
29 |
30 | public String getName() {
31 | return name.get();
32 | }
33 |
34 | public void setName(String value) {
35 | name.set(value);
36 | }
37 |
38 | public String getType() {
39 | return type.get();
40 | }
41 |
42 | public void setType(String value) {
43 | type.set(value);
44 | }
45 |
46 | public String getUnit() {
47 | return unit.get();
48 | }
49 |
50 | public void setUnit(String value) {
51 | unit.set(value);
52 | }
53 |
54 | public String getPrice() {
55 | return price.get();
56 | }
57 |
58 | public void setPrice(String value) {
59 | price.set(value);
60 | }
61 |
62 | public int getAmount() {
63 | return Integer.parseInt(amount.get());
64 | }
65 |
66 | public void setAmount(String value) {
67 | amount.set(value);
68 | }
69 |
70 | public String getSuppliers() {
71 | return suppliers.get();
72 | }
73 |
74 | public void setSuppliers(String value) {
75 | suppliers.set(value);
76 | }
77 |
78 | }
79 |
--------------------------------------------------------------------------------
/src/main/java/Doctor/PopoverController.java:
--------------------------------------------------------------------------------
1 | package Doctor;
2 |
3 | import java.util.*;
4 | import javafx.scene.control.TextField;
5 | import javafx.fxml.FXML;
6 | import javafx.scene.control.*;
7 | import javafx.stage.Stage;
8 | import javafx.fxml.FXMLLoader;
9 | import java.io.IOException;
10 | import javafx.collections.FXCollections;
11 | import javafx.collections.ObservableList;
12 | import javafx.scene.Node;
13 | import javafx.scene.input.KeyCode;
14 | import javafx.scene.layout.AnchorPane;
15 | import javafx.scene.input.KeyEvent;
16 |
17 | /**
18 | *
19 | * @author heshan
20 | */
21 | public class PopoverController extends AnchorPane {
22 |
23 | TextField text;
24 |
25 | /**
26 | *
27 | * @param username
28 | */
29 | public PopoverController(TextField text) {
30 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/Popover.fxml"));
31 | fxmlLoader.setRoot(this);
32 | fxmlLoader.setController(this);
33 |
34 | this.text = text;
35 |
36 | try {
37 | fxmlLoader.load();
38 | } catch (IOException exception) {
39 | throw new RuntimeException(exception);
40 | }
41 | }
42 |
43 | @FXML
44 | private ListView brandList;
45 | @FXML
46 | private Label genericName;
47 |
48 | public void fillBrandList(ArrayList data, String genName) {
49 | ObservableList items = FXCollections.observableArrayList();
50 | int size = data.size();
51 |
52 | for (int i = 0; i < size; i++) {
53 | items.add(data.get(i));
54 | }
55 | brandList.setItems(items);
56 | genericName.setText(genName);
57 | }
58 |
59 | @FXML
60 | private void selectBrand(KeyEvent e) {
61 | if (e.getCode() == KeyCode.ENTER) {
62 | String brand = (String) brandList.getSelectionModel().getSelectedItem();
63 | text.setText(brand);
64 |
65 | Stage stage = (Stage) brandList.getScene().getWindow();
66 | stage.close();
67 | }
68 |
69 | }
70 |
71 | public void close() {
72 | ((Node) (genericName)).getScene().getWindow().hide();
73 | }
74 |
75 | }
76 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/PopupAskController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import Cashier.CashierController;
4 | import Cashier.RefundController;
5 | import javafx.fxml.FXML;
6 | import javafx.scene.control.*;
7 | import javafx.fxml.FXMLLoader;
8 | import java.io.IOException;
9 | import javafx.scene.layout.AnchorPane;
10 | import javafx.stage.Stage;
11 |
12 | /**
13 | *
14 | * @author heshan
15 | */
16 | public class PopupAskController extends AnchorPane {
17 |
18 | private Label label;
19 | private CashierController cashier;
20 | private RefundController refundC;
21 |
22 | public PopupAskController(Label label, CashierController cashier, RefundController refundC) {
23 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/PopupAsk.fxml"));
24 | fxmlLoader.setRoot(this);
25 | fxmlLoader.setController(this);
26 |
27 | this.label = label;
28 | this.cashier = cashier;
29 | this.refundC = refundC;
30 |
31 | try {
32 | fxmlLoader.load();
33 | } catch (IOException exception) {
34 | throw new RuntimeException(exception);
35 | }
36 | }
37 |
38 | @FXML
39 | private Button yesButton;
40 | @FXML
41 | private Button noButton;
42 |
43 | @FXML
44 | private void yes() {
45 |
46 | String[] tmp = label.getText().split(" ");
47 | if (tmp[0].equals("refund")) {
48 | boolean result = cashier.cashier.makeRefund(tmp[1]);
49 |
50 | if (result) {
51 | cashier.loadRefunds();
52 |
53 | Stage stage2;
54 | stage2 = (Stage) yesButton.getScene().getWindow();
55 | stage2.close();
56 |
57 | refundC.fillRefundTable();
58 |
59 | cashier.showSuccessIndicator();
60 |
61 | }
62 |
63 | }
64 |
65 | }
66 |
67 | @FXML
68 | private void no() {
69 |
70 | Stage stage;
71 | stage = (Stage) noButton.getScene().getWindow();
72 | stage.close();
73 | }
74 |
75 | @FXML
76 | private Label PopUpMessage;
77 |
78 | public void message(String msg) {
79 | PopUpMessage.setText(msg);
80 | }
81 |
82 | }
83 |
--------------------------------------------------------------------------------
/src/main/resources/styles/accordian.css:
--------------------------------------------------------------------------------
1 | .accordion .titled-pane .title {
2 | /*-fx-background-color:linear-gradient(#aaa 0%, #fff 100%); /*linear-gradient(#131313 0%, #424141 100%); /*transparent ;*/
3 | -fx-text-fill: #d9d9d9;
4 | -fx-alignment: CENTER;
5 | }
6 |
7 |
8 | .titled-pane {
9 | -fx-text-fill: #777;
10 | }
11 |
12 | .titled-pane > .title
13 | {
14 | -fx-background-color: -fx-box-border, -fx-inner-border, -fx-body-color;
15 | -fx-background-insets: 0, 1, 2;
16 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
17 | -fx-padding: 0.166667em 0.833333em 0.25em 0.833333em; /* 2 10 3 10 */
18 | }
19 |
20 | .titled-pane:focused > .title
21 | {
22 | -fx-color: -fx-focus-color;
23 | -fx-font-weight:bold;
24 | }
25 |
26 | .titled-pane:expanded > .title
27 | {
28 | -fx-background-color:linear-gradient(#131313 0%, #424141 100%);
29 | -fx-color: -fx-focus-color;
30 | -fx-font-weight:bold;
31 | -fx-text-fill:#fff !important;
32 | }
33 |
34 | .titled-pane:collapsed > .title
35 | {
36 | /*-fx-background-color:linear-gradient(#aaa 0%, #fff 100%);*/
37 | }
38 |
39 | .titled-pane > .title > .arrow-button
40 | {
41 | -fx-background-color: null;
42 | -fx-background-insets: 0;
43 | -fx-background-radius: 0;
44 | -fx-padding: 0.0em 0.25em 0.0em 0.0em; /* 0 3 0 0 */
45 | }
46 |
47 | .titled-pane > .title > .arrow-button .arrow
48 | {
49 | -fx-background-color: -fx-mark-highlight-color, -fx-mark-color;
50 | -fx-background-insets: 1 0 -1 0, 0;
51 | -fx-padding: 0.25em 0.3125em 0.25em 0.3125em; /* 3 3.75 3 3.75 */
52 | -fx-shape: "M 0 0 h 7 l -3.5 4 z";
53 | }
54 |
55 | .titled-pane:collapsed > .title > .arrow-button .arrow
56 | {
57 | -fx-rotate: -90;
58 | }
59 |
60 | .titled-pane > *.content
61 | {
62 | -fx-background-color:
63 | -fx-box-border,
64 | linear-gradient(to bottom, derive(-fx-color,-02%), derive(-fx-color,65%) 12%, derive(-fx-color,23%) 88%, derive(-fx-color,50%) 99%, -fx-box-border);
65 | -fx-background-insets: 0, 0 1 1 1;
66 | -fx-padding: 0.167em;
67 | -fx-background-radius: 0 0 5 5, 0 0 4 4, 0 0 3 3;
68 | -fx-border-radius: 0 0 5 5;
69 | -fx-background-insets: 0, 1, 2;
70 | }
71 |
72 | .titled-pane:focused > .title > .arrow-button .arrow
73 | {
74 | -fx-background-color: #0798bc;
75 | }
76 |
77 | .titled-pane:focused
78 | {
79 | -fx-text-fill: white;
80 | }
81 |
--------------------------------------------------------------------------------
/src/main/resources/styles/table.css:
--------------------------------------------------------------------------------
1 | .table-view{
2 | -fx-background-color: transparent;
3 | }
4 |
5 | .table-view:focused{
6 | -fx-background-color: transparent;
7 | }
8 |
9 | /* Spaltenköpfe
10 | Struktur column-header-background -> column-header */
11 |
12 | .table-view .column-header-background{
13 | -fx-background-color: linear-gradient(#131313 0%, #424141 100%);
14 | }
15 |
16 | .table-view .column-header-background .label{
17 | -fx-background-color: transparent;
18 | -fx-text-fill: white;
19 | }
20 |
21 | .table-view .column-header {
22 | -fx-background-color: transparent;
23 | }
24 |
25 | .table-view .table-cell .text{
26 | -fx-text-fill: black;
27 | }
28 |
29 |
30 | .table-row-cell{
31 | -fx-background-color: -fx-table-cell-border-color, #ffffff; /*#616161;*/
32 | -fx-background-insets: 0, 0 0 1 0;
33 | -fx-padding: 0 0 0 5; /* 0 */
34 | }
35 |
36 | .table-row-cell:odd{
37 | -fx-background-color: -fx-table-cell-border-color, #ddd;
38 | -fx-background-insets: 0, 0 0 1 0;
39 | -fx-padding: 0 0 0 5; /* 0 */
40 | }
41 | /*
42 | .table-row-cell:selected {
43 | -fx-background-color: #005797;
44 | -fx-background-insets: 0;
45 | -fx-background-radius: 1;
46 | -fx-text-fill: whitesmoke !important;
47 | }
48 |
49 | .table-view .table-cell:selected{
50 | -fx-text-fill: whitesmoke !important;
51 | }
52 | */
53 | .table-view > .virtual-flow > .scroll-bar:vertical,
54 | .table-view > .virtual-flow > .scroll-bar:vertical > .track,
55 | .table-view > .virtual-flow > .scroll-bar:vertical > .track-background,
56 | .table-view > .virtual-flow > .scroll-bar:horizontal,
57 | .table-view > .virtual-flow > .scroll-bar:horizontal > .track,
58 | .table-view > .virtual-flow > .scroll-bar:horizontal > .track-background {
59 | -fx-background-color: transparent;
60 | }
61 |
62 |
63 |
64 | .table-view > .virtual-flow > .scroll-bar > .increment-button,
65 | .table-view > .virtual-flow > .scroll-bar > .decrement-button {
66 | -fx-opacity: 0;
67 | }
68 |
69 | .table-view .filler{
70 | -fx-background-color: linear-gradient(#131313 0%, #424141 100%);
71 | }
72 |
73 | .table-row-cell {
74 | -fx-cell-size: 35px;
75 | }
76 |
77 | .table-row-cell:selected {
78 | -fx-background-color: steelblue;
79 | -fx-text-background-color: white;
80 | }
81 |
82 | .table-column {
83 | -fx-alignment: CENTER-LEFT;
84 |
85 | }
--------------------------------------------------------------------------------
/src/main/java/LabAssistant/PrescriptionListController.java:
--------------------------------------------------------------------------------
1 | package LabAssistant;
2 |
3 | import java.util.*;
4 | import javafx.fxml.FXML;
5 | import javafx.scene.control.*;
6 | import javafx.stage.Stage;
7 | import javafx.fxml.FXMLLoader;
8 | import java.io.IOException;
9 | import javafx.collections.FXCollections;
10 | import javafx.collections.ObservableList;
11 | import javafx.scene.layout.AnchorPane;
12 |
13 | /**
14 | *
15 | * @author heshan
16 | */
17 | public class PrescriptionListController extends AnchorPane {
18 |
19 | public PrescriptionListController() {
20 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/PrescriptionListPopup.fxml"));
21 | fxmlLoader.setRoot(this);
22 | fxmlLoader.setController(this);
23 |
24 | try {
25 | fxmlLoader.load();
26 | } catch (IOException exception) {
27 | throw new RuntimeException(exception);
28 | }
29 | }
30 |
31 | LabAssistantController lab;
32 | @FXML
33 | TableView prescList;
34 |
35 | public void fillTableData(ArrayList> data, LabAssistantController lab) {
36 |
37 | int noOfSlots = data.size();
38 | final ObservableList data2 = FXCollections.observableArrayList();
39 | for (int i = 1; i < noOfSlots; i++) {
40 | String prescID = data.get(i).get(0);
41 | String prescDate = data.get(i).get(1);
42 | String prescconsultant = data.get(i).get(3) + " " + data.get(i).get(4);
43 | String prescTests = data.get(i).get(2);
44 |
45 | data2.add(new Prescription(prescID, prescDate, prescconsultant, prescTests));
46 | }
47 | prescList.setItems(data2);
48 | this.lab = lab;
49 | }
50 |
51 | @FXML
52 | private void LoadPrescriptionInfo() {
53 | Prescription prescription = (Prescription) prescList.getSelectionModel().getSelectedItem();
54 |
55 | String doctor = prescription.getDoctor();
56 | String tests = prescription.getPrescription();
57 | String date = prescription.getDate();
58 |
59 | lab.fillPrescriptionInfo(doctor, tests, date);
60 |
61 | Stage stage = new Stage();
62 | stage = (Stage) prescList.getScene().getWindow();
63 | stage.close();
64 |
65 | }
66 |
67 | @FXML
68 | private void close() {
69 | Stage stage = new Stage();
70 | stage = (Stage) prescList.getScene().getWindow();
71 | stage.close();
72 | }
73 |
74 | }
75 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/LogoutController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import java.io.IOException;
4 | import javafx.event.ActionEvent;
5 | import javafx.fxml.FXML;
6 | import javafx.fxml.FXMLLoader;
7 | import javafx.geometry.Rectangle2D;
8 | import javafx.scene.Scene;
9 | import javafx.scene.control.Button;
10 | import javafx.scene.layout.AnchorPane;
11 | import javafx.stage.Screen;
12 | import javafx.stage.Stage;
13 |
14 | public class LogoutController extends AnchorPane {
15 |
16 | @FXML
17 | private Button mainLogoutButton;
18 |
19 | private User user;
20 |
21 | public LogoutController(Button button, User user) {
22 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/Logout.fxml"));
23 | fxmlLoader.setRoot(this);
24 | fxmlLoader.setController(this);
25 |
26 | this.user = user;
27 | mainLogoutButton = button;
28 |
29 | try {
30 | fxmlLoader.load();
31 | } catch (IOException exception) {
32 | throw new RuntimeException(exception);
33 | }
34 | }
35 |
36 | @FXML
37 | private Button logoutButton;
38 | @FXML
39 | private Button cancelButton;
40 |
41 | @FXML
42 | private void logout() {
43 |
44 | user.saveLogout(user.username);
45 |
46 | Stage stage = (Stage) mainLogoutButton.getScene().getWindow();
47 | stage.close();
48 |
49 | stage = (Stage) cancelButton.getScene().getWindow();
50 | stage.close();
51 |
52 | LoginController login = new LoginController();
53 | stage.setScene(new Scene(login));
54 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
55 | // set Stage boundaries to visible bounds of the main screen
56 | stage.setX(primaryScreenBounds.getMinX());
57 | stage.setY(primaryScreenBounds.getMinY());
58 | stage.setWidth(primaryScreenBounds.getWidth());
59 | stage.setHeight(primaryScreenBounds.getHeight());
60 | stage.show();
61 | }
62 |
63 | @FXML
64 | private void cancel() {
65 | Stage stage = (Stage) cancelButton.getScene().getWindow();
66 | stage.close();
67 | }
68 |
69 | @FXML
70 | private Button saveSuccess;
71 |
72 | @FXML
73 | private void saveSuccessExit(ActionEvent event) {
74 |
75 | Stage stage;
76 | if (event.getSource() == saveSuccess) {
77 | stage = (Stage) saveSuccess.getScene().getWindow();
78 | stage.close();
79 | }
80 | }
81 |
82 | }
83 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # HealthCare Facility
2 |
3 | [](https://openjdk.org/)
4 | [](https://openjfx.io)
5 | [](https://mariadb.org/download)
6 | [](https://maven.apache.org/)
7 | [](https://github.com/stellarloop/Health-Care-Facility/blob/master/LICENSE)
8 |
9 | HealthCare Facility is a management system designed to streamline operations within healthcare facilities. It offers functionalities such as patient registration, appointment scheduling, medical record management, pharmacy billing, and inventory control. Developed using Java, JavaFX and uses MariaDB for database management
10 |
11 | ## The system includes
12 | - Registration of patients
13 | - Making appointments
14 | - Storing patient records
15 | - Billing in the pharmacy
16 | - Pharmacy stock controlling
17 |
18 | ## Workflow and Component Interactions
19 |
20 |
21 |
22 | ## Setting Up the Application
23 |
24 | ### Prerequisites
25 | - [MariaDB](https://mariadb.org/download)
26 | - [Java](https://openjdk.org/)
27 | - [JavaFX](https://openjfx.io)
28 |
29 | ### Set Up the Database
30 | - Set up a new database named `test_HMS2`
31 | - Import the dummy data from [`hms_db.sql`](https://github.com/stellarloop/Health-Care-Facility/blob/master/database/hms_db.sql) to new DB
32 | - Update the system configuration in [`config.properties`](https://github.com/stellarloop/Health-Care-Facility/blob/master/config.properties) with the database credentials
33 |
34 |
35 | ### Build the App
36 | - Resolve the dependencies
37 | ```shell
38 | mvn dependency:resolve
39 | ```
40 | - Build
41 | ```shell
42 | mvn clean install
43 | ```
44 | - Run
45 | ```shell
46 | mvn javafx:run
47 | ```
48 |
49 | ### Authentication
50 | Since this was developed as a simple application, all the credentials are saved in a database table in plain text format without any hashing or encryptions.
51 |
52 | #### View all existing users with credentials
53 | ```SQL
54 | USE test_HMS2;
55 | SELECT * FROM sys_user;
56 | ```
57 |
58 | ## User Interfaces
59 |
60 |
61 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/CurrentUserSummaryController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import java.util.ArrayList;
8 | import java.util.HashMap;
9 | import javafx.event.ActionEvent;
10 | import javafx.scene.image.Image;
11 | import javafx.scene.image.ImageView;
12 | import javafx.scene.layout.AnchorPane;
13 | import javafx.stage.Stage;
14 |
15 | /**
16 | *
17 | * @author heshan
18 | */
19 | public class CurrentUserSummaryController extends AnchorPane {
20 |
21 | private User sysUser;
22 |
23 | public CurrentUserSummaryController(User sysUser) {
24 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/CurrentUserSummary.fxml"));
25 | fxmlLoader.setRoot(this);
26 | fxmlLoader.setController(this);
27 |
28 | this.sysUser = sysUser;
29 |
30 | try {
31 | fxmlLoader.load();
32 | } catch (IOException exception) {
33 | throw new RuntimeException(exception);
34 | }
35 | }
36 |
37 | @FXML
38 | private ImageView profPic;
39 | @FXML
40 | private Label userN;
41 | @FXML
42 | private Label userTAndN;
43 |
44 | public void fillUser() {
45 | HashMap log = new HashMap();
46 | log.clear();
47 | log.put("doctor", "Doctor");
48 | log.put("lab_assistant", "Lab Assistant");
49 | log.put("cashier", "Cashier");
50 | log.put("pharmacist", "Pharmacist");
51 | log.put("receptionist", "Receptionist");
52 | log.put("admin", "Admin");
53 |
54 | ArrayList> data = sysUser.getCurrentUserNameAndID();
55 |
56 | userN.setText(data.get(1).get(0) + " " + data.get(1).get(1));
57 | userTAndN.setText(log.get(data.get(1).get(2)) + " : " + data.get(1).get(3));
58 | Image img;
59 | try {
60 | String image = sysUser.getProfilePic();
61 | img = new Image(getClass().getResource("/imgs/profilePics/" + image).toString(), true);
62 | } catch (Exception e) {
63 | img = new Image(getClass().getResource("/imgs/noUser.png").toString(), true);
64 | }
65 | profPic.setImage(img);
66 |
67 | }
68 |
69 | @FXML
70 | private Button saveSuccess;
71 |
72 | @FXML
73 | private void saveSuccessExit(ActionEvent event) {
74 |
75 | Stage stage;
76 | if (event.getSource() == saveSuccess) {
77 | stage = (Stage) saveSuccess.getScene().getWindow();
78 | stage.close();
79 | }
80 | }
81 |
82 | public void load() {
83 | fillUser();
84 | }
85 |
86 | }
87 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/AllMessages.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.scene.image.ImageView;
4 |
5 | public class AllMessages {
6 | private ImageView image;
7 | private String string;
8 | private ImageView image2;
9 |
10 | private String sender;
11 | private String message;
12 | private String date;
13 | private String subject;
14 | private String name;
15 | private String type;
16 | private String id;
17 |
18 | AllMessages(ImageView img, String string, ImageView img2, String sender, String message, String date,
19 | String subject, String name, String type, String id) {
20 | this.image = img;
21 | this.image2 = img2;
22 | this.string = string;
23 |
24 | this.sender = sender;
25 | this.message = message;
26 | this.date = date;
27 | this.subject = subject;
28 | this.name = name;
29 | this.type = type;
30 | this.id = id;
31 | }
32 |
33 | public void setImage(ImageView value) {
34 | image = value;
35 | }
36 |
37 | public ImageView getImage() {
38 | return image;
39 | }
40 |
41 | public void setImage2(ImageView value) {
42 | image2 = value;
43 | }
44 |
45 | public ImageView getImage2() {
46 | return image2;
47 | }
48 |
49 | public void setString(String string) {
50 | this.string = string;
51 | }
52 |
53 | public String getString() {
54 | return this.string;
55 | }
56 |
57 | public void setSender(String string) {
58 | this.sender = string;
59 | }
60 |
61 | public String getSender() {
62 | return this.sender;
63 | }
64 |
65 | public void setMessage(String string) {
66 | this.message = string;
67 | }
68 |
69 | public String getMessage() {
70 | return this.message;
71 | }
72 |
73 | public void setDate(String string) {
74 | this.date = string;
75 | }
76 |
77 | public String getDate() {
78 | return this.date;
79 | }
80 |
81 | public void setSubject(String string) {
82 | this.subject = string;
83 | }
84 |
85 | public String getSubject() {
86 | return this.subject;
87 | }
88 |
89 | public void setType(String string) {
90 | this.type = string;
91 | }
92 |
93 | public String getType() {
94 | return this.type;
95 | }
96 |
97 | public void setName(String string) {
98 | this.name = string;
99 | }
100 |
101 | public String getName() {
102 | return this.name;
103 | }
104 |
105 | public void setID(String string) {
106 | this.id = string;
107 | }
108 |
109 | public String getID() {
110 | return this.id;
111 | }
112 | }
113 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/ProgressIndicator.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/CurrentUserSummary.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/AllMessages.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
43 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
--------------------------------------------------------------------------------
/src/main/java/Cashier/Bill.java:
--------------------------------------------------------------------------------
1 | package Cashier;
2 |
3 | import javafx.beans.property.SimpleStringProperty;
4 |
5 | /**
6 | *
7 | * @author heshan
8 | */
9 | public class Bill {
10 | private final SimpleStringProperty patientID = new SimpleStringProperty("");
11 | private final SimpleStringProperty date = new SimpleStringProperty("");
12 |
13 | private final SimpleStringProperty doctor = new SimpleStringProperty("");
14 | private final SimpleStringProperty hospital = new SimpleStringProperty("");
15 | private final SimpleStringProperty pharmacy = new SimpleStringProperty("");
16 | private final SimpleStringProperty laboratory = new SimpleStringProperty("");
17 | private final SimpleStringProperty appointment = new SimpleStringProperty("");
18 |
19 | private final SimpleStringProperty bill = new SimpleStringProperty("");
20 | private final SimpleStringProperty billID = new SimpleStringProperty("");
21 |
22 | public Bill() {
23 | this("", "", "", "", "", "", "", "", "");
24 | }
25 |
26 | public Bill(String patientID, String date, String doctor, String hospital, String pharmacy, String laboratory,
27 | String appointment, String bill, String billID) {
28 | setPatientID(patientID);
29 | setDate(date);
30 |
31 | setDoctor(doctor);
32 | setHospital(hospital);
33 | setPharmacy(pharmacy);
34 | setLaboratory(laboratory);
35 | setAppointment(appointment);
36 |
37 | setBill(bill);
38 | setBillID(billID);
39 | }
40 |
41 | public String getPatientID() {
42 | return patientID.get();
43 | }
44 |
45 | public void setPatientID(String value) {
46 | patientID.set(value);
47 | }
48 |
49 | public String getDate() {
50 | return date.get();
51 | }
52 |
53 | public void setDate(String value) {
54 | date.set(value);
55 | }
56 |
57 | public String getDoctor() {
58 | return doctor.get();
59 | }
60 |
61 | public void setDoctor(String value) {
62 | doctor.set(value);
63 | }
64 |
65 | public String getHospital() {
66 | return hospital.get();
67 | }
68 |
69 | public void setHospital(String value) {
70 | hospital.set(value);
71 | }
72 |
73 | public String getPharmacy() {
74 | return pharmacy.get();
75 | }
76 |
77 | public void setPharmacy(String value) {
78 | pharmacy.set(value);
79 | }
80 |
81 | public String getLaboratory() {
82 | return laboratory.get();
83 | }
84 |
85 | public void setLaboratory(String value) {
86 | laboratory.set(value);
87 | }
88 |
89 | public String getAppointment() {
90 | return appointment.get();
91 | }
92 |
93 | public void setAppointment(String value) {
94 | appointment.set(value);
95 | }
96 |
97 | public String getBill() {
98 | return bill.get();
99 | }
100 |
101 | public void setBill(String value) {
102 | bill.set(value);
103 | }
104 |
105 | public String getBillID() {
106 | return billID.get();
107 | }
108 |
109 | public void setBillID(String value) {
110 | billID.set(value);
111 | }
112 | }
113 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/UserOptionPopOver.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
68 |
69 |
70 |
71 |
72 |
--------------------------------------------------------------------------------
/src/main/java/Doctor/NewDoctorTimeSlotController.java:
--------------------------------------------------------------------------------
1 | package Doctor;
2 |
3 | import com.hms.hms_test_2.SuccessIndicatorController;
4 | import javafx.fxml.FXML;
5 | import javafx.scene.control.*;
6 | import javafx.fxml.FXMLLoader;
7 | import java.io.IOException;
8 | import java.util.HashMap;
9 | import javafx.event.ActionEvent;
10 | import javafx.geometry.Rectangle2D;
11 | import javafx.scene.Scene;
12 | import javafx.scene.layout.AnchorPane;
13 | import javafx.stage.Screen;
14 | import javafx.stage.Stage;
15 | import javafx.stage.StageStyle;
16 |
17 | /**
18 | *
19 | * @author heshan
20 | */
21 | public class NewDoctorTimeSlotController extends AnchorPane {
22 |
23 | private Doctor doc;
24 | private DoctorController docC;
25 |
26 | public NewDoctorTimeSlotController(Doctor doc, DoctorController docC) {
27 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/NewDoctorTimeSlot.fxml"));
28 | fxmlLoader.setRoot(this);
29 | fxmlLoader.setController(this);
30 |
31 | this.doc = doc;
32 | this.docC = docC;
33 |
34 | try {
35 | fxmlLoader.load();
36 | } catch (IOException exception) {
37 | throw new RuntimeException(exception);
38 | }
39 | }
40 |
41 | @FXML
42 | private Button saveSuccess;
43 |
44 | @FXML
45 | private void saveSuccessExit(ActionEvent event) {
46 |
47 | Stage stage;
48 | if (event.getSource() == saveSuccess) {
49 | stage = (Stage) saveSuccess.getScene().getWindow();
50 | stage.close();
51 | }
52 | }
53 |
54 | @FXML
55 | private Label close;
56 |
57 | @FXML
58 | private void closeEditor() {
59 | Stage stage;
60 | stage = (Stage) close.getScene().getWindow();
61 | stage.close();
62 | }
63 |
64 | public void showSuccessIndicator() {
65 | Stage stage = new Stage();
66 | SuccessIndicatorController success = new SuccessIndicatorController();
67 | Scene scene = new Scene(success);
68 | stage.setScene(scene);
69 |
70 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
71 | // set Stage boundaries to visible bounds of the main screen
72 | stage.setX(primaryScreenBounds.getMinX());
73 | stage.setY(primaryScreenBounds.getMinY());
74 | stage.setWidth(primaryScreenBounds.getWidth());
75 | stage.setHeight(primaryScreenBounds.getHeight());
76 |
77 | stage.initStyle(StageStyle.UNDECORATED);
78 | scene.setFill(null);
79 | stage.initStyle(StageStyle.TRANSPARENT);
80 | stage.show();
81 | }
82 |
83 | @FXML
84 | private Button saveButton;
85 |
86 | @FXML
87 | private ComboBox slotDayCombo;
88 | @FXML
89 | private ComboBox start;
90 | @FXML
91 | private ComboBox end;
92 |
93 | @FXML
94 | private void save() {
95 | String day = (String) slotDayCombo.getSelectionModel().getSelectedItem();
96 | String sTime = (String) start.getSelectionModel().getSelectedItem();
97 | String eTime = (String) end.getSelectionModel().getSelectedItem();
98 |
99 | HashMap daysHash = new HashMap<>();
100 | daysHash.put("Monday", "1");
101 | daysHash.put("Tuesday", "2");
102 | daysHash.put("Wednesday", "3");
103 | daysHash.put("Thursday", "4");
104 | daysHash.put("Friday", "5");
105 | daysHash.put("Saturday", "6");
106 | daysHash.put("Sunday", "7");
107 |
108 | day = daysHash.get(day);
109 | String timeSlot = sTime + "-" + eTime;
110 |
111 | boolean result = doc.doctorTimeTableAddSlot(day, timeSlot);
112 | if (result) {
113 | Stage stage;
114 | stage = (Stage) close.getScene().getWindow();
115 | stage.close();
116 | docC.MakeAvailabilityTable();
117 | showSuccessIndicator();
118 | }
119 | }
120 |
121 | }
122 |
--------------------------------------------------------------------------------
/src/main/java/Cashier/RefundController.java:
--------------------------------------------------------------------------------
1 | package Cashier;
2 |
3 | import com.hms.hms_test_2.PopupAskController;
4 | import java.io.IOException;
5 | import java.util.ArrayList;
6 | import javafx.collections.FXCollections;
7 | import javafx.collections.ObservableList;
8 | import javafx.fxml.FXML;
9 | import javafx.fxml.FXMLLoader;
10 | import javafx.geometry.Rectangle2D;
11 | import javafx.scene.Scene;
12 | import javafx.scene.control.Label;
13 | import javafx.scene.control.TablePosition;
14 | import javafx.scene.control.TableView;
15 | import javafx.scene.image.Image;
16 | import javafx.scene.image.ImageView;
17 | import javafx.scene.layout.AnchorPane;
18 | import javafx.stage.Screen;
19 | import javafx.stage.Stage;
20 | import javafx.stage.StageStyle;
21 |
22 | public class RefundController extends AnchorPane {
23 |
24 | CashierController cashier;
25 |
26 | public RefundController(CashierController cashier) {
27 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/RefundTable.fxml"));
28 | fxmlLoader.setRoot(this);
29 | fxmlLoader.setController(this);
30 |
31 | this.cashier = cashier;
32 |
33 | try {
34 | fxmlLoader.load();
35 | } catch (IOException exception) {
36 | throw new RuntimeException(exception);
37 | }
38 | }
39 |
40 | // @FXML
41 | // private TableView billTable;
42 | @FXML
43 | private TableView refundTable;
44 |
45 | public void fillRefundTable() {
46 | final ObservableList data = FXCollections.observableArrayList();
47 | ArrayList> refundData = cashier.cashier.getWaitingRefunds();
48 |
49 | int size = refundData.size();
50 | for (int i = 1; i < size; i++) {
51 | String refundId = refundData.get(i).get(0);
52 | String billId = refundData.get(i).get(1);
53 | String reason = refundData.get(i).get(3);
54 | String amount = refundData.get(i).get(4);
55 | String date = refundData.get(i).get(5);
56 |
57 | Image img2 = new Image(getClass().getResource("/imgs/refund.png").toString(), true);
58 | ImageView imageView = new ImageView(img2);
59 | imageView.setFitHeight(25);
60 | imageView.setFitWidth(25);
61 | imageView.setPreserveRatio(true);
62 |
63 | data.add(new Refund(refundId, date, billId, reason, amount, imageView));
64 | }
65 |
66 | refundTable.setItems(data);
67 | }
68 |
69 | private Label info = new Label();
70 |
71 | @FXML
72 | private void getRefundInfo() {
73 |
74 | Refund refund = (Refund) refundTable.getSelectionModel().getSelectedItem();
75 |
76 | @SuppressWarnings("unchecked")
77 | TablePosition pos = refundTable.getFocusModel().getFocusedCell();
78 | int column = pos.getColumn();
79 | if (column == 5) {
80 | info.setText("refund " + refund.getPatientID());
81 |
82 | Stage stage = new Stage();
83 | PopupAskController popup = new PopupAskController(info, cashier, this);
84 | popup.message(" Make the Refund?");
85 |
86 | Scene scene = new Scene(popup);
87 | stage.setScene(scene);
88 |
89 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
90 | // set Stage boundaries to visible bounds of the main screen
91 | stage.setX(primaryScreenBounds.getMinX());
92 | stage.setY(primaryScreenBounds.getMinY());
93 | stage.setWidth(primaryScreenBounds.getWidth());
94 | stage.setHeight(primaryScreenBounds.getHeight());
95 |
96 | stage.initStyle(StageStyle.UNDECORATED);
97 | scene.setFill(null);
98 | stage.initStyle(StageStyle.TRANSPARENT);
99 | stage.show();
100 | }
101 |
102 | if (info.getText().equals("1")) {
103 | System.out.println("Yes!");
104 | }
105 | System.out.println(info.getText());
106 |
107 | }
108 |
109 | @FXML
110 | public Label closeRefund;
111 |
112 | @FXML
113 | public void closeRefundTable() {
114 | Stage stage;
115 | stage = (Stage) closeRefund.getScene().getWindow();
116 | stage.close();
117 | }
118 |
119 | }
120 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/PrescriptionListPopup.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
81 |
82 |
83 |
84 |
85 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/ReadMessageController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import javafx.event.ActionEvent;
8 | import javafx.geometry.Rectangle2D;
9 | import javafx.scene.Scene;
10 | import javafx.scene.layout.AnchorPane;
11 | import javafx.stage.Screen;
12 | import javafx.stage.Stage;
13 | import javafx.stage.StageStyle;
14 |
15 | /**
16 | *
17 | * @author heshan
18 | */
19 | public class ReadMessageController extends AnchorPane {
20 |
21 | private AllMessages message;
22 | private User newSysUser;
23 |
24 | public ReadMessageController(AllMessages message, User newSysUser) {
25 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/ReadMessage.fxml"));
26 | fxmlLoader.setRoot(this);
27 | fxmlLoader.setController(this);
28 |
29 | this.message = message;
30 | this.newSysUser = newSysUser;
31 |
32 | try {
33 | fxmlLoader.load();
34 | } catch (IOException exception) {
35 | throw new RuntimeException(exception);
36 | }
37 | }
38 |
39 | @FXML
40 | private Button saveSuccess;
41 |
42 | @FXML
43 | private void saveSuccessExit(ActionEvent event) {
44 |
45 | Stage stage;
46 | if (event.getSource() == saveSuccess) {
47 | stage = (Stage) saveSuccess.getScene().getWindow();
48 | stage.close();
49 | }
50 | }
51 |
52 | @FXML
53 | private Label close;
54 |
55 | @FXML
56 | private void closeEditor() {
57 | Stage stage;
58 | stage = (Stage) close.getScene().getWindow();
59 | stage.close();
60 | }
61 |
62 | @FXML
63 | private Button deleteButton;
64 |
65 | @FXML
66 | private void delete() {
67 | String id = msgID.getText();
68 | boolean result = newSysUser.deleteMessage(id);
69 | if (result) {
70 | Stage stage;
71 | stage = (Stage) close.getScene().getWindow();
72 | stage.close();
73 | showSuccessIndicator();
74 | }
75 |
76 | }
77 |
78 | @FXML
79 | private void reply() {
80 | Stage stage2;
81 | stage2 = (Stage) close.getScene().getWindow();
82 | stage2.close();
83 |
84 | Stage stage = new Stage();
85 | NewMessageController newMessage = new NewMessageController(newSysUser);
86 | System.out.println(msgID.getText());
87 | newMessage.load(msgID.getText());
88 | Scene scene = new Scene(newMessage);
89 | stage.setScene(scene);
90 |
91 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
92 | // set Stage boundaries to visible bounds of the main screen
93 | stage.setX(primaryScreenBounds.getMinX());
94 | stage.setY(primaryScreenBounds.getMinY());
95 | stage.setWidth(primaryScreenBounds.getWidth());
96 | stage.setHeight(primaryScreenBounds.getHeight());
97 |
98 | stage.initStyle(StageStyle.UNDECORATED);
99 | scene.setFill(null);
100 | stage.initStyle(StageStyle.TRANSPARENT);
101 | stage.show();
102 |
103 | }
104 |
105 | @FXML
106 | private void previousMessage() {
107 |
108 | }
109 |
110 | @FXML
111 | private void nextMessage() {
112 |
113 | }
114 |
115 | @FXML
116 | private Label senderName;
117 | @FXML
118 | private Label date;
119 | @FXML
120 | private Label subject;
121 |
122 | @FXML
123 | private TextArea messagetxt;
124 |
125 | private Label msgID = new Label();
126 |
127 | public void fillMessage() {
128 |
129 | String name = message.getName() + " (" + message.getType() + ")";
130 | String dt = message.getDate();
131 | String sbjct = message.getSubject();
132 | String msg = message.getMessage();
133 | String msgid = message.getID();
134 |
135 | newSysUser.setMessageRead(msgid);
136 | msgID.setText(msgid);
137 |
138 | senderName.setText(name);
139 | date.setText(dt);
140 | subject.setText(sbjct);
141 | messagetxt.setText(msg);
142 |
143 | }
144 |
145 | public void showSuccessIndicator() {
146 | Stage stage = new Stage();
147 | SuccessIndicatorController success = new SuccessIndicatorController();
148 | Scene scene = new Scene(success);
149 | stage.setScene(scene);
150 |
151 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
152 | // set Stage boundaries to visible bounds of the main screen
153 | stage.setX(primaryScreenBounds.getMinX());
154 | stage.setY(primaryScreenBounds.getMinY());
155 | stage.setWidth(primaryScreenBounds.getWidth());
156 | stage.setHeight(primaryScreenBounds.getHeight());
157 |
158 | stage.initStyle(StageStyle.UNDECORATED);
159 | scene.setFill(null);
160 | stage.initStyle(StageStyle.TRANSPARENT);
161 | stage.show();
162 | }
163 |
164 | }
165 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/PopupAsk.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
66 |
71 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
--------------------------------------------------------------------------------
/src/main/java/Receptionist/AllAppointmentsController.java:
--------------------------------------------------------------------------------
1 | package Receptionist;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import java.util.ArrayList;
8 | import java.util.HashMap;
9 | import javafx.event.ActionEvent;
10 | import javafx.scene.layout.AnchorPane;
11 | import javafx.stage.Stage;
12 | import org.controlsfx.control.textfield.TextFields;
13 |
14 | /**
15 | *
16 | * @author heshan
17 | */
18 | public class AllAppointmentsController extends AnchorPane {
19 |
20 | private Receptionist receptionist;
21 |
22 | public AllAppointmentsController(Receptionist receptionist) {
23 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/AllAppointments.fxml"));
24 | fxmlLoader.setRoot(this);
25 | fxmlLoader.setController(this);
26 |
27 | this.receptionist = receptionist;
28 |
29 | try {
30 | fxmlLoader.load();
31 | } catch (IOException exception) {
32 | throw new RuntimeException(exception);
33 | }
34 | }
35 |
36 | @FXML
37 | private ComboBox searchAppointmentCombo;
38 | @FXML
39 | private TextField searchValue;
40 | @FXML
41 | private Button searchButton;
42 |
43 | @FXML
44 | private ListView list1;
45 | @FXML
46 | private ListView list2;
47 | @FXML
48 | private ListView list3;
49 |
50 | @FXML
51 | private void search() {
52 | String value = searchValue.getText();
53 | String type = (String) searchAppointmentCombo.getSelectionModel().getSelectedItem();
54 | switch (type) {
55 | case "Doctor":
56 | type = "d";
57 | value = log.get(value);
58 | break;
59 | case "Patient ID":
60 | type = "p";
61 | break;
62 | case "Appointment ID":
63 | type = "a";
64 | break;
65 | }
66 |
67 | ArrayList> data = receptionist.getAppointmentDetails(type, value);
68 |
69 | list1.getItems().clear();
70 | list2.getItems().clear();
71 | list3.getItems().clear();
72 |
73 | try {
74 | int size = data.size();
75 | for (int i = 1; i < size; i++) {
76 | list1.getItems().add(data.get(i).get(4));
77 | if (type.equals("p"))
78 | list2.getItems().add(log2.get(data.get(i).get(4)));
79 | else if (type.equals("d"))
80 | list2.getItems().add(data.get(i).get(2) + " " + data.get(i).get(3));
81 | else
82 | list2.getItems().add(data.get(i).get(2) + " " + data.get(i).get(3));
83 | list3.getItems().add(data.get(i).get(1));
84 | }
85 | } catch (Exception e) {
86 | e.printStackTrace();
87 | }
88 |
89 | }
90 |
91 | @FXML
92 | private void bindSuggestions() {
93 | String type = (String) searchAppointmentCombo.getSelectionModel().getSelectedItem();
94 | ArrayList tmp = new ArrayList();
95 | switch (type) {
96 | case "Doctor":
97 | TextFields.bindAutoCompletion(searchValue, docNames);
98 | break;
99 | case "Patient ID":
100 | TextFields.bindAutoCompletion(searchValue, tmp);
101 | break;
102 | case "Appointment ID":
103 | TextFields.bindAutoCompletion(searchValue, tmp);
104 | break;
105 | }
106 |
107 | }
108 |
109 | @FXML
110 | private Button saveSuccess;
111 |
112 | @FXML
113 | private void saveSuccessExit(ActionEvent event) {
114 |
115 | Stage stage;
116 | if (event.getSource() == saveSuccess) {
117 | stage = (Stage) saveSuccess.getScene().getWindow();
118 | stage.close();
119 | }
120 | }
121 |
122 | @FXML
123 | private Button clearButton;
124 |
125 | @FXML
126 | private void clear() {
127 | list1.getItems().clear();
128 | list2.getItems().clear();
129 | list3.getItems().clear();
130 |
131 | searchValue.setText("");
132 |
133 | }
134 |
135 | @FXML
136 | private Label close;
137 |
138 | @FXML
139 | private void closeEditor() {
140 | Stage stage;
141 | stage = (Stage) close.getScene().getWindow();
142 | stage.close();
143 | }
144 |
145 | HashMap log;
146 | HashMap log2;
147 | ArrayList docNames;
148 |
149 | public void loadDoctorNames() {
150 | log = new HashMap();
151 | log2 = new HashMap();
152 | docNames = new ArrayList();
153 |
154 | ArrayList> data = receptionist.getDoctorDetails();
155 | int size = data.size();
156 |
157 | for (int i = 1; i < size; i++) {
158 | log.put(data.get(i).get(1) + " " + data.get(i).get(2), data.get(i).get(0));
159 | log2.put(data.get(i).get(0), data.get(i).get(1) + " " + data.get(i).get(2));
160 | docNames.add(data.get(i).get(1) + " " + data.get(i).get(2));
161 | }
162 |
163 | }
164 |
165 | public void load() {
166 | loadDoctorNames();
167 | }
168 |
169 | }
170 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/NewMessageController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import java.util.ArrayList;
8 | import java.util.HashMap;
9 | import javafx.event.ActionEvent;
10 | import javafx.geometry.Rectangle2D;
11 | import javafx.scene.Scene;
12 | import javafx.scene.layout.AnchorPane;
13 | import javafx.stage.Screen;
14 | import javafx.stage.Stage;
15 | import javafx.stage.StageStyle;
16 | import org.controlsfx.control.textfield.TextFields;
17 |
18 | /**
19 | *
20 | * @author heshan
21 | */
22 | public class NewMessageController extends AnchorPane {
23 |
24 | private User newSysUser;
25 |
26 | public NewMessageController(User newSysUser) {
27 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/NewMessage.fxml"));
28 | fxmlLoader.setRoot(this);
29 | fxmlLoader.setController(this);
30 |
31 | this.newSysUser = newSysUser;
32 |
33 | try {
34 | fxmlLoader.load();
35 | } catch (IOException exception) {
36 | throw new RuntimeException(exception);
37 | }
38 | }
39 |
40 | @FXML
41 | private Button saveSuccess;
42 |
43 | @FXML
44 | private void saveSuccessExit(ActionEvent event) {
45 |
46 | Stage stage;
47 | if (event.getSource() == saveSuccess) {
48 | stage = (Stage) saveSuccess.getScene().getWindow();
49 | stage.close();
50 | }
51 | }
52 |
53 | @FXML
54 | public TextField receivertxt;
55 | @FXML
56 | private TextField subjecttxt;
57 | @FXML
58 | private TextArea messagetxt;
59 |
60 | private HashMap log;
61 |
62 | public void loadUserNames() {
63 |
64 | ArrayList> data = newSysUser.getUserNameAndID();
65 |
66 | log = new HashMap();
67 | ArrayList possibleSuggestions = new ArrayList();
68 |
69 | int size = data.size();
70 | for (int i = 1; i < size; i++) {
71 | log.put(data.get(i).get(0) + " " + data.get(i).get(1), data.get(i).get(3) + " " + data.get(i).get(2));
72 | possibleSuggestions.add(data.get(i).get(3) + " " + data.get(i).get(0) + " " + data.get(i).get(1));
73 | }
74 |
75 | TextFields.bindAutoCompletion(receivertxt, possibleSuggestions);
76 |
77 | }
78 |
79 | @FXML
80 | public TextField userid;
81 | @FXML
82 | private TextField type;
83 |
84 | @FXML
85 | private void getName() {
86 |
87 | try {
88 | String data[] = receivertxt.getText().split(" ");
89 | if (data.length == 3) {
90 | receivertxt.setText(" " + data[1] + " " + data[2]);
91 |
92 | userid.setText(log.get(data[1] + " " + data[2]).split(" ")[0]);
93 | type.setText(log.get(data[1] + " " + data[2]).split(" ")[1]);
94 | }
95 |
96 | } catch (Exception e) {
97 | }
98 |
99 | }
100 |
101 | @FXML
102 | private Button clearButton;
103 |
104 | @FXML
105 | private void clear() {
106 | receivertxt.setText("");
107 | subjecttxt.setText("");
108 | messagetxt.setText("");
109 |
110 | userid.setText("");
111 | type.setText("");
112 | }
113 |
114 | @FXML
115 | private Button sendButton;
116 |
117 | @FXML
118 | private void send() {
119 |
120 | String senderID = newSysUser.userID;
121 | String subject = subjecttxt.getText();
122 | String message = messagetxt.getText();
123 | String receiver = userid.getText();
124 |
125 | boolean result = true;
126 | result = newSysUser.sendMessage(senderID, receiver, subject, message);
127 |
128 | if (result) {
129 | Stage stage;
130 | stage = (Stage) close.getScene().getWindow();
131 | stage.close();
132 | showSuccessIndicator();
133 | }
134 |
135 | }
136 |
137 | @FXML
138 | private Label close;
139 |
140 | @FXML
141 | private void closeEditor() {
142 | Stage stage;
143 | stage = (Stage) close.getScene().getWindow();
144 | stage.close();
145 | }
146 |
147 | public void load(String msgid) {
148 |
149 | if (!msgid.equals("")) {
150 |
151 | ArrayList> data = newSysUser.getUserNameAndID();
152 |
153 | String userId = newSysUser.getMessageSenderInfo(msgid);
154 | int size = data.size();
155 |
156 | for (int i = 1; i < size; i++) {
157 | if (data.get(i).get(3).equals(userId)) {
158 | receivertxt.setText(" " + data.get(i).get(0) + " " + data.get(i).get(1));
159 | type.setText(data.get(i).get(2));
160 | }
161 | }
162 |
163 | userid.setText(userId);
164 |
165 | }
166 |
167 | loadUserNames();
168 | }
169 |
170 | public void showSuccessIndicator() {
171 | Stage stage = new Stage();
172 | SuccessIndicatorController success = new SuccessIndicatorController();
173 | Scene scene = new Scene(success);
174 | stage.setScene(scene);
175 |
176 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
177 | // set Stage boundaries to visible bounds of the main screen
178 | stage.setX(primaryScreenBounds.getMinX());
179 | stage.setY(primaryScreenBounds.getMinY());
180 | stage.setWidth(primaryScreenBounds.getWidth());
181 | stage.setHeight(primaryScreenBounds.getHeight());
182 |
183 | stage.initStyle(StageStyle.UNDECORATED);
184 | scene.setFill(null);
185 | stage.initStyle(StageStyle.TRANSPARENT);
186 | stage.show();
187 | }
188 |
189 | }
190 |
--------------------------------------------------------------------------------
/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 4.0.0
4 |
5 | com.hms
6 | hms_test_2
7 | 1.0-SNAPSHOT
8 | jar
9 |
10 | HealthPlus
11 |
12 |
13 | UTF-8
14 | com.hms.hms_test_2.MainApp
15 | 17.0.10
16 |
17 |
18 |
19 | HealthPlus
20 |
21 |
22 |
23 |
24 |
25 |
26 | org.openjfx
27 | javafx-maven-plugin
28 | 0.0.8
29 |
30 | com.hms.hms_test_2.MainApp
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 | org.apache.maven.plugins
47 | maven-compiler-plugin
48 | 3.11.0
49 |
50 | 17
51 | 17
52 |
53 |
54 |
55 |
56 |
57 | org.apache.maven.plugins
58 | maven-surefire-plugin
59 | 3.0.0
60 |
61 |
62 | --module-path ${java.home}/lib --add-modules javafx.controls,javafx.fxml
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 | org.openjfx
72 | javafx-controls
73 | ${javafx.version}
74 |
75 |
76 | org.openjfx
77 | javafx-fxml
78 | ${javafx.version}
79 |
80 |
81 | org.openjfx
82 | javafx-base
83 | ${javafx.version}
84 |
85 |
86 |
87 | de.jensd
88 | fontawesomefx-fontawesome
89 | 4.7.0-9.1.2
90 |
91 |
92 | org.controlsfx
93 | controlsfx
94 | 11.1.2
95 |
96 |
97 | org.jfxtras
98 | jfxtras-common
99 | 8.0-r5
100 |
101 |
102 | org.jfxtras
103 | jfxtras-fxml
104 | 8.0-r5
105 |
106 |
107 | org.jfxtras
108 | jfxtras-controls
109 | 8.0-r5
110 |
111 |
112 | org.jfxtras
113 | jfxtras-window
114 | 8.0-r5
115 |
116 |
117 | org.jfxtras
118 | jfxtras-menu
119 | 8.0-r5
120 |
121 |
122 | org.jfxtras
123 | jfxtras-labs
124 | 8.0-r5
125 |
126 |
127 | org.mariadb.jdbc
128 | mariadb-java-client
129 | 1.1.7
130 |
131 |
132 | junit
133 | junit
134 | 4.12
135 | test
136 |
137 |
138 | org.hamcrest
139 | hamcrest-core
140 | 1.3
141 | test
142 |
143 |
144 | org.apache.maven.shared
145 | maven-shared-utils
146 | 3.3.4
147 | jar
148 |
149 |
150 |
151 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/Logout.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
66 |
67 |
68 |
75 |
83 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/src/main/java/Admin/SysUserController.java:
--------------------------------------------------------------------------------
1 | package Admin;
2 |
3 | import com.hms.hms_test_2.SuccessIndicatorController;
4 | import javafx.fxml.FXML;
5 | import javafx.scene.control.*;
6 | import javafx.fxml.FXMLLoader;
7 | import java.io.IOException;
8 | import java.time.LocalDate;
9 | import java.time.format.DateTimeFormatter;
10 | import java.util.ArrayList;
11 | import javafx.event.ActionEvent;
12 | import javafx.geometry.Rectangle2D;
13 | import javafx.scene.Scene;
14 | import javafx.scene.layout.AnchorPane;
15 | import javafx.stage.Screen;
16 | import javafx.stage.Stage;
17 | import javafx.stage.StageStyle;
18 |
19 | /**
20 | *
21 | * @author heshan
22 | */
23 | public class SysUserController extends AnchorPane {
24 |
25 | private AdminController admin;
26 | private String userID;
27 |
28 | public SysUserController(AdminController admin, String userID) {
29 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/SysUser.fxml"));
30 | fxmlLoader.setRoot(this);
31 | fxmlLoader.setController(this);
32 |
33 | this.admin = admin;
34 | this.userID = userID;
35 |
36 | try {
37 | fxmlLoader.load();
38 | } catch (IOException exception) {
39 | throw new RuntimeException(exception);
40 | }
41 | }
42 |
43 | @FXML
44 | private Button suspendButton;
45 | @FXML
46 | private Button editButton;
47 |
48 | @FXML
49 | private Label userType;
50 |
51 | @FXML
52 | private TextField firstName;
53 | @FXML
54 | private TextField lastName;
55 | @FXML
56 | private TextField address;
57 | @FXML
58 | private TextField NIC;
59 | @FXML
60 | private DatePicker DOB;
61 | @FXML
62 | private TextField mobile;
63 | @FXML
64 | private TextField email;
65 | @FXML
66 | private ComboBox gender;
67 |
68 | @FXML
69 | private TextField username;
70 | @FXML
71 | private TextField userid;
72 |
73 | public void loadInfo() {
74 | ArrayList> data = admin.admin.getSysUser(userID);
75 |
76 | String type = data.get(1).get(13);
77 |
78 | switch (type) {
79 | case "doctor":
80 | type = "Doctor";
81 | break;
82 | case "lab_assistant":
83 | type = "Lab Assistant";
84 | break;
85 | case "pharmacist":
86 | type = "Pharmacist";
87 | break;
88 | case "cashier":
89 | type = "Cashier";
90 | break;
91 | case "receptionist":
92 | type = "Receptionist";
93 | break;
94 | }
95 |
96 | userType.setText(type);
97 |
98 | firstName.setText(data.get(1).get(7));
99 | lastName.setText(data.get(1).get(8));
100 | address.setText(data.get(1).get(5));
101 | NIC.setText(data.get(1).get(2));
102 |
103 | String date = data.get(1).get(4);
104 | DateTimeFormatter fomatter1 = DateTimeFormatter.ofPattern("yyyy-MM-dd");
105 | LocalDate birth = LocalDate.parse(date, fomatter1);
106 |
107 | DOB.setValue(birth);
108 |
109 | mobile.setText(data.get(1).get(6));
110 | email.setText(data.get(1).get(9));
111 |
112 | type = data.get(1).get(13);
113 |
114 | switch (type) {
115 | case "m":
116 | type = "Male";
117 | break;
118 | case "f":
119 | type = "Female";
120 | break;
121 | }
122 |
123 | gender.getSelectionModel().select(type);
124 |
125 | username.setText(data.get(1).get(12));
126 | userid.setText(userID);
127 |
128 | String suspend = data.get(1).get(15);
129 | if (suspend.equals("1"))
130 | suspendButton.setText("unsuspend");
131 |
132 | }
133 |
134 | @FXML
135 | private void suspend() {
136 | String suspend = suspendButton.getText();
137 |
138 | if (suspend.equals("suspend")) {
139 | String userId = userid.getText();
140 | admin.admin.suspendUser(userId);
141 |
142 | } else {
143 | String userId = userid.getText();
144 | admin.admin.unsuspendUser(userId);
145 | }
146 |
147 | admin.fillStorageInfo();
148 | Stage stage;
149 | stage = (Stage) close.getScene().getWindow();
150 | stage.close();
151 | showSuccessIndicator();
152 | }
153 |
154 | @FXML
155 | private Button resetPasswordButton;
156 |
157 | @FXML
158 | private void resetPassword() {
159 | String user = userid.getText();
160 | boolean result = admin.admin.resetPassword(user);
161 | if (result)
162 | showSuccessIndicator();
163 |
164 | }
165 |
166 | @FXML
167 | private Button saveSuccess;
168 |
169 | @FXML
170 | private void saveSuccessExit(ActionEvent event) {
171 |
172 | Stage stage;
173 | if (event.getSource() == saveSuccess) {
174 | stage = (Stage) saveSuccess.getScene().getWindow();
175 | stage.close();
176 | }
177 | }
178 |
179 | @FXML
180 | private Label close;
181 |
182 | @FXML
183 | private void closeEditor() {
184 | Stage stage;
185 | stage = (Stage) close.getScene().getWindow();
186 | stage.close();
187 | }
188 |
189 | public void load() {
190 | loadInfo();
191 | }
192 |
193 | public void showSuccessIndicator() {
194 | Stage stage = new Stage();
195 | SuccessIndicatorController success = new SuccessIndicatorController();
196 | Scene scene = new Scene(success);
197 | stage.setScene(scene);
198 |
199 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
200 | // set Stage boundaries to visible bounds of the main screen
201 | stage.setX(primaryScreenBounds.getMinX());
202 | stage.setY(primaryScreenBounds.getMinY());
203 | stage.setWidth(primaryScreenBounds.getWidth());
204 | stage.setHeight(primaryScreenBounds.getHeight());
205 |
206 | stage.initStyle(StageStyle.UNDECORATED);
207 | scene.setFill(null);
208 | stage.initStyle(StageStyle.TRANSPARENT);
209 | stage.show();
210 | }
211 |
212 | }
213 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/Validate.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import java.util.*;
4 |
5 | public class Validate {
6 | private static final String EMAIL_REGEX = "^[\\w-_\\.+]*[\\w-_\\.]\\@([\\w]+\\.)+[\\w]+[\\w]$";
7 |
8 | /**
9 | *
10 | * @param nic National Identity Card No
11 | * @return empty ArrayList with birth year, days and gender
12 | * respectively
13 | * ArrayList is empty if the string is not an nic no
14 | *
15 | */
16 | public static ArrayList NIC(String nic) {
17 | ArrayList result = new ArrayList();
18 | // Checking the length of the String
19 | if (nic.length() == 10) {
20 | char V = nic.charAt(9);
21 | // checking the last character
22 | if ((V == 'V') || (V == 'v')) {
23 | try {
24 |
25 | int yearPart = Integer.parseInt(nic.substring(0, 2));
26 | int dayPart = Integer.parseInt(nic.substring(2, 5));
27 |
28 | String birthYear = "19" + yearPart;
29 | String gender = "m";
30 | if (dayPart > 500) {
31 | gender = "f";
32 | dayPart -= 500;
33 | }
34 | result.add(birthYear);
35 | result.add(Integer.toString(dayPart));
36 | result.add(gender);
37 |
38 | } catch (Exception e) {
39 | }
40 | }
41 | }
42 | return result;
43 | }
44 |
45 | /**
46 | *
47 | * @param mob mobile number
48 | * @return String "1" if correct else return correct format
49 | */
50 | public static String mobile(String mob) {
51 | String result = "0xx-xxx-xxxx";
52 |
53 | if (mob.length() == 10) {
54 | result = "1";
55 | int x;
56 | for (int j = 0; j < mob.length(); j++) {
57 | x = (int) mob.charAt(j);
58 | if (x < 48 || x > 57)
59 | result = "0xx-xxx-xxxx";
60 | }
61 |
62 | }
63 | return result;
64 | }
65 |
66 | /**
67 | *
68 | * @param patientID Patient ID of the patient
69 | * @return String "1" if correct else return correct format
70 | */
71 | public static String patientID(String patientID) {
72 | String result = "hmsxxxxpa";
73 |
74 | if (patientID.length() == 9) {
75 | if (patientID.substring(0, 3).equals("hms")) {
76 | if (patientID.substring(7, 9).equals("pa")) {
77 | result = "1";
78 | }
79 | }
80 | }
81 | return result;
82 | }
83 |
84 | /**
85 | *
86 | * @param email email
87 | * @return String "1" if correct else return correct format
88 | */
89 | public static String email(String email) {
90 | String result = "1";
91 | Boolean match = email.matches(EMAIL_REGEX);
92 | if (!match) {
93 | result = "abc@mail.com";
94 | }
95 | return result;
96 | }
97 |
98 | public static String testID(String patientID) {
99 | String result = "hmsxxxxpa";
100 |
101 | if (patientID.length() == 9) {
102 | if (patientID.substring(0, 3).equals("hms")) {
103 | if (patientID.substring(7, 9).equals("pa")) {
104 | result = "1";
105 | }
106 | }
107 | }
108 | return result;
109 | }
110 |
111 | /**
112 | *
113 | * @param value as a String
114 | * @return true or false
115 | */
116 | public static boolean checkInt(String value) {
117 | boolean result = false;
118 |
119 | try {
120 | Integer.parseInt(value);
121 | result = true;
122 | } catch (Exception e) {
123 | result = false;
124 | }
125 |
126 | return result;
127 | }
128 |
129 | /**
130 | *
131 | * @param value
132 | * @return
133 | */
134 | public static String appointmentID(String patientID) {
135 | String result = "1";
136 |
137 | if (patientID.length() == 6) {
138 | if (patientID.substring(0, 3).equals("app")) {
139 | if (checkInt(patientID.substring(3, 6)) == true) {
140 | result = "1";
141 | } else {
142 | result = "appxxx";
143 | }
144 | } else
145 | result = "appxxx";
146 |
147 | } else if (patientID.length() == 7) {
148 |
149 | if (patientID.substring(0, 4).equals("lapp")) {
150 | if (checkInt(patientID.substring(4, 7)) == true) {
151 | result = "1";
152 | } else {
153 | result = "appxxx";
154 | }
155 | } else
156 | result = "lappxxx";
157 | } else if (patientID.length() > 7) {
158 |
159 | result = "appxxx";
160 | }
161 | return result;
162 | }
163 | }
164 |
--------------------------------------------------------------------------------
/src/main/java/LabAssistant/LabReportPreviewController.java:
--------------------------------------------------------------------------------
1 | package LabAssistant;
2 |
3 | import java.io.IOException;
4 | import java.text.SimpleDateFormat;
5 | import java.util.ArrayList;
6 | import java.util.Calendar;
7 | import java.util.Date;
8 | import javafx.collections.FXCollections;
9 | import javafx.collections.ObservableList;
10 | import javafx.event.ActionEvent;
11 | import javafx.fxml.FXML;
12 | import javafx.fxml.FXMLLoader;
13 | import javafx.scene.control.Button;
14 | import javafx.scene.control.TableView;
15 | import javafx.scene.layout.AnchorPane;
16 | import javafx.stage.Stage;
17 |
18 | public class LabReportPreviewController extends AnchorPane {
19 |
20 | @FXML
21 | private LabAssistant lab;
22 |
23 | public LabReportPreviewController(LabAssistant lab) {
24 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/LabReportPreview.fxml"));
25 | fxmlLoader.setRoot(this);
26 | fxmlLoader.setController(this);
27 |
28 | this.lab = lab;
29 |
30 | try {
31 | fxmlLoader.load();
32 | } catch (IOException exception) {
33 | throw new RuntimeException(exception);
34 | }
35 | }
36 |
37 | @FXML
38 | TableView report;
39 |
40 | public void setData(ArrayList> data, String type) {
41 | ObservableList data2 = FXCollections.observableArrayList();
42 |
43 | String[] urArray = {
44 | "Test ID", "prescription_id", "Appearance", "S.G (Refractometer)",
45 | "PH", "Protein", "Glucose", "Ketone Bodies", "Bilirubin", "Urobilirubin",
46 | "Contrifuged Depositsphase Contrast Microscopy", "Pus Cells",
47 | "Red Cells", "Epithelial Cells", "Casts", "Cristals"
48 | };
49 |
50 | String[] liArray = {
51 | "Test ID", "prescription_id", "Cholestrol HDL", "cholestrolLDL",
52 | "Triglycerides", "Cholestrol LDL/HDL Ratio"
53 | };
54 |
55 | String[] bgArray = {
56 | "Test ID", "prescription_id", "Blood Group", "Rhesus D"
57 | };
58 |
59 | String[] cbcArray = {
60 | "Test ID", "prescription_id", "Total White Cell Count", "Differential Count",
61 | "Neutrophils", "Lymphocytes", "Monocytes", "Eosonophils", "Basophils",
62 | "Haemoglobin", "Red Blood Cells", "Mean Cell Volume", "Haematocrit", "Mean Cell Haemoglobin",
63 | "M.C.H Concentration", "Red Cells Distribution Width", "Platelet Count"
64 | };
65 |
66 | String[] lvArray = {
67 | "Test ID", "prescription_id", "Total Protein", "Albumin", "Globulin",
68 | "Total Bilirubin", "Direct Bilirubin", "SGOT(AST)", "SGPT(ALT)", "Alkaline Phospates"
69 | };
70 |
71 | String[] reArray = {
72 | "Test ID", "prescription_id", "Creatinine", "Urea", "Total Bilirubin",
73 | "Direct Bilirubin", "SGOT(AST)", "SGPT(ALT)", "Alkaline Phospates"
74 | };
75 |
76 | String[] scptArray = {
77 | "Test ID", "prescription_id", "CPK Total"
78 | };
79 |
80 | String[] scpArray = {
81 | "Test ID", "prescription_id", "HIV 1 & 2 ELISA"
82 | };
83 |
84 | String[] tmpArray = null;
85 |
86 | switch (type) {
87 | case "ur":
88 | tmpArray = urArray;
89 | break;
90 | case "li":
91 | tmpArray = liArray;
92 | break;
93 | case "bg":
94 | tmpArray = bgArray;
95 | break;
96 | case "cbc":
97 | tmpArray = cbcArray;
98 | break;
99 | case "lv":
100 | tmpArray = lvArray;
101 | break;
102 | case "re":
103 | tmpArray = reArray;
104 | break;
105 | case "scpt":
106 | tmpArray = scptArray;
107 | break;
108 | case "scp":
109 | tmpArray = scpArray;
110 | break;
111 | }
112 |
113 | if (tmpArray != null) {
114 | int size = data.get(0).size();
115 | String tmp = data.get(1).get(size - 2);
116 | ArrayList> data4 = lab.getPatientInfo(tmp);
117 |
118 | data2.add(new LabReport("Name", data4.get(1).get(0) + " " + data4.get(1).get(1)));
119 |
120 | String tmpGen = data4.get(1).get(2);
121 | if (tmpGen.equals("m")) {
122 | tmpGen = "Male";
123 | } else {
124 | tmpGen = "Female";
125 | }
126 | data2.add(new LabReport("Gender", tmpGen));
127 |
128 | try {
129 | SimpleDateFormat tmpdataformat = new SimpleDateFormat("yyyy-MM-dd");
130 | Date birth = tmpdataformat.parse(data4.get(1).get(3));
131 | Calendar calendarBirth = Calendar.getInstance();
132 | calendarBirth.setTime(birth);
133 | Calendar calendarToday = Calendar.getInstance();
134 | String tmpage = Integer.toString(calendarToday.get(Calendar.YEAR) - calendarBirth.get(Calendar.YEAR));
135 |
136 | data2.add(new LabReport("Age", tmpage));
137 |
138 | } catch (Exception e) {
139 | e.printStackTrace();
140 | }
141 |
142 | data2.add(new LabReport("", ""));
143 | data2.add(new LabReport(tmpArray[0], data.get(1).get(0)));
144 | data2.add(new LabReport("", ""));
145 |
146 | for (int i = 1; i < size; i++) {
147 | System.out.println(i);
148 | if ((i != 1) && (i != size - 2) && (i != size - 1)) {
149 | data2.add(new LabReport(tmpArray[i] + " (g/dL)", data.get(1).get(i)));
150 | } else if (i == size - 2) {
151 | data2.add(new LabReport("", ""));
152 | } else if (i == size - 1) {
153 | data2.add(new LabReport("Date", data.get(1).get(i)));
154 | }
155 |
156 | }
157 | report.setItems(data2);
158 | }
159 | }
160 |
161 | @FXML
162 | private Button closeAccounts;
163 |
164 | @FXML
165 | private void closeViewAccounts(ActionEvent event) {
166 |
167 | Stage stage;
168 | if (event.getSource() == closeAccounts) {
169 | stage = (Stage) closeAccounts.getScene().getWindow();
170 | stage.close();
171 | }
172 | }
173 |
174 | }
175 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/LabReportPreview.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
--------------------------------------------------------------------------------
/src/main/java/com/hms/hms_test_2/AllMessagesController.java:
--------------------------------------------------------------------------------
1 | package com.hms.hms_test_2;
2 |
3 | import javafx.fxml.FXML;
4 | import javafx.scene.control.*;
5 | import javafx.fxml.FXMLLoader;
6 | import java.io.IOException;
7 | import java.util.ArrayList;
8 | import javafx.collections.FXCollections;
9 | import javafx.collections.ObservableList;
10 | import javafx.geometry.Rectangle2D;
11 | import javafx.scene.Scene;
12 | import javafx.scene.control.cell.PropertyValueFactory;
13 | import javafx.scene.image.Image;
14 | import javafx.scene.image.ImageView;
15 | import javafx.scene.layout.AnchorPane;
16 | import javafx.stage.Screen;
17 | import javafx.stage.Stage;
18 | import javafx.stage.StageStyle;
19 |
20 | /**
21 | *
22 | * @author heshan
23 | */
24 | public class AllMessagesController extends AnchorPane {
25 |
26 | private User newSysUser;
27 |
28 | public AllMessagesController(User newSysUser) {
29 | FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/AllMessages.fxml"));
30 | fxmlLoader.setRoot(this);
31 | fxmlLoader.setController(this);
32 |
33 | this.newSysUser = newSysUser;
34 |
35 | try {
36 | fxmlLoader.load();
37 | } catch (IOException exception) {
38 | throw new RuntimeException(exception);
39 | }
40 | }
41 |
42 | @FXML
43 | TableView messagesTable;
44 |
45 | public void loadMessages() {
46 | ArrayList> data = newSysUser.getMessages();
47 | int noOfMessages = data.size();
48 |
49 | ObservableList msgList = FXCollections.observableArrayList();
50 | Image img;
51 |
52 | for (int i = 1; i < noOfMessages; i++) {
53 | ArrayList row = data.get(i);
54 |
55 | String sender = row.get(0);
56 | String subject = row.get(1);
57 | String message = row.get(2);
58 | String date = row.get(3);
59 | String read = row.get(4);
60 | String id = row.get(5);
61 |
62 | ImageView imageView2;
63 | Image img2;
64 | if (read.equals("0")) {
65 | img2 = new Image(getClass().getResource("/imgs/msgunread.png").toString(), true);
66 | } else {
67 | img2 = new Image(getClass().getResource("/imgs/msgread.png").toString(), true);
68 | }
69 | imageView2 = new ImageView(img2);
70 | imageView2.setFitHeight(25);
71 | imageView2.setFitWidth(25);
72 | imageView2.setPreserveRatio(true);
73 |
74 | ArrayList> data2 = newSysUser.getName(sender);
75 |
76 | String name = data2.get(1).get(0) + " " + data2.get(1).get(1);
77 | String user = data2.get(1).get(2);
78 |
79 | // getting the profile picture
80 | try {
81 | String image = newSysUser.getProfilePic(sender);
82 | img = new Image(getClass().getResource("/imgs/profilePics/" + image).toString(), true);
83 | } catch (Exception e) {
84 | img = new Image(getClass().getResource("/imgs/profilePics/p2.png").toString(), true);
85 | }
86 | ImageView imageView = new ImageView(img);
87 | imageView.setFitHeight(35);
88 | imageView.setFitWidth(35);
89 | imageView.setPreserveRatio(true);
90 |
91 | AllMessages msg = new AllMessages(imageView,
92 | name + " (" + user + ") " + "\n" + subject + "\n" + date,
93 | imageView2, sender, message, date, subject, name, user, id);
94 | msgList.add(msg);
95 |
96 | }
97 |
98 | TableColumn pic = new TableColumn<>("profile");
99 | pic.setCellValueFactory(new PropertyValueFactory<>("image"));
100 | pic.prefWidthProperty().bind(messagesTable.widthProperty().divide(8));
101 | pic.setResizable(false);
102 |
103 | TableColumn msg = new TableColumn<>("Message");
104 | msg.setCellValueFactory(new PropertyValueFactory<>("string"));
105 | msg.prefWidthProperty().bind(messagesTable.widthProperty().divide(1.5));
106 | msg.setResizable(true);
107 |
108 | TableColumn read = new TableColumn<>("");
109 | read.setCellValueFactory(new PropertyValueFactory<>("image2"));
110 | read.prefWidthProperty().bind(messagesTable.widthProperty().divide(8));
111 | read.setResizable(false);
112 |
113 | messagesTable.getColumns().add(pic);
114 | messagesTable.getColumns().add(msg);
115 | messagesTable.getColumns().add(read);
116 | messagesTable.setItems(msgList);
117 |
118 | }
119 |
120 | @FXML
121 | private Button newMessageButton;
122 |
123 | @FXML
124 | private void newMessage() {
125 | Stage stage = new Stage();
126 | NewMessageController newMessage = new NewMessageController(newSysUser);
127 | newMessage.load("");
128 | Scene scene = new Scene(newMessage);
129 | stage.setScene(scene);
130 |
131 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
132 | // set Stage boundaries to visible bounds of the main screen
133 | stage.setX(primaryScreenBounds.getMinX());
134 | stage.setY(primaryScreenBounds.getMinY());
135 | stage.setWidth(primaryScreenBounds.getWidth());
136 | stage.setHeight(primaryScreenBounds.getHeight());
137 |
138 | stage.initStyle(StageStyle.UNDECORATED);
139 | scene.setFill(null);
140 | stage.initStyle(StageStyle.TRANSPARENT);
141 | stage.show();
142 | }
143 |
144 | @FXML
145 | private void showMessage() {
146 | AllMessages message = (AllMessages) messagesTable.getSelectionModel().getSelectedItem();
147 |
148 | Stage stage = new Stage();
149 | ReadMessageController newMessage = new ReadMessageController(message, newSysUser);
150 | newMessage.fillMessage();
151 | Scene scene = new Scene(newMessage);
152 | stage.setScene(scene);
153 |
154 | Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
155 | // set Stage boundaries to visible bounds of the main screen
156 | stage.setX(primaryScreenBounds.getMinX());
157 | stage.setY(primaryScreenBounds.getMinY());
158 | stage.setWidth(primaryScreenBounds.getWidth());
159 | stage.setHeight(primaryScreenBounds.getHeight());
160 |
161 | stage.initStyle(StageStyle.UNDECORATED);
162 | scene.setFill(null);
163 | stage.initStyle(StageStyle.TRANSPARENT);
164 | stage.show();
165 |
166 | }
167 | }
168 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/ReadMessage.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
68 |
78 |
83 |
96 |
101 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/PatientAccountSuccess.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
72 |
77 |
82 |
87 |
92 |
97 |
102 |
107 |
108 |
109 |
110 |
111 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/AppointmentSuccess.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
72 |
77 |
82 |
87 |
92 |
97 |
102 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
--------------------------------------------------------------------------------
/src/main/resources/fxml/RefundTable.fxml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
--------------------------------------------------------------------------------
/src/main/resources/styles/tabbedPane4.css:
--------------------------------------------------------------------------------
1 | .tab-pane
2 | {
3 | -fx-tab-min-width: 30px; /* 55 */
4 | -fx-tab-max-width: 30px; /* 55 */
5 | -fx-tab-min-height: 140px; /* 24 */
6 | -fx-tab-max-height: 140px; /* 24 */
7 |
8 | -fx-focus-color: transparent;
9 | -fx-faint-focus-color: transparent;
10 |
11 | }
12 |
13 | .tab .tab-label
14 | {
15 | -fx-background-color: transparent;
16 | -fx-alignment: CENTER;
17 | -fx-text-fill: #999999;
18 | }
19 |
20 | .tab:selected .tab-label
21 | {
22 | -fx-text-fill: #ffffff;
23 | }
24 |
25 | .tab *.tab-label .text {
26 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
27 | -fx-rotate: 90;
28 | -fx-font-size: 12;
29 | -fx-alignment:BOTTOM_LEFT;
30 | -fx-width:200px;
31 | }
32 |
33 |
34 | .tab-content-area
35 | {
36 | -fx-background-color: -fx-control-inner-background;
37 | -fx-padding: 0.0em; /* 0 */
38 | /* -fx-opacity: -fx-disabled-opacity;*/
39 |
40 | }
41 | .tab
42 | {
43 | /* This is how it is done in Button, but the -1 inset caused a white line */
44 | /* to appear beneath the tab, which looks bad, so it's taken out below. */
45 | /* -fx-background-color: -fx-shadow-highlight-color, -fx-tab-border-color, -fx-inner-border, -fx-body-color;
46 | -fx-background-radius: 5 5 0 0, 5 5 0 0, 4 4 0 0, 3 3 0 0;
47 | -fx-background-insets: 0 0 -1 0, 0, 1, 2;*/
48 | -fx-background-insets: 0, 1, 2;
49 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
50 | -fx-padding: 0em 0.5em 0.083333em 0.5em; /* 1 6 1 6 */
51 | /* -fx-text-fill: -fx-text-base-color;*/
52 | -fx-border-width: 0 0 0 2; -fx-border-color: #444 #444 #000 #555 ;
53 | }
54 | /*
55 | .tab:top
56 | {
57 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
58 | }
59 | .tab:right
60 | {
61 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
62 | }
63 | .tab:bottom
64 | {
65 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
66 | }
67 | */
68 | .tab:left
69 | {
70 | /*
71 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
72 | */
73 | -fx-background-color: #444;
74 | }
75 | .tab:hover
76 | {
77 | -fx-background-color: #333;
78 | -fx-border-width: 0 2 0 2; -fx-border-color: #444 #222 #000 #555 ;
79 | -fx-cursor:hand;
80 | }
81 |
82 | .tab:selected
83 | {
84 | -fx-text-fill: #223;
85 | -fx-background-color: #222; /*linear-gradient(#424141 0%, #ffffff 100%);
86 | /*-fx-background-color: #ffffff;
87 | -fx-background-color: white;*/
88 | /* -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
89 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
90 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
91 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
92 | */
93 | -fx-background-insets: 0, 1 1 0 1;
94 | -fx-background-radius: 0 0 0 0, 0 0 0 0;
95 | -fx-border-color: transparent;
96 | /*-fx-border-style: none;*/
97 | -fx-background-insets: 0, 1, 2;
98 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
99 | -fx-padding: 0em 0.5em 0.083333em 0.5em;
100 | }
101 | .tab:disabled
102 | {
103 | -fx-opacity: -fx-disabled-opacity;
104 | }
105 | .tab:disabled:hover
106 | {
107 | -fx-color: -fx-base;
108 | -fx-opacity: -fx-disabled-opacity;
109 | -fx-cursor:hand;
110 | }
111 | .tab-pane *.tab-header-background
112 | {/*
113 | -fx-background-color: -fx-outer-border, -fx-inner-border, derive(-fx-color, -20%);
114 | -fx-effect: innershadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0 , 0);
115 | */
116 | -fx-background-color: #444;
117 | }
118 | /*.tab-pane *.tab-header-area {*/
119 | /* I would like to use -fx-tab-border-color here, but for some reason it */
120 | /* just isn't the correct color, even though it works in :top above */
121 | /* -fx-background-color: -fx-tab-border-color, lightgray;*/
122 | /*}*/
123 | .tab-pane:top *.tab-header-area
124 | {
125 | -fx-background-insets: 0, 0 0 1 0;
126 | -fx-padding: 0.416667em 0.166667em 0.0em 0.833em; /* 5 2 0 10 */
127 | }
128 | .tab-pane:bottom *.tab-header-area
129 | {
130 | -fx-background-insets: 0, 1 0 0 0;
131 | -fx-padding: 0 0.166667em 0.416667em 0.833em; /* 0 2 5 0 */
132 | }
133 | .tab-pane:left *.tab-header-area
134 | {
135 | -fx-background-insets: 0, 0 1 0 0;
136 | -fx-padding: 0.833em 0.0em 0.166667em 0.416667em; /* 10 0 2 5 */
137 | }
138 | .tab-pane:right *.tab-header-area
139 | {
140 | -fx-background-insets: 0, 0 0 0 1;
141 | -fx-padding: 0.833em 0.416667em 0.166667em 0.0em; /* 10 5 2 0 */
142 | }
143 | .tab-pane .headers-region
144 | {
145 | -fx-effect: dropshadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0, 0);
146 | }
147 | /* TODO: scaling the shape seems to make it way too large */
148 | .tab-close-button
149 | {
150 | -fx-background-color: -fx-mark-color;
151 | -fx-shape: "M 0,0 H1 L 4,3 7,0 H8 V1 L 5,4 8,7 V8 H7 L 4,5 1,8 H0 V7 L 3,4 0,1 Z";
152 | -fx-scale-shape: false;
153 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
154 | }
155 | .tab-close-button:hover
156 | {
157 | -fx-background-color: derive(-fx-mark-color, -30%);
158 | }
159 | /* CONTROL BUTTONS */
160 | .control-buttons-tab
161 | {
162 | /*-fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;*/
163 | -fx-background-insets: 0, 1, 2;
164 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
165 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em; /* 1 3 1 3 */
166 | }
167 | .tab-down-button
168 | {
169 | -fx-background-color: transparent;
170 | -fx-padding: 0.0em 0.416667em 0.0em 0.416667em; /* 0 5 0 5 */
171 | }
172 | .tab-down-button:hover
173 | {
174 | -fx-background-color: -fx-body-color;
175 | -fx-color: -fx-hover-base;
176 | }
177 | .tab-down-button .arrow
178 | {
179 | -fx-background-color: -fx-mark-highlight-color, -fx-mark-color;
180 | -fx-background-insets: 1 0 -1 0, 0;
181 | -fx-padding: 0.238083em 0.416667em 0.238083em 0.416667em; /* 2.857 5 2.857 5 */
182 | -fx-shape: "M 0 0 H 7 L 3.5 4 z";
183 | }
184 | /* FLOATING TABS CUSTOMISATION */
185 | .tab-pane.floating *.tab-header-background {
186 | -fx-background-color: null;
187 | }
188 | .tab-pane.floating *.tab-header-area
189 | {
190 | -fx-background-color: null;
191 | }
192 | .tab-pane.floating *.tab-content-area
193 | {
194 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
195 | -fx-background-insets: 0, 1;
196 | -fx-background-radius: 5, 4;
197 | }
198 | .tab-pane.floating *.tab
199 | {
200 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
201 | -fx-background-insets: 0, 1, 2;
202 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
203 | }
204 | .tab-pane.floating *.tab:selected
205 | {
206 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
207 | -fx-background-insets: 0 0 -1 0, 1 1 -1 1;
208 | -fx-background-radius: 5 5 0 0, 4 4 0 0;
209 | }
210 | /*.tab-pane:floating *.control-buttons-tab
211 | {
212 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em;
213 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
214 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
215 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
216 | }*/
217 |
218 | #tab_ico0{
219 | -fx-fill: #999999;
220 | }
221 |
222 | #tab_ico1{
223 | -fx-fill: #999999;
224 | }
225 |
226 | #tab_ico2{
227 | -fx-fill: #999999;
228 | }
229 |
230 | #tab_ico3{
231 | -fx-fill: #999999;
232 | }
233 |
234 | .tab:selected #tab_ico0{
235 | -fx-fill: #FFFFFF;
236 | }
237 | .tab:selected #tab_ico1{
238 | -fx-fill: #FFFFFF;
239 | }
240 | .tab:selected #tab_ico2{
241 | -fx-fill: #FFFFFF;
242 | }
243 | .tab:selected #tab_ico3{
244 | -fx-fill: #FFFFFF;
245 | }
246 |
247 | .tab-content-area {
248 | -fx-background-image: url("../imgs/bg1.jpg");
249 | -fx-background-repeat: repeat;
250 | -fx-z-index:-1;
251 | }
252 |
253 | .tab-pane:left *.tab-header-area {
254 | -fx-alignment: CENTER_RIGHT;
255 | }
256 |
257 | .tab-pane:left *.tab-header-area {
258 | -fx-padding: 0.0em 100% 0.0em 0%;
259 | }
--------------------------------------------------------------------------------
/src/main/resources/styles/tabbedPane.css:
--------------------------------------------------------------------------------
1 | .tab-pane
2 | {
3 | -fx-tab-min-width: 120px; /* 55 */
4 | -fx-tab-max-width: 120px; /* 55 */
5 | -fx-tab-min-height: 140px; /* 24 */
6 | -fx-tab-max-height: 140px; /* 24 */
7 |
8 | -fx-focus-color: transparent;
9 | -fx-faint-focus-color: transparent;
10 |
11 | }
12 |
13 | .tab .tab-label
14 | {
15 | -fx-background-color: transparent;
16 | -fx-alignment: CENTER;
17 | -fx-text-fill: #999999;
18 | }
19 |
20 | .tab:selected .tab-label
21 | {
22 | -fx-text-fill: #ffffff;
23 | }
24 |
25 | .tab *.tab-label .text {
26 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
27 | -fx-rotate: 90;
28 | -fx-font-size: 12;
29 | -fx-alignment:BOTTOM_LEFT;
30 | -fx-width:100px;
31 | }
32 |
33 |
34 | .tab-content-area
35 | {
36 | -fx-background-color: -fx-control-inner-background;
37 | -fx-padding: 0.0em; /* 0 */
38 | /* -fx-opacity: -fx-disabled-opacity;*/
39 |
40 | }
41 | .tab
42 | {
43 | /* This is how it is done in Button, but the -1 inset caused a white line */
44 | /* to appear beneath the tab, which looks bad, so it's taken out below. */
45 | /* -fx-background-color: -fx-shadow-highlight-color, -fx-tab-border-color, -fx-inner-border, -fx-body-color;
46 | -fx-background-radius: 5 5 0 0, 5 5 0 0, 4 4 0 0, 3 3 0 0;
47 | -fx-background-insets: 0 0 -1 0, 0, 1, 2;*/
48 | -fx-background-insets: 0, 1, 2;
49 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
50 | -fx-padding: 0em 0.5em 0.083333em 0.5em; /* 1 6 1 6 */
51 | /* -fx-text-fill: -fx-text-base-color;*/
52 | -fx-border-width: 0 0 0 2; -fx-border-color: #444 #444 #000 #555 ;
53 | }
54 | /*
55 | .tab:top
56 | {
57 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
58 | }
59 | .tab:right
60 | {
61 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
62 | }
63 | .tab:bottom
64 | {
65 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
66 | }
67 | */
68 | .tab:left
69 | {
70 | /*
71 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
72 | */
73 | -fx-background-color: #444;
74 | }
75 | .tab:hover
76 | {
77 | -fx-background-color: #333;
78 | -fx-border-width: 0 2 0 2; -fx-border-color: #444 #222 #000 #555 ;
79 | -fx-cursor:hand;
80 | }
81 |
82 | .tab:selected
83 | {
84 | -fx-text-fill: #223;
85 | -fx-background-color: #222; /*linear-gradient(#424141 0%, #ffffff 100%);
86 | /*-fx-background-color: #ffffff;
87 | -fx-background-color: white;*/
88 | /* -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
89 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
90 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
91 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
92 | */
93 | -fx-background-insets: 0, 1 1 0 1;
94 | -fx-background-radius: 0 0 0 0, 0 0 0 0;
95 | -fx-border-color: transparent;
96 | /*-fx-border-style: none;*/
97 | -fx-background-insets: 0, 1, 2;
98 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
99 | -fx-padding: 0em 0.5em 0.083333em 0.5em;
100 | }
101 | .tab:disabled
102 | {
103 | -fx-opacity: -fx-disabled-opacity;
104 | }
105 | .tab:disabled:hover
106 | {
107 | -fx-color: -fx-base;
108 | -fx-opacity: -fx-disabled-opacity;
109 | -fx-cursor:hand;
110 | }
111 | .tab-pane *.tab-header-background
112 | {/*
113 | -fx-background-color: -fx-outer-border, -fx-inner-border, derive(-fx-color, -20%);
114 | -fx-effect: innershadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0 , 0);
115 | */
116 | -fx-background-color: #444;
117 | }
118 | /*.tab-pane *.tab-header-area {*/
119 | /* I would like to use -fx-tab-border-color here, but for some reason it */
120 | /* just isn't the correct color, even though it works in :top above */
121 | /* -fx-background-color: -fx-tab-border-color, lightgray;*/
122 | /*}*/
123 | .tab-pane:top *.tab-header-area
124 | {
125 | -fx-background-insets: 0, 0 0 1 0;
126 | -fx-padding: 0.416667em 0.166667em 0.0em 0.833em; /* 5 2 0 10 */
127 | }
128 | .tab-pane:bottom *.tab-header-area
129 | {
130 | -fx-background-insets: 0, 1 0 0 0;
131 | -fx-padding: 0 0.166667em 0.416667em 0.833em; /* 0 2 5 0 */
132 | }
133 | .tab-pane:left *.tab-header-area
134 | {
135 | -fx-background-insets: 0, 0 1 0 0;
136 | -fx-padding: 0.833em 0.0em 0.166667em 0.416667em; /* 10 0 2 5 */
137 | }
138 | .tab-pane:right *.tab-header-area
139 | {
140 | -fx-background-insets: 0, 0 0 0 1;
141 | -fx-padding: 0.833em 0.416667em 0.166667em 0.0em; /* 10 5 2 0 */
142 | }
143 | .tab-pane .headers-region
144 | {
145 | -fx-effect: dropshadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0, 0);
146 | }
147 | /* TODO: scaling the shape seems to make it way too large */
148 | .tab-close-button
149 | {
150 | -fx-background-color: -fx-mark-color;
151 | -fx-shape: "M 0,0 H1 L 4,3 7,0 H8 V1 L 5,4 8,7 V8 H7 L 4,5 1,8 H0 V7 L 3,4 0,1 Z";
152 | -fx-scale-shape: false;
153 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
154 | }
155 | .tab-close-button:hover
156 | {
157 | -fx-background-color: derive(-fx-mark-color, -30%);
158 | }
159 | /* CONTROL BUTTONS */
160 | .control-buttons-tab
161 | {
162 | /*-fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;*/
163 | -fx-background-insets: 0, 1, 2;
164 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
165 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em; /* 1 3 1 3 */
166 | }
167 | .tab-down-button
168 | {
169 | -fx-background-color: transparent;
170 | -fx-padding: 0.0em 0.416667em 0.0em 0.416667em; /* 0 5 0 5 */
171 | }
172 | .tab-down-button:hover
173 | {
174 | -fx-background-color: -fx-body-color;
175 | -fx-color: -fx-hover-base;
176 | }
177 | .tab-down-button .arrow
178 | {
179 | -fx-background-color: -fx-mark-highlight-color, -fx-mark-color;
180 | -fx-background-insets: 1 0 -1 0, 0;
181 | -fx-padding: 0.238083em 0.416667em 0.238083em 0.416667em; /* 2.857 5 2.857 5 */
182 | -fx-shape: "M 0 0 H 7 L 3.5 4 z";
183 | }
184 | /* FLOATING TABS CUSTOMISATION */
185 | .tab-pane.floating *.tab-header-background {
186 | -fx-background-color: null;
187 | }
188 | .tab-pane.floating *.tab-header-area
189 | {
190 | -fx-background-color: null;
191 | }
192 | .tab-pane.floating *.tab-content-area
193 | {
194 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
195 | -fx-background-insets: 0, 1;
196 | -fx-background-radius: 5, 4;
197 | }
198 | .tab-pane.floating *.tab
199 | {
200 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
201 | -fx-background-insets: 0, 1, 2;
202 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
203 | }
204 | .tab-pane.floating *.tab:selected
205 | {
206 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
207 | -fx-background-insets: 0 0 -1 0, 1 1 -1 1;
208 | -fx-background-radius: 5 5 0 0, 4 4 0 0;
209 | }
210 | /*.tab-pane:floating *.control-buttons-tab
211 | {
212 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em;
213 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
214 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
215 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
216 | }*/
217 |
218 | #tab_ico0{
219 | -fx-fill: #999999;
220 | }
221 |
222 | #tab_ico1{
223 | -fx-fill: #999999;
224 | }
225 |
226 | #tab_ico2{
227 | -fx-fill: #999999;
228 | }
229 |
230 | #tab_ico3{
231 | -fx-fill: #999999;
232 | }
233 |
234 | .tab:selected #tab_ico0{
235 | -fx-fill: #FFFFFF;
236 | }
237 | .tab:selected #tab_ico1{
238 | -fx-fill: #FFFFFF;
239 | }
240 | .tab:selected #tab_ico2{
241 | -fx-fill: #FFFFFF;
242 | }
243 | .tab:selected #tab_ico3{
244 | -fx-fill: #FFFFFF;
245 | }
246 |
247 | .tab-content-area {
248 | -fx-background-image: url("../imgs/bg1.jpg");
249 | -fx-background-repeat: repeat;
250 | -fx-z-index:-1;
251 | }
252 |
253 | .tab-pane:left *.tab-header-area {
254 | -fx-alignment: CENTER_RIGHT;
255 | }
256 |
257 | .tab-pane:left *.tab-header-area {
258 | -fx-padding: 0.0em 100% 0.0em 0%;
259 | }
--------------------------------------------------------------------------------
/src/main/resources/styles/tabbedPaneTheme2.css:
--------------------------------------------------------------------------------
1 | .tab-pane
2 | {
3 | -fx-tab-min-width: 120px; /* 55 */
4 | -fx-tab-max-width: 120px; /* 55 */
5 | -fx-tab-min-height: 140px; /* 24 */
6 | -fx-tab-max-height: 140px; /* 24 */
7 |
8 | -fx-focus-color: transparent;
9 | -fx-faint-focus-color: transparent;
10 |
11 | }
12 |
13 | .tab .tab-label
14 | {
15 | -fx-background-color: transparent;
16 | -fx-alignment: CENTER;
17 | -fx-text-fill: #999999;
18 | }
19 |
20 | .tab:selected .tab-label
21 | {
22 | -fx-text-fill: #ffffff;
23 | }
24 |
25 | .tab *.tab-label .text {
26 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
27 | -fx-rotate: 90;
28 | -fx-font-size: 12;
29 | -fx-alignment:BOTTOM_LEFT;
30 | -fx-width:100px;
31 | }
32 |
33 |
34 | .tab-content-area
35 | {
36 | -fx-background-color: -fx-control-inner-background;
37 | -fx-padding: 0.0em; /* 0 */
38 | /* -fx-opacity: -fx-disabled-opacity;*/
39 |
40 | }
41 | .tab
42 | {
43 | /* This is how it is done in Button, but the -1 inset caused a white line */
44 | /* to appear beneath the tab, which looks bad, so it's taken out below. */
45 | /* -fx-background-color: -fx-shadow-highlight-color, -fx-tab-border-color, -fx-inner-border, -fx-body-color;
46 | -fx-background-radius: 5 5 0 0, 5 5 0 0, 4 4 0 0, 3 3 0 0;
47 | -fx-background-insets: 0 0 -1 0, 0, 1, 2;*/
48 | -fx-background-insets: 0, 1, 2;
49 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
50 | -fx-padding: 0em 0.5em 0.083333em 0.5em; /* 1 6 1 6 */
51 | /* -fx-text-fill: -fx-text-base-color;*/
52 | -fx-border-width: 0 0 0 2; -fx-border-color: #444 #444 #000 #555 ;
53 | }
54 | /*
55 | .tab:top
56 | {
57 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
58 | }
59 | .tab:right
60 | {
61 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
62 | }
63 | .tab:bottom
64 | {
65 | -fx-background-color: -fx-tab-border-color, -fx-inner-border-bottomup, -fx-body-color-bottomup;
66 | }
67 | */
68 | .tab:left
69 | {
70 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
71 | /*-fx-background-color: #444; */
72 | }
73 | .tab:hover
74 | {
75 | /*-fx-background-color: #333;*/
76 | -fx-border-width: 0 2 0 2; -fx-border-color: #444 #222 #000 #555 ;
77 | -fx-cursor:hand;
78 | }
79 |
80 | .tab:selected
81 | {
82 |
83 | -fx-text-fill: #223;
84 | -fx-background-color: linear-gradient(#424141 0%, #ffffff 100%); /* #222; /*
85 | /*-fx-background-color: #ffffff;
86 | -fx-background-color: white;*/
87 | /* -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
88 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
89 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
90 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
91 | */
92 | -fx-background-insets: 0, 1 1 0 1;
93 | -fx-background-radius: 0 0 0 0, 0 0 0 0;
94 | -fx-border-color: transparent;
95 | /*-fx-border-style: none;*/
96 | -fx-background-insets: 0, 1, 2;
97 | -fx-background-radius: 0 0 0 0, 0 0 0 0, 0 0 0 0;
98 | -fx-padding: 0em 0.5em 0.083333em 0.5em;
99 | }
100 | .tab:disabled
101 | {
102 | -fx-opacity: -fx-disabled-opacity;
103 | }
104 | .tab:disabled:hover
105 | {
106 | -fx-color: -fx-base;
107 | -fx-opacity: -fx-disabled-opacity;
108 | -fx-cursor:hand;
109 | }
110 | .tab-pane *.tab-header-background
111 | {/*
112 | -fx-background-color: -fx-outer-border, -fx-inner-border, derive(-fx-color, -20%);
113 | -fx-effect: innershadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0 , 0);
114 | */
115 | -fx-background-color: #444;
116 | }
117 | /*.tab-pane *.tab-header-area {*/
118 | /* I would like to use -fx-tab-border-color here, but for some reason it */
119 | /* just isn't the correct color, even though it works in :top above */
120 | /* -fx-background-color: -fx-tab-border-color, lightgray;*/
121 | /*}*/
122 | .tab-pane:top *.tab-header-area
123 | {
124 | -fx-background-insets: 0, 0 0 1 0;
125 | -fx-padding: 0.416667em 0.166667em 0.0em 0.833em; /* 5 2 0 10 */
126 | }
127 | .tab-pane:bottom *.tab-header-area
128 | {
129 | -fx-background-insets: 0, 1 0 0 0;
130 | -fx-padding: 0 0.166667em 0.416667em 0.833em; /* 0 2 5 0 */
131 | }
132 | .tab-pane:left *.tab-header-area
133 | {
134 | -fx-background-insets: 0, 0 1 0 0;
135 | -fx-padding: 0.833em 0.0em 0.166667em 0.416667em; /* 10 0 2 5 */
136 | }
137 | .tab-pane:right *.tab-header-area
138 | {
139 | -fx-background-insets: 0, 0 0 0 1;
140 | -fx-padding: 0.833em 0.416667em 0.166667em 0.0em; /* 10 5 2 0 */
141 | }
142 | .tab-pane .headers-region
143 | {
144 | -fx-effect: dropshadow(two-pass-box , rgba(0,0,0,0.6) , 4, 0.0 , 0, 0);
145 | }
146 | /* TODO: scaling the shape seems to make it way too large */
147 | .tab-close-button
148 | {
149 | -fx-background-color: -fx-mark-color;
150 | -fx-shape: "M 0,0 H1 L 4,3 7,0 H8 V1 L 5,4 8,7 V8 H7 L 4,5 1,8 H0 V7 L 3,4 0,1 Z";
151 | -fx-scale-shape: false;
152 | -fx-effect: dropshadow(two-pass-box , rgba(255, 255, 255, 0.4), 1, 0.0 , 0, 1);
153 | }
154 | .tab-close-button:hover
155 | {
156 | -fx-background-color: derive(-fx-mark-color, -30%);
157 | }
158 | /* CONTROL BUTTONS */
159 | .control-buttons-tab
160 | {
161 | /*-fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;*/
162 | -fx-background-insets: 0, 1, 2;
163 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
164 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em; /* 1 3 1 3 */
165 | }
166 | .tab-down-button
167 | {
168 | -fx-background-color: transparent;
169 | -fx-padding: 0.0em 0.416667em 0.0em 0.416667em; /* 0 5 0 5 */
170 | }
171 | .tab-down-button:hover
172 | {
173 | -fx-background-color: -fx-body-color;
174 | -fx-color: -fx-hover-base;
175 | }
176 | .tab-down-button .arrow
177 | {
178 | -fx-background-color: -fx-mark-highlight-color, -fx-mark-color;
179 | -fx-background-insets: 1 0 -1 0, 0;
180 | -fx-padding: 0.238083em 0.416667em 0.238083em 0.416667em; /* 2.857 5 2.857 5 */
181 | -fx-shape: "M 0 0 H 7 L 3.5 4 z";
182 | }
183 | /* FLOATING TABS CUSTOMISATION */
184 | .tab-pane.floating *.tab-header-background {
185 | -fx-background-color: null;
186 | }
187 | .tab-pane.floating *.tab-header-area
188 | {
189 | -fx-background-color: null;
190 | }
191 | .tab-pane.floating *.tab-content-area
192 | {
193 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
194 | -fx-background-insets: 0, 1;
195 | -fx-background-radius: 5, 4;
196 | }
197 | .tab-pane.floating *.tab
198 | {
199 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
200 | -fx-background-insets: 0, 1, 2;
201 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
202 | }
203 | .tab-pane.floating *.tab:selected
204 | {
205 | -fx-background-color: -fx-tab-border-color, -fx-control-inner-background;
206 | -fx-background-insets: 0 0 -1 0, 1 1 -1 1;
207 | -fx-background-radius: 5 5 0 0, 4 4 0 0;
208 | }
209 | /*.tab-pane:floating *.control-buttons-tab
210 | {
211 | -fx-padding: 0.083333em 0.25em 0.083333em 0.25em;
212 | -fx-background-color: -fx-tab-border-color, -fx-inner-border, -fx-body-color;
213 | -fx-background-radius: 5 5 0 0, 4 4 0 0, 3 3 0 0;
214 | -fx-background-insets: 0, 1 1 0 1, 2 2 0 2;
215 | }*/
216 |
217 | #tab_ico0{
218 | -fx-fill: #999999;
219 | }
220 |
221 | #tab_ico1{
222 | -fx-fill: #999999;
223 | }
224 |
225 | #tab_ico2{
226 | -fx-fill: #999999;
227 | }
228 |
229 | #tab_ico3{
230 | -fx-fill: #999999;
231 | }
232 |
233 | .tab:selected #tab_ico0{
234 | -fx-fill: #FFFFFF;
235 | }
236 | .tab:selected #tab_ico1{
237 | -fx-fill: #FFFFFF;
238 | }
239 | .tab:selected #tab_ico2{
240 | -fx-fill: #FFFFFF;
241 | }
242 | .tab:selected #tab_ico3{
243 | -fx-fill: #FFFFFF;
244 | }
245 |
246 | .tab-content-area {
247 | -fx-background-image: url("../imgs/bg1.jpg");
248 | -fx-background-repeat: repeat;
249 | -fx-z-index:-1;
250 | }
251 |
252 | .tab-pane:left *.tab-header-area {
253 | -fx-alignment: CENTER_RIGHT;
254 | }
255 |
256 | .tab-pane:left *.tab-header-area {
257 | -fx-padding: 0.0em 100% 0.0em 0%;
258 | }
--------------------------------------------------------------------------------