-
Notifications
You must be signed in to change notification settings - Fork 0
/
datacheck.php
124 lines (106 loc) · 3.04 KB
/
datacheck.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
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
<?php
require_once "config.php";
$PAGE = "datacheck";
require_once "includes/header.php";
$dc = new DataCheck();
?>
<h2><?php echo getString("datacheck.unregistered.title")?></h2>
<p><?php echo getString("datacheck.unregistered.info")?></p>
<?php
$unregistered = $dc->getDataCheck('unreg');
if(count($unregistered)>0){
?>
<table class="admin">
<tr>
<th>Error Date</th>
<th>Registered by/at</th>
<th>Patient ID</th>
<th>Protocol</th>
</tr>
<?php
foreach ($unregistered as $d){
echo "<tr class='l' title='Click to view full details'";
printf("onclick=\"document.location.href='%spatient.php?hpcode=%s&patientid=%s&protocol=%s';\">",
$CONFIG->homeAddress,
$d->patienthpcode,
$d->patid,
$d->protocol
);
echo "<td nowrap>".$d->dcdate."</td>";
echo "<td nowrap>".$d->submittedname." at ".displayHealthPointName($d->protocolhpcode)."</td>";
echo "<td nowrap>(".$d->patienthpcode.") ".displayHealthPointName($d->patienthpcode,$d->patid)."</td>";
echo "<td nowrap>".getstring($d->protocol)."</td>";
echo "</tr>";
}
?>
</table>
<?php
} else {
echo "<p>".getString("datacheck.unregistered.none")."</p>";
}
?>
<h2><?php echo getString("datacheck.duplicate.protocol.title")?></h2>
<p><?php echo getString("datacheck.duplicate.protocol.info")?></p>
<?php
$dup = $dc->getDataCheck('duplicate');
if(count($dup)>0){
?>
<table class="admin">
<tr>
<th>Error Date</th>
<th>Registered by/at</th>
<th>Patient ID</th>
<th>Protocol</th>
</tr>
<?php
foreach ($dup as $d){
echo "<tr class='l' title='Click to view full details'";
printf("onclick=\"document.location.href='%spatient.php?hpcode=%s&patientid=%s&protocol=%s';\">",
$CONFIG->homeAddress,
$d->patienthpcode,
$d->patid,
$d->protocol
);
echo "<td nowrap>".$d->dcdate."</td>";
echo "<td nowrap>".$d->submittedname." at ".displayHealthPointName($d->protocolhpcode)."</td>";
echo "<td nowrap>(".$d->patienthpcode.") ".displayHealthPointName($d->patienthpcode,$d->patid)."</td>";
echo "<td nowrap>".getstring($d->protocol)."</td>";
echo "</tr>";
}
?>
</table>
<?php
} else {
echo "<p>".getString("datacheck.duplicate.protocol.none")."</p>";
}
?>
<h2><?php echo getString("datacheck.ageyob.title")?></h2>
<?php
$ageyob = $dc->getDataCheck('ageyob');
if(count($ageyob)>0){
?>
<table class="admin">
<tr>
<th>Error Date</th>
<th>Patient ID</th>
</tr>
<?php
foreach ($ageyob as $ay){
echo "<tr class='l' title='Click to view full details'";
printf("onclick=\"document.location.href='%spatient.php?hpcode=%s&patientid=%s';\">",
$CONFIG->homeAddress,
$ay->patienthpcode,
$ay->patid
);
echo "<td nowrap>".$ay->dcdate."</td>";
echo "<td nowrap>(".$ay->patienthpcode.") ".displayHealthPointName($ay->patienthpcode,$ay->patid)."</td>";
echo "</tr>";
}
?>
</table>
<?php
} else {
echo "<p>".getString("datacheck.ageyob.none")."</p>";
}
include_once "includes/footer.php";
?>