3 * Display patient notes.
6 * @link http://www.open-emr.org
7 * @author Brady Miller <brady.g.miller@gmail.com>
8 * @copyright Copyright (c) 2018 Brady Miller <brady.g.miller@gmail.com>
9 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
13 require_once("../../globals.php");
14 require_once("$srcdir/patient.inc");
15 require_once("$srcdir/acl.inc");
16 require_once("$srcdir/options.inc.php");
17 require_once("$srcdir/pnotes.inc");
19 $prow = getPatientData($pid, "squad, title, fname, mname, lname");
21 // Check authorization.
22 $thisauth = acl_check('patients', 'notes');
24 die(xlt('Not authorized'));
27 if ($prow['squad'] && ! acl_check('squads', $prow['squad'])) {
28 die(xlt('Not authorized for this squad.'));
31 $noteid = $_REQUEST['noteid'];
33 $ptname = $prow['title'] . ' ' . $prow['fname'] . ' ' . $prow['mname'] .
41 $nrow = getPnoteById($noteid, 'title,assigned_to,activity,body');
42 $title = $nrow['title'];
43 $assigned_to = $nrow['assigned_to'];
44 $activity = $nrow['activity'];
45 $body = $nrow['body'];
50 <link rel
='stylesheet' href
="<?php echo $css_header;?>" type
="text/css">
53 <body
class="body_top">
56 generate_display_field(array('data_type'=>'1','list_id'=>'note_type'), $title) .
57 "</b>" . ' ' . xlt('for') . ' ' .
58 "<b>" . attr($ptname) . "</b>"; ?
></p
>
60 <p
><?php
echo xlt('Assigned To'); ?
>: <?php
echo text($assigned_to); ?
></p
>
62 <p
><?php
echo xlt('Active{{Note}}'); ?
>: <?php
echo ($activity ?
xlt('Yes') : xlt('No')); ?
></p
>
64 <p
><?php
echo nl2br(text($body)); ?
></p
>
66 <script language
='JavaScript'>
67 opener
.top
.printLogPrint(window
);