Highway to PSR2
[openemr.git] / contrib / forms / psychiatrySet / psychiatrisch_onderzoek / report.php
blob671b850f838d60bfa07234fc51e15d0d43e39336
1 <?php
2 ////////////////////////////////////////////////////////////////////
3 // Form: PSYCHIATRISCH ONDERZOEK
4 // Package: Research psihiatric - Dutch specific form
5 // Created by: Larry Lart
6 // Version: 1.0 - 29-03-2008
7 ////////////////////////////////////////////////////////////////////
9 include_once("../../globals.php");
10 include_once($GLOBALS["srcdir"]."/api.inc");
12 ////////////////////////////////////////////////////////////////////
13 // Function: psychiatrisch_onderzoek_report
14 // Purpose: callback func?
15 // Input: pid? encounter, cols, id ?
16 ////////////////////////////////////////////////////////////////////
17 function psychiatrisch_onderzoek_report($pid, $encounter, $cols, $id)
19 $count = 0;
20 $data = formFetch("form_psychiatrisch_onderzoek", $id);
21 if ($data) {
22 print "<table>";
24 foreach ($data as $key => $value) {
25 // here we check for current ???? what ? session ?
26 if ($key == "id" || $key == "pid" || $key == "user" ||
27 $key == "groupname" || $key == "authorized" || $key == "activity" ||
28 $key == "date" || $value == "" || $value == "0000-00-00 00:00:00") {
29 continue;
32 // larry :: ??? - is this for check box or select or what ?
33 if ($value == "on") {
34 $value = "yes";
37 // Datum onderzoek
38 if ($key == "datum_onderzoek") {
39 print "<tr><td><span class=bold>" . xl('Examination Date') . ": </span><span class=text>" .
40 nl2br(stripslashes($value)) . "</span></td></tr>";
43 // Reden van aanmelding
44 if ($key == "reden_van_aanmelding") {
45 print "<tr><td><span class=bold>" . xl('Reason for Visit') . ": </span><span class=text>" .
46 nl2br(stripslashes($value)) . "</span></td></tr>";
49 // Conclusie van intake
50 if ($key == "conclusie_van_intake") {
51 print "<tr><td><span class=bold>" . xl('Intake Conclusion') . ": </span><span class=text>" .
52 nl2br(stripslashes($value)) . "</span></td></tr>";
55 // Medicatie
56 if ($key == "medicatie") {
57 print "<tr><td><span class=bold>" . xl('Medications') . ": </span><span class=text>" .
58 nl2br(stripslashes($value)) . "</span></td></tr>";
61 // Anamnese
62 if ($key == "anamnese") {
63 print "<tr><td><span class=bold>" . xl('History') . ": </span><span class=text>" .
64 nl2br(stripslashes($value)) . "</span></td></tr>";
67 // Psychiatrisch onderzoek i.e.z.
68 if ($key == "psychiatrisch_onderzoek") {
69 print "<tr><td><span class=bold>" . xl('Psychiatric Examination') . ": </span><span class=text>" .
70 nl2br(stripslashes($value)) . "</span></td></tr>";
73 // Beschrijvende conclusie
74 if ($key == "beschrijvende_conclusie") {
75 print "<tr><td><span class=bold>" . xl('Conclusions') . ": </span><span class=text>" .
76 nl2br(stripslashes($value)) . "</span></td></tr>";
79 // Behandelvoorstel
80 if ($key == "behandelvoorstel") {
81 print "<tr><td><span class=bold>" . xl('Treatment Plan') . ": </span><span class=text>" .
82 nl2br(stripslashes($value)) . "</span></td></tr>";
86 // increment records counter
87 $count++;
88 // check if not at the end close/open new row
89 if ($count == $cols) {
90 $count = 0;
91 print "</tr><tr>\n";
96 print "</tr></table>";