Highway to PSR2
[openemr.git] / interface / forms / transfer_summary / new.php
blob75eb94816a3b23be3e80b3b326f0e1cbcb8634a8
1 <?php
2 /**
4 * Copyright (C) 2012-2013 Naina Mohamed <naina@capminds.com> CapMinds Technologies
5 * Copyright (C) 2017 Brady Miller <brady.g.miller@gmail.com>
8 * LICENSE: This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 3
11 * of the License, or (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://opensource.org/licenses/gpl-license.php>;.
19 * @package OpenEMR
20 * @author Naina Mohamed <naina@capminds.com>
21 * @author Brady Miller <brady.g.miller@gmail.com>
22 * @link http://www.open-emr.org
26 include_once("../../globals.php");
27 include_once("$srcdir/api.inc");
28 require_once("$srcdir/patient.inc");
29 require_once("$srcdir/options.inc.php");
30 formHeader("Form:Transfer Summary");
31 $returnurl = 'encounter_top.php';
32 $formid = 0 + (isset($_GET['id']) ? $_GET['id'] : '');
33 $obj = $formid ? formFetch("form_transfer_summary", $formid) : array();
36 <html>
37 <head>
38 <?php html_header_show();?>
40 <link rel="stylesheet" href="<?php echo $css_header;?>" type="text/css">
41 <link rel="stylesheet" href="<?php echo $GLOBALS['assets_static_relative']; ?>/jquery-datetimepicker-2-5-4/build/jquery.datetimepicker.min.css">
43 <script type="text/javascript" src="<?php echo $GLOBALS['webroot'] ?>/library/textformat.js?v=<?php echo $v_js_includes; ?>"></script>
44 <script type="text/javascript" src="<?php echo $GLOBALS['webroot'] ?>/library/dialog.js?v=<?php echo $v_js_includes; ?>"></script>
45 <script type="text/javascript" src="<?php echo $GLOBALS['assets_static_relative']; ?>/jquery-min-3-1-1/index.js"></script>
46 <script type="text/javascript" src="<?php echo $GLOBALS['assets_static_relative']; ?>/jquery-datetimepicker-2-5-4/build/jquery.datetimepicker.full.min.js"></script>
48 <script language="JavaScript">
49 $(document).ready(function() {
50 var win = top.printLogSetup ? top : opener.top;
51 win.printLogSetup(document.getElementById('printbutton'));
53 $('.datepicker').datetimepicker({
54 <?php $datetimepicker_timepicker = false; ?>
55 <?php $datetimepicker_showseconds = false; ?>
56 <?php $datetimepicker_formatInput = false; ?>
57 <?php require($GLOBALS['srcdir'] . '/js/xl/jquery-datetimepicker-2-5-4.js.php'); ?>
58 <?php // can add any additional javascript settings to datetimepicker here; need to prepend first setting with a comma ?>
59 });
60 });
61 </script>
63 </head>
65 <body class="body_top">
66 <p><span class="forms-title"><?php echo xlt('Transfer Summary'); ?></span></p>
67 </br>
68 <?php
69 echo "<form method='post' name='my_form' " .
70 "action='$rootdir/forms/transfer_summary/save.php?id=" . attr($formid) ."'>\n";
72 <table border="0">
73 <tr>
74 <td align="left" class="forms" class="forms"><?php echo xlt('Client Name'); ?>:</td>
75 <td class="forms">
76 <label class="forms-data"> <?php if (is_numeric($pid)) {
77 $result = getPatientData($pid, "fname,lname,squad");
78 echo text($result['fname'])." ".text($result['lname']);
81 $patient_name=($result['fname'])." ".($result['lname']);
83 </label>
84 <input type="hidden" name="client_name" value="<?php echo attr($patient_name);?>">
85 </td>
86 <td align="left" class="forms"><?php echo xlt('DOB'); ?>:</td>
87 <td class="forms">
88 <label class="forms-data"> <?php if (is_numeric($pid)) {
89 $result = getPatientData($pid, "*");
90 echo text($result['DOB']);
93 $dob=($result['DOB']);
95 </label>
96 <input type="hidden" name="DOB" value="<?php echo attr($dob);?>">
97 </td>
98 </tr>
99 <tr>
101 <td align="left" class="forms"><?php echo xlt('Transfer to'); ?>:</td>
103 <td class="forms">
104 <input type="text" name="transfer_to" id="transfer_to"
105 value="<?php echo text($obj{"transfer_to"});?>"></td>
107 <td align="left" class="forms"><?php echo xlt('Transfer date'); ?>:</td>
108 <td class="forms">
109 <input type='text' size='10' class='datepicker' name='transfer_date' id='transfer_date' <?php echo attr($disabled)?>;
110 value='<?php echo attr($obj{"transfer_date"}); ?>'
111 title='<?php echo xla('yyyy-mm-dd Date of service'); ?>' />
112 </td>
114 </tr>
116 <tr>
117 <td align="left colspan="3" style="padding-bottom:7px;"></td>
118 </tr>
120 <tr>
121 <td align="left" class="forms"><b><?php echo xlt('Status Of Admission'); ?>:</b></td>
122 <td colspan="3"><textarea name="status_of_admission" rows="3" cols="60" wrap="virtual name"><?php echo text($obj{"status_of_admission"});?></textarea></td>
123 </tr>
124 <tr>
125 <td align="left colspan="3" style="padding-bottom:7px;"></td>
126 </tr>
127 <tr>
128 <td align="left" class="forms"><b><?php echo xlt('Diagnosis'); ?>:</b></td>
129 <td colspan="3"><textarea name="diagnosis" rows="3" cols="60" wrap="virtual name"><?php echo text($obj{"diagnosis"});?></textarea></td>
130 </tr>
131 <tr>
132 <td align="left colspan="3" style="padding-bottom:7px;"></td>
133 </tr>
134 <tr>
135 <td align="left" class="forms"><b><?php echo xlt('Intervention Provided'); ?>:</b></td>
136 <td colspan="3"><textarea name="intervention_provided" rows="3" cols="60" wrap="virtual name"><?php echo text($obj{"intervention_provided"});?></textarea></td>
137 </tr>
138 <tr>
139 <td align="left colspan="3" style="padding-bottom:7px;"></td>
140 </tr>
141 <tr>
142 <td align="left" class="forms"><b><?php echo xlt('Overall Status Of Discharge'); ?>:</b></td>
143 <td colspan="3"><textarea name="overall_status_of_discharge" rows="3" cols="60" wrap="virtual name"><?php echo text($obj{"overall_status_of_discharge"});?></textarea></td>
144 </tr>
146 <tr>
147 <td align="left colspan="3" style="padding-bottom:7px;"></td>
148 </tr>
150 <tr>
151 <td align="left colspan="3" style="padding-bottom:7px;"></td>
152 </tr>
153 <tr>
154 <td></td>
155 <td><input type='submit' value='<?php echo xlt('Save');?>' class="button-css">&nbsp;
156 <input type='button' value='<?php echo xla('Print'); ?>' id='printbutton' />&nbsp;
157 <input type='button' class="button-css" value='<?php echo xla('Cancel'); ?>'
158 onclick="top.restoreSession();location='<?php echo "$rootdir/patient_file/encounter/$returnurl" ?>'" />
160 </td>
161 </tr>
162 </table>
163 </form>
165 <?php
166 formFooter();