-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpatient_info.php
55 lines (47 loc) · 1.39 KB
/
patient_info.php
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
<?php
if (!isset($_SESSION)) {
session_start();
}
?>
<?php
include 'header.php';
include 'library.php';
noAccessIfNotLoggedIn();
noAccessForNormal();
noAccessForClerk();
noAccessForAdmin();
?>
<div class = 'about'>
<div class = 'container'>
<h3>Upcomming Appointments</h3>
<p style="margin-top: 40px">Click on the the field to fill additional information</p>
<table class='table table-striped text-center '>
<thead class="thead-inverse">
<tr>
<th><center>Appointment No</center></th>
<th><center>Patient's Full Name</center></th>
<th><center>Medical Condition</center></th>
</tr>
</thead>
<?php
$result = getPatientsFor('Dentist');
while ($row = $result->fetch_array()) {
$status = ' ';
if (appointment_status((int) $row['appointment_no']) == 1) {
$status = 'table-active';
} elseif (appointment_status((int) $row['appointment_no']) == 2) {
$status = 'table-success';
}
$link = "<td ><a href= 'update_info.php?appointment_no=".$row['appointment_no']."'>";
$endingTag = '</a></td>';
echo '<tr class="'.$status.'"> ';
echo "$link".$row['appointment_no']."$endingTag";
echo "$link".$row['full_name']."$endingTag";
echo "$link".$row['medical_condition']."$endingTag";
echo '</tr>';
}
?>
</table>
</div>
</div>
<?php include 'footer.php'; ?>