-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathadd_patient.html
203 lines (183 loc) · 9.25 KB
/
add_patient.html
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
64
65
66
67
68
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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<meta http-equiv='X-UA-Compatible' content='IE=edge'>
<title>Edgecliff Medical Centre App</title>
<meta name='viewport' content='width=device-width, initial-scale=1'>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-9ndCyUaIbzAi2FUVXJi0CjmCapSmO7SnpJef0486qhLnuZ2cdeRhO02iuK6FUUVM" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.5/font/bootstrap-icons.css">
<link rel="stylesheet" href="css/style.css">
<script src="js/script.js" defer></script>
</head>
<body onload="showPatientsInfo()">
<div class="mt-3">
<!-- add patient form -->
<div class="card mb-5" style="max-width: 800px;">
<div class="card-header">
<h4>Add New Patient</h4>
</div>
<div class="card-body">
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personName" placeholder="Patient's name">
<label for="personName">Patient's name</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="email" class="form-control" id="personEmail" placeholder="name@example.com">
<label for="personEmail">Email address</label>
</div>
</div>
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personPhone" placeholder="Phone number">
<label for="personPhone">Phone number</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="date" class="form-control" id="personDob">
<label for="personDob">Date of birth</label>
</div>
</div>
<div class="col-sm-6">
<div class="form-floating">
<select class="form-select" id="personGender">
<option value="Select" selected>Select gender</option>
<option value="Female">Female</option>
<option value="Male">Male</option>
<option value="Other">Other</option>
</select>
<label for="personGender">Gender</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personAddress" placeholder="Address">
<label for="personAddress">Address</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<textarea class="form-control" id="personMedicalHistory" placeholder="Medical History"></textarea>
<label for="personMedicalHistory">Medical History</label>
</div>
</div>
</div>
</div>
<div class="card-footer d-flex justify-content-end">
<button type="button" class="btn btn-secondary btn-sm me-3" onclick="reset('listPatients')">Reset</button>
<button type="button" class="btn btn-primary btn-sm" onclick="savePatient()">Save</button>
</div>
</div>
<hr />
<!-- patient table -->
<div class="card my-5">
<div class="card-header">
<h4>Patient List</h4>
</div>
<div class="card-body">
<table class="table table-hover">
<thead>
<tr>
<th scope="col">Name</th>
<th scope="col">Email</th>
<th scope="col">Phone</th>
<th scope="col">DOB</th>
<th scope="col">Gender</th>
<th scope="col">Address</th>
<th scope="col">Medical history</th>
<th scope="col"></th>
</tr>
</thead>
<tbody id="showInfoTable">
</tbody>
</table>
</div>
</div>
<!-- Modal edit -->
<div id="modal" class="modal">
<div class="modal-content card my-5" style="max-width: 800px;">
<div class="card-header d-flex justify-content-between align-items-center px-4">
<h4 class="mt-2">Edit information</h4>
<span class="close" onclick="closeModal()">×</span>
</div>
<div class="card-body p-4">
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personNameEdit" placeholder="person's name">
<label for="personNameEdit">Patient's name</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="email" class="form-control" id="personEmailEdit" placeholder="name@example.com">
<label for="personEmailEdit">Email address</label>
</div>
</div>
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personPhoneEdit" placeholder="Phone number">
<label for="personPhoneEdit">Phone number</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-floating mb-3">
<input type="date" class="form-control" id="personDobEdit">
<label for="personDobEdit">Date of birth</label>
</div>
</div>
<div class="col-sm-6">
<div class="form-floating">
<select class="form-select" id="personGenderEdit">
<option selected>Select gender</option>
<option value="Female">Female</option>
<option value="Male">Male</option>
<option value="Other">Other</option>
</select>
<label for="personGenderEdit">Gender</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<input type="text" class="form-control" id="personAddressEdit" placeholder="Address">
<label for="personAddressEdit">Address</label>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="form-floating mb-3">
<textarea class="form-control" id="personMedicalHistoryEdit" placeholder="Medical History"></textarea>
<label for="personMedicalHistoryEdit">Medical History</label>
</div>
</div>
</div>
</div>
<div id="btnSaveEdit" class="card-footer d-flex justify-content-end px-4">
</div>
</div>
</div>
<!-- Modal edit -->
</div>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js" integrity="sha384-geWF76RCwLtnZ8qwWowPQNguL3RmwHVBC9FhGdlKrxdiJJigb/j/68SIy3Te4Bkz" crossorigin="anonymous"></script>
</body>
</html>