-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathPatientVitalsController.java
More file actions
60 lines (44 loc) · 1.4 KB
/
PatientVitalsController.java
File metadata and controls
60 lines (44 loc) · 1.4 KB
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
import java.io.IOException;
import java.net.URL;
import java.util.ResourceBundle;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
import javafx.scene.control.TextArea;
import javafx.scene.control.TextField;
import javafx.scene.text.Text;
public class PatientVitalsController extends Controller {
@FXML
private Button backToNursePage, submitHealthInfo;
@FXML
private TextArea Immunization, healthIssues;
@FXML
private TextField PatientTemperature, patientBloodPressure, patientHeight, patientWeight;
@FXML
private Text currentPatient;
@FXML
void handleBackButton(ActionEvent event) throws IOException {
super.backButton(super.prevPage, backToNursePage);
}
@FXML
void handleSubmitButton(ActionEvent event) throws IOException {
Patient cp = (Patient) super.selectedAccount;
cp.setImmunization(Immunization.getText());
cp.setHealthIssues(healthIssues.getText());
float bp = Float.parseFloat(patientBloodPressure.getText());
cp.setBloodPressure(bp);
cp.setPatientHeight(patientHeight.getText());
float w = Float.parseFloat(patientWeight.getText());
cp.setWeight(w);
float t = Float.parseFloat(PatientTemperature.getText());
cp.setBodyTemp(t);
super.saveData();
super.backButton(super.prevPage, submitHealthInfo);
}
@Override
public void initData() {
}
@Override
public void initialize(URL location, ResourceBundle resources) {
}
}