Refactor previous name into dedicated service (#7571)
[openemr.git] / interface / patient_tracker / patient_tracker.php
blobbe4b88a609c6ca9bc4abb9301c1d2faf1c9618cc
1 <?php
3 /**
4 * Patient Tracker (Patient Flow Board)
6 * This program displays the information entered in the Calendar program ,
7 * allowing the user to change status and view those changed here and in the Calendar
8 * Will allow the collection of length of time spent in each status
10 * @package OpenEMR
11 * @link http://www.open-emr.org
12 * @author Terry Hill <terry@lilysystems.com>
13 * @author Brady Miller <brady.g.miller@gmail.com>
14 * @author Ray Magauran <magauran@medexbank.com>
15 * @copyright Copyright (c) 2015-2017 Terry Hill <terry@lillysystems.com>
16 * @copyright Copyright (c) 2017-2021 Brady Miller <brady.g.miller@gmail.com>
17 * @copyright Copyright (c) 2017 Ray Magauran <magauran@medexbank.com>
18 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
21 require_once "../globals.php";
22 require_once "$srcdir/patient.inc.php";
23 require_once "$srcdir/options.inc.php";
24 require_once "$srcdir/patient_tracker.inc.php";
25 require_once "$srcdir/user.inc.php";
26 require_once "$srcdir/MedEx/API.php";
28 use OpenEMR\Common\Csrf\CsrfUtils;
29 use OpenEMR\Core\Header;
31 if (!empty($_POST)) {
32 if (!CsrfUtils::verifyCsrfToken($_POST["csrf_token_form"])) {
33 CsrfUtils::csrfNotVerified();
37 // These settings are sticky user preferences linked to a given page.
38 // mdsupport - user_settings prefix
39 $uspfx = substr(__FILE__, strlen($webserver_root)) . '.';
40 $setting_new_window = prevSetting($uspfx, 'setting_new_window', 'setting_new_window', ' ');
41 // flow board and recall board share bootstrap settings:
42 $setting_bootstrap_submenu = prevSetting('', 'setting_bootstrap_submenu', 'setting_bootstrap_submenu', ' ');
43 $setting_selectors = prevSetting($uspfx, 'setting_selectors', 'setting_selectors', 'block');
44 $form_apptcat = prevSetting($uspfx, 'form_apptcat', 'form_apptcat', '');
45 $form_apptstatus = prevSetting($uspfx, 'form_apptstatus', 'form_apptstatus', '');
46 $facility = prevSetting($uspfx, 'form_facility', 'form_facility', '');
47 $provider = prevSetting($uspfx, 'form_provider', 'form_provider', $_SESSION['authUserID']);
49 if (
50 ($_POST['setting_new_window'] ?? '') ||
51 ($_POST['setting_bootstrap_submenu'] ?? '') ||
52 ($_POST['setting_selectors'] ?? '')
53 ) {
54 // These are not form elements. We only ever change them via ajax, so exit now.
55 exit();
58 //set default start date of flow board to value based on globals
59 if (!$GLOBALS['ptkr_date_range']) {
60 $from_date = date('Y-m-d');
61 } elseif (!is_null($_REQUEST['form_from_date'] ?? null)) {
62 $from_date = DateToYYYYMMDD($_REQUEST['form_from_date']);
63 } elseif (($GLOBALS['ptkr_start_date']) == 'D0') {
64 $from_date = date('Y-m-d');
65 } elseif (($GLOBALS['ptkr_start_date']) == 'B0') {
66 if (date(w) == GLOBALS['first_day_week']) {
67 //today is the first day of the week
68 $from_date = date('Y-m-d');
69 } elseif ($GLOBALS['first_day_week'] == 0) {
70 //Sunday
71 $from_date = date('Y-m-d', strtotime('previous sunday'));
72 } elseif ($GLOBALS['first_day_week'] == 1) {
73 //Monday
74 $from_date = date('Y-m-d', strtotime('previous monday'));
75 } elseif ($GLOBALS['first_day_week'] == 6) {
76 //Saturday
77 $from_date = date('Y-m-d', strtotime('previous saturday'));
79 } else {
80 //shouldnt be able to get here...
81 $from_date = date('Y-m-d');
84 //set default end date of flow board to value based on globals
85 if ($GLOBALS['ptkr_date_range']) {
86 if (substr($GLOBALS['ptkr_end_date'], 0, 1) == 'Y') {
87 $ptkr_time = substr($GLOBALS['ptkr_end_date'], 1, 1);
88 $ptkr_future_time = mktime(0, 0, 0, date('m'), date('d'), date('Y') + $ptkr_time);
89 } elseif (substr($GLOBALS['ptkr_end_date'], 0, 1) == 'M') {
90 $ptkr_time = substr($GLOBALS['ptkr_end_date'], 1, 1);
91 $ptkr_future_time = mktime(0, 0, 0, date('m') + $ptkr_time, date('d'), date('Y'));
92 } elseif (substr($GLOBALS['ptkr_end_date'], 0, 1) == 'D') {
93 $ptkr_time = substr($GLOBALS['ptkr_end_date'], 1, 1);
94 $ptkr_future_time = mktime(0, 0, 0, date('m'), date('d') + $ptkr_time, date('Y'));
97 $to_date = date('Y-m-d', $ptkr_future_time);
98 $to_date = !is_null($_REQUEST['form_to_date'] ?? null) ? DateToYYYYMMDD($_REQUEST['form_to_date']) : $to_date;
99 } else {
100 $to_date = date('Y-m-d');
103 $form_patient_name = !is_null($_POST['form_patient_name'] ?? null) ? $_POST['form_patient_name'] : null;
104 $form_patient_id = !is_null($_POST['form_patient_id'] ?? null) ? $_POST['form_patient_id'] : null;
107 $lres = sqlStatement("SELECT option_id, title FROM list_options WHERE list_id = ? AND activity=1", array('apptstat'));
108 while ($lrow = sqlFetchArray($lres)) {
109 // if exists, remove the legend character
110 if ($lrow['title'][1] == ' ') {
111 $splitTitle = explode(' ', $lrow['title']);
112 array_shift($splitTitle);
113 $title = implode(' ', $splitTitle);
114 } else {
115 $title = $lrow['title'];
117 $statuses_list[$lrow['option_id']] = $title;
120 if ($GLOBALS['medex_enable'] == '1') {
121 $query2 = "SELECT * FROM medex_icons";
122 $iconed = sqlStatement($query2);
123 while ($icon = sqlFetchArray($iconed)) {
124 $icons[$icon['msg_type']][$icon['msg_status']]['html'] = $icon['i_html'];
126 $MedEx = new MedExApi\MedEx('MedExBank.com');
127 $sql = "SELECT * FROM medex_prefs LIMIT 1";
128 $preferences = sqlStatement($sql);
129 $prefs = sqlFetchArray($preferences);
130 $results = json_decode($prefs['status'], true);
131 $logged_in = $results;
132 $logged_in = $results;
133 if (!empty($logged_in['token'])) {
134 $current_events = xlt("On-line");
135 } else {
136 $current_events = xlt("Currently off-line");
140 if (!($_REQUEST['flb_table'] ?? null)) {
142 <html>
143 <head>
144 <meta name="author" content="OpenEMR: MedExBank" />
145 <?php Header::setupHeader(['datetime-picker', 'opener']); ?>
146 <title><?php echo xlt('Flow Board'); ?></title>
147 <script>
148 <?php require_once "$srcdir/restoreSession.php"; ?>
149 </script>
151 <?php if ($_SESSION['language_direction'] == "rtl") { ?>
152 <link rel="stylesheet" href="<?php echo $GLOBALS['themes_static_relative']; ?>/misc/rtl_bootstrap_navbar.css?v=<?php echo $GLOBALS['v_js_includes']; ?>" />
153 <?php } else { ?>
154 <link rel="stylesheet" href="<?php echo $GLOBALS['themes_static_relative']; ?>/misc/bootstrap_navbar.css?v=<?php echo $GLOBALS['v_js_includes']; ?>" />
155 <?php } ?>
157 <script src="<?php echo $GLOBALS['web_root']; ?>/interface/main/messages/js/reminder_appts.js?v=<?php echo $v_js_includes; ?>"></script>
158 </head>
160 <body>
161 <?php
162 if (($GLOBALS['medex_enable'] == '1') && (empty($_REQUEST['nomenu']))) {
163 $logged_in = $MedEx->login();
164 $MedEx->display->navigation($logged_in);
167 <div class="container mt-3">
168 <div id="flb_selectors" style="display:<?php echo attr($setting_selectors); ?>;">
169 <h2 class="text-center"><?php echo xlt('Flow Board'); ?></h2>
170 <div class="jumbotron p-4">
171 <div class="showRFlow text-center" id="show_flows" name="kiosk_hide">
172 <div name="div_response" id="div_response" class="nodisplay"></div>
173 <form name="flb" id="flb" method="post">
174 <div class="row">
175 <input type="hidden" name="csrf_token_form" value="<?php echo attr(CsrfUtils::collectCsrfToken()); ?>" />
176 <div class="text-center col-4 align-items-center">
177 <!-- Visit Categories Section -->
178 <div class="col-sm">
179 <select id="form_apptcat" name="form_apptcat" class="form-control form-control-sm" onchange="refineMe('apptcat');">
180 <?php
181 $categories = fetchAppointmentCategories();
182 echo "<option value=''>" . xlt("Visit Categories") . "</option>";
183 while ($cat = sqlFetchArray($categories)) {
184 echo "<option value='" . attr($cat['id']) . "'";
185 if ($cat['id'] == ($_POST['form_apptcat'] ?? null)) {
186 echo " selected='true' ";
188 echo ">" . xlt($cat['category']) . "</option>";
191 </select>
192 </div>
193 <!-- Visit Status Section -->
194 <div class="col-sm">
195 <select id="form_apptstatus" name="form_apptstatus" class="form-control form-control-sm" onchange="refineMe();">
196 <option value=""><?php echo xlt("Visit Status"); ?></option>
197 <?php
198 $apptstats = sqlStatement("SELECT * FROM list_options WHERE list_id = 'apptstat' AND activity = 1 ORDER BY seq");
199 while ($apptstat = sqlFetchArray($apptstats)) {
200 echo "<option value='" . attr($apptstat['option_id']) . "'";
201 if ($apptstat['option_id'] == ($_POST['form_apptstatus'] ?? null)) {
202 echo " selected='true' ";
204 echo ">" . xlt($apptstat['title']) . "</option>";
207 </select>
208 </div>
209 <!-- Facility Section -->
210 <div class="col-sm">
211 <select class="form-control form-control-sm" id="form_facility" name="form_facility"
212 <?php
213 $fac_sql = sqlStatement("SELECT * FROM facility ORDER BY id");
214 while ($fac = sqlFetchArray($fac_sql)) {
215 $true = ($fac['id'] == ($_POST['form_facility'] ?? null)) ? "selected=true" : '';
216 ($select_facs ?? null) ? $select_facs : $select_facs = '';
217 $select_facs .= "<option value=" . attr($fac['id']) . " " . $true . ">" . text($fac['name']) . "</option>\n";
218 ($count ?? null) ? $count_facs : $count_facs = 0;
219 $count_facs++;
221 if ($count_facs < '1') {
222 echo "disabled";
224 ?> onchange="refineMe('facility');">
225 <option value=""><?php echo xlt('All Facilities'); ?></option>
226 <?php echo $select_facs; ?>
227 </select>
228 </div>
230 <?php
231 // Build a drop-down list of ACTIVE providers.
232 $query = "SELECT id, lname, fname FROM users WHERE " .
233 "authorized = 1 AND active = 1 AND username > '' ORDER BY lname, fname"; #(CHEMED) facility filter
234 $ures = sqlStatement($query);
235 while ($urow = sqlFetchArray($ures)) {
236 $provid = $urow['id'];
237 ($select_provs ?? null) ? $select_provs : $select_provs = '';
238 $select_provs .= " <option value='" . attr($provid) . "'";
239 if (isset($_POST['form_provider']) && $provid == $_POST['form_provider']) {
240 $select_provs .= " selected";
241 } elseif (!isset($_POST['form_provider']) && $_SESSION['userauthorized'] && $provid == $_SESSION['authUserID']) {
242 $select_provs .= " selected";
244 $select_provs .= ">" . text($urow['lname']) . ", " . text($urow['fname']) . "\n";
245 ($count_provs ?? null) ? $count_provs : $count_provs = 0;
246 $count_provs++;
249 <!-- Provider Section -->
250 <div class="col-sm">
251 <select class="form-control form-control-sm" id="form_provider" name="form_provider" <?php
252 if ($count_provs < '2') {
253 echo "disabled";
255 ?> onchange="refineMe('provider');">
256 <option value="" selected><?php echo xlt('All Providers'); ?></option>
258 <?php
259 echo $select_provs;
261 </select>
262 </div>
263 </div>
264 <?php
265 if ($GLOBALS['ptkr_date_range'] == '1') {
266 $type = 'date';
267 $style = '';
268 } else {
269 $type = 'hidden';
270 $style = 'display:none;';
271 } ?>
272 <div class="col-4 mt-3 nowrap row" style="<?php echo $style; ?>">
274 <label class="col-form-label col-sm-3 text-right" for="flow_from"><?php echo xlt('From'); ?>:</label>
275 <div class="col-sm-9">
276 <input type="text" id="form_from_date" name="form_from_date" class="datepicker form-control form-control-sm text-center" value="<?php echo attr(oeFormatShortDate($from_date)); ?>"/>
277 </div>
278 <label class="col-form-label col-sm-3 text-right" for="flow_to"><?php echo xlt('To{{Range}}'); ?>:</label>
279 <div class="col-sm-9">
280 <input type="text" id="form_to_date" name="form_to_date" class="datepicker form-control form-control-sm text-center" value="<?php echo attr(oeFormatShortDate($to_date)); ?>"/>
281 </div>
283 <div class="col-sm-12 mt-3 mx-auto">
284 <button id="filter_submit" class="btn btn-primary btn-sm btn-filter"><?php echo xlt('Filter'); ?></button>
285 <input type="hidden" id="kiosk" name="kiosk" value="<?php echo attr($_REQUEST['kiosk'] ?? ''); ?>" />
286 </div>
287 </div>
288 <div class="col-4 mt-3 row">
289 <div class="col-sm-12 text-center">
290 <!-- Patient Name Section -->
291 <input type="text" placeholder="<?php echo xla('Patient Name'); ?>" class="form-control form-control-sm" id="form_patient_name" name="form_patient_name" value="<?php echo ($form_patient_name) ? attr($form_patient_name) : ""; ?>" onKeyUp="refineMe();" />
292 </div>
293 <div class="col-sm-12 text-center">
294 <!-- Patient ID Section -->
295 <input placeholder="<?php echo xla('Patient ID'); ?>" class="form-control form-control-sm" type="text" id="form_patient_id" name="form_patient_id" value="<?php echo ($form_patient_id) ? attr($form_patient_id) : ""; ?>" onKeyUp="refineMe();" />
296 </div>
297 <div class="col-sm-12 mx-auto">
298 <div class="text-center pt-3 mx-auto">
300 <?php if ($GLOBALS['medex_enable'] == '1') { ?>
301 <b>MedEx:</b>
302 <a href="https://medexbank.com/cart/upload/index.php?route=information/campaigns&amp;g=rem"
303 target="_medex">
304 <?php echo $current_events; ?>
305 </a>
306 <?php } ?>
307 </div>
308 </div>
309 </div>
310 <div id="message" class="warning"></div>
311 </div>
312 </form>
313 </div>
314 </div>
315 </div>
316 <div class="row-fluid">
317 <div class="col-md-12">
318 <div class="text-center row mx-auto divTable">
319 <div class="col-sm-12" id="loader">
320 <div class="spinner-border" role="status">
321 <span class="sr-only"><?php echo xlt('Loading data'); ?>...</span>
322 </div>
323 <h2><?php echo xlt('Loading data'); ?>...</h2>
324 </div>
325 <div id="flb_table" name="flb_table" class="w-100">
326 <?php
327 } else {
328 //end of if !$_REQUEST['flb_table'] - this is the table we fetch via ajax during a refreshMe() call
329 // get all appts for date range and refine view client side. very fast...
330 $appointments = array();
331 $datetime = date("Y-m-d H:i:s");
332 $appointments = fetch_Patient_Tracker_Events($from_date, $to_date, '', '', '', '', $form_patient_name, $form_patient_id);
333 $appointments = sortAppointments($appointments, 'date', 'time');
334 //grouping of the count of every status
335 $appointments_status = getApptStatus($appointments);
337 $chk_prov = array(); // list of providers with appointments
338 // Scan appointments for additional info
339 foreach ($appointments as $apt) {
340 $chk_prov[$apt['uprovider_id']] = $apt['ulname'] . ', ' . $apt['ufname'] . ' ' . $apt['umname'];
343 <div class="col-sm-12 text-center m-1">
344 <div class=" d-sm-block">
345 <span id="status_summary">
346 <?php
347 $statuses_output = "<span class='text badge badge-light'><em>" . xlt('Total patients') . ':</em> ' . text($appointments_status['count_all']) . "</span>";
348 unset($appointments_status['count_all']);
349 foreach ($appointments_status as $status_symbol => $count) {
350 $statuses_output .= " | <span><em>" . text(xl_list_label($statuses_list[$status_symbol])) . ":</em> <span class='badge badge-light'>" . text($count) . "</span></span>";
352 echo $statuses_output;
354 </span>
355 </div>
356 <div id="pull_kiosk_right" class="text-right">
357 <span class="fa-stack fa-lg" id="flb_caret" onclick="toggleSelectors();" title="<?php echo xla('Show/Hide the Selection Area'); ?>" style="color:<?php echo $color = ($setting_selectors == 'none') ? 'var(--danger)' : 'var(--black)'; ?>;">
358 <i class="far fa-square fa-stack-2x"></i>
359 <i id="print_caret" class='fa fa-caret-<?php echo $caret = ($setting_selectors == 'none') ? 'down' : 'up'; ?> fa-stack-1x'></i>
360 </span>
362 <a class="btn btn-primary btn-setting" data-toggle="collapse" href="#collapseSetting">
363 <?php echo xlt('Setting'); ?>
364 </a>
365 <a class='btn btn-primary btn-refresh' id='refreshme'><?php echo xlt('Refresh'); ?></a>
366 <a class='btn btn-primary btn-print' onclick="print_FLB();"> <?php echo xlt('Print'); ?></a>
367 <a class='btn btn-primary' onclick="kiosk_FLB();"> <?php echo xlt('Kiosk'); ?></a>
368 <div class="collapse mt-2 mb-2" id="collapseSetting">
369 <input type='checkbox' name='setting_new_window' id='setting_new_window' value='<?php echo attr($setting_new_window); ?>' <?php echo attr($setting_new_window); ?> />
370 <?php echo xlt('Open Patient in New Window'); ?>
371 </div>
372 </div>
373 </div>
375 <div class="table-responsive mt-3">
376 <table class="table table-bordered">
377 <thead class="table-primary">
378 <tr class="small font-weight-bold text-center">
379 <?php if ($GLOBALS['ptkr_show_pid']) { ?>
380 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
381 <?php echo xlt('PID'); ?>
382 </td>
383 <?php } ?>
384 <td class="dehead text-center text-ovr-dark" style="max-width: 150px;">
385 <?php echo xlt('Patient'); ?>
386 </td>
387 <?php if ($GLOBALS['ptkr_visit_reason'] == '1') { ?>
388 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
389 <?php echo xlt('Reason'); ?>
390 </td>
391 <?php } ?>
392 <?php if ($GLOBALS['ptkr_show_encounter']) { ?>
393 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
394 <?php echo xlt('Encounter'); ?>
395 </td>
396 <?php } ?>
398 <?php if ($GLOBALS['ptkr_date_range'] == '1') { ?>
399 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
400 <?php echo xlt('Appt Date'); ?>
401 </td>
402 <?php } ?>
403 <td class="dehead text-center text-ovr-dark">
404 <?php echo xlt('Appt Time'); ?>
405 </td>
406 <td class="dehead text-center text-ovr-dark">
407 <?php echo xlt('Arrive Time'); ?>
408 </td>
409 <td class="dehead text-center d-block d-sm-none text-ovr-dark">
410 <?php echo xlt('Arrival'); ?>
411 </td>
412 <td class="dehead text-center d-sm-table-cell text-ovr-dark">
413 <?php echo xlt('Appt Status'); ?>
414 </td>
415 <td class="dehead text-center d-sm-table-cell text-ovr-dark">
416 <?php echo xlt('Current Status'); ?>
417 </td>
418 <td class="dehead text-center d-block d-table-cell d-sm-none text-ovr-dark">
419 <?php echo xlt('Current'); ?>
420 </td>
421 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
422 <?php echo xlt('Visit Type'); ?>
423 </td>
424 <?php if (count($chk_prov) > 1) { ?>
425 <td class="dehead text-center d-sm-table-cell text-ovr-dark">
426 <?php echo xlt('Provider'); ?>
427 </td>
428 <?php } ?>
429 <td class="dehead text-center text-ovr-dark">
430 <?php echo xlt('Total Time'); ?>
431 </td>
432 <td class="dehead text-center d-sm-table-cell text-ovr-dark">
433 <?php echo xlt('Check Out Time'); ?>
434 </td>
435 <td class="dehead text-center d-block d-table-cell d-sm-none text-ovr-dark">
436 <?php echo xlt('Out Time'); ?>
437 </td>
438 <?php
439 if ($GLOBALS['ptkr_show_staff']) { ?>
440 <td class="dehead text-center text-ovr-dark" name="kiosk_hide">
441 <?php echo xlt('Updated By'); ?>
442 </td>
443 <?php
445 if ($_REQUEST['kiosk'] != '1') {
446 if ($GLOBALS['drug_screen']) { ?>
447 <td class="dehead center text-ovr-dark" name="kiosk_hide">
448 <?php echo xlt('Random Drug Screen'); ?>
449 </td>
450 <td class="dehead center text-ovr-dark" name="kiosk_hide">
451 <?php echo xlt('Drug Screen Completed'); ?>
452 </td>
453 <?php
455 } ?>
456 </tr>
457 </thead>
458 <tbody>
459 <?php
460 $prev_appt_date_time = "";
461 foreach ($appointments as $appointment) {
462 // Collect appt date and set up squashed date for use below
463 $date_appt = $appointment['pc_eventDate'];
464 $date_squash = str_replace("-", "", $date_appt);
465 if (empty($appointment['room']) && ($logged_in ?? null) && ($setting_bootstrap_submenu != 'hide')) {
466 //Patient has not arrived yet, display MedEx Reminder info
467 //one icon per type of response.
468 //If there was a SMS dialog, display it as a mouseover/title
469 //Display date received also as mouseover title.
470 $other_title = '';
471 $title = '';
472 $icon2_here = '';
473 $appt['stage'] = '';
474 $icon_here = array();
475 $prog_text = '';
476 $FINAL = '';
478 $query = "SELECT * FROM medex_outgoing WHERE msg_pc_eid =? ORDER BY medex_uid asc";
479 $myMedEx = sqlStatement($query, array($appointment['eid']));
481 * Each row for this pc_eid in the medex_outgoing table represents an event.
482 * Every event is recorded in $prog_text.
483 * A modality is represented by an icon (eg mail icon, phone icon, text icon).
484 * The state of the Modality is represented by the color of the icon:
485 * CONFIRMED = green
486 * READ = blue
487 * FAILED = pink
488 * SENT/in process = yellow
489 * SCHEDULED = white
490 * Icons are displayed in their highest state.
492 while ($row = sqlFetchArray($myMedEx)) {
493 // Need to convert $row['msg_date'] to localtime (stored as GMT) & then oeFormatShortDate it.
494 // I believe there is a new GLOBAL for server timezone??? If so, it will be easy.
495 // If not we need to import it from Medex through medex_preferences. It should really be in openEMR though.
496 // Delete when we figure this out.
497 $other_title = '';
498 if (!empty($row['msg_extra_text'])) {
499 $local = attr($row['msg_extra_text']) . " |";
501 $prog_text .= attr(oeFormatShortDate($row['msg_date'])) . " :: " . attr($row['msg_type']) . " : " . attr($row['msg_reply']) . " | " . $local . " |";
503 if ($row['msg_reply'] == 'Other') {
504 $other_title .= $row['msg_extra_text'] . "\n";
505 $icon_extra .= str_replace(
506 "EXTRA",
507 attr(oeFormatShortDate($row['msg_date'])) . "\n" . xla('Patient Message') . ":\n" . attr($row['msg_extra_text']) . "\n",
508 $icons[$row['msg_type']]['EXTRA']['html']
510 continue;
511 } elseif ($row['msg_reply'] == 'CANCELLED') {
512 $appointment[$row['msg_type']]['stage'] = "CANCELLED";
513 $icon_here[$row['msg_type']] = '';
514 } elseif ($row['msg_reply'] == "FAILED") {
515 $appointment[$row['msg_type']]['stage'] = "FAILED";
516 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['FAILED']['html'];
517 } elseif (($row['msg_reply'] == "CONFIRMED") || ($appointment[$row['msg_type']]['stage'] == "CONFIRMED")) {
518 $appointment[$row['msg_type']]['stage'] = "CONFIRMED";
519 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['CONFIRMED']['html'];
520 } elseif (($row['msg_reply'] == "READ") || ($appointment[$row['msg_type']]['stage'] == "READ")) {
521 $appointment[$row['msg_type']]['stage'] = "READ";
522 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['READ']['html'];
523 } elseif (($row['msg_reply'] == "SENT") || ($appointment[$row['msg_type']]['stage'] == "SENT")) {
524 $appointment[$row['msg_type']]['stage'] = "SENT";
525 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['SENT']['html'];
526 } elseif (($row['msg_reply'] == "To Send") || (empty($appointment['stage']))) {
527 if (
528 ($appointment[$row['msg_type']]['stage'] != "CONFIRMED") &&
529 ($appointment[$row['msg_type']]['stage'] != "READ") &&
530 ($appointment[$row['msg_type']]['stage'] != "SENT") &&
531 ($appointment[$row['msg_type']]['stage'] != "FAILED")
533 $appointment[$row['msg_type']]['stage'] = "QUEUED";
534 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['SCHEDULED']['html'];
537 //these are additional icons if present
538 if ($row['msg_reply'] == "CALL") {
539 $icon_here[$row['msg_type']] = $icons[$row['msg_type']]['CALL']['html'];
540 if (($appointment['allow_sms'] != "NO") && ($appointment['phone_cell'] > '')) {
541 $icon_4_CALL = "<span class='input-group-addon'
542 onclick='SMS_bot(" . attr_js($row['msg_pid']) . ");'>
543 <i class='fas fa-sms'></i>
544 </span>";
546 } elseif ($row['msg_reply'] == "STOP") {
547 $icon2_here .= $icons[$row['msg_type']]['STOP']['html'];
548 } elseif ($row['msg_reply'] == "Other") {
549 $icon2_here .= $icons[$row['msg_type']]['Other']['html'];
552 //if pc_apptstatus == '-', update it now to=status
553 if (!empty($other_title)) {
554 $appointment['messages'] = $icon2_here . $icon_extra;
558 // Collect variables and do some processing
559 $docname = $chk_prov[$appointment['uprovider_id']];
560 if (strlen($docname) <= 3) {
561 continue;
563 $ptname = $appointment['lname'] . ', ' . $appointment['fname'] . ' ' . $appointment['mname'];
564 $ptname_short = $appointment['fname'][0] . " " . $appointment['lname'][0];
565 $appt_enc = $appointment['encounter'];
566 $appt_eid = (!empty($appointment['eid'])) ? $appointment['eid'] : $appointment['pc_eid'];
567 $appt_pid = (!empty($appointment['pid'])) ? $appointment['pid'] : $appointment['pc_pid'];
568 if ($appt_pid == 0) {
569 continue; // skip when $appt_pid = 0, since this means it is not a patient specific appt slot
571 $status = (!empty($appointment['status']) && (!is_numeric($appointment['status']))) ? $appointment['status'] : $appointment['pc_apptstatus'];
572 $appt_room = (!empty($appointment['room'])) ? $appointment['room'] : $appointment['pc_room'];
573 $appt_time = (!empty($appointment['appttime'])) ? $appointment['appttime'] : $appointment['pc_startTime'];
574 $tracker_id = $appointment['id'];
575 // reason for visit
576 if ($GLOBALS['ptkr_visit_reason']) {
577 $reason_visit = $appointment['pc_hometext'];
579 $newarrive = collect_checkin($tracker_id);
580 $newend = collect_checkout($tracker_id);
581 $colorevents = (collectApptStatusSettings($status));
582 $bgcolor = $colorevents['color'];
583 $statalert = $colorevents['time_alert'];
584 // process the time to allow items with a check out status to be displayed
585 if (is_checkout($status) && (($GLOBALS['checkout_roll_off'] > 0) && strlen($form_apptstatus) != 1)) {
586 $to_time = strtotime($newend);
587 $from_time = strtotime($datetime);
588 $display_check_out = round(abs($from_time - $to_time) / 60, 0);
589 if ($display_check_out >= $GLOBALS['checkout_roll_off']) {
590 continue;
594 echo '<tr data-apptstatus="' . attr($appointment['pc_apptstatus']) . '"
595 data-apptcat="' . attr($appointment['pc_catid']) . '"
596 data-facility="' . attr($appointment['pc_facility']) . '"
597 data-provider="' . attr($appointment['uprovider_id']) . '"
598 data-pid="' . attr($appointment['pc_pid']) . '"
599 data-pname="' . attr($ptname) . '"
600 class="text-small"
601 style="background-color:' . attr($bgcolor) . ';" >';
603 if ($GLOBALS['ptkr_show_pid']) {
605 <td class="detail text-center" name="kiosk_hide">
606 <?php echo text($appt_pid); ?>
607 </td>
608 <?php
612 <td class="detail text-center" name="kiosk_hide">
613 <a href="#" onclick="return topatient(<?php echo attr_js($appt_pid); ?>,<?php echo attr_js($appt_enc); ?>)">
614 <?php echo text($ptname); ?></a>
615 </td>
617 <td class="detail text-center" style="white-space: normal;" name="kiosk_show">
618 <a href="#" onclick="return topatient(<?php echo attr_js($appt_pid); ?>,<?php echo attr_js($appt_enc); ?>)">
619 <?php echo text($ptname_short); ?></a>
620 </td>
622 <!-- reason -->
623 <?php if ($GLOBALS['ptkr_visit_reason']) { ?>
624 <td class="detail text-center" name="kiosk_hide">
625 <?php echo text($reason_visit) ?>
626 </td>
627 <?php } ?>
628 <?php if ($GLOBALS['ptkr_show_encounter']) { ?>
629 <td class="detail text-center" name="kiosk_hide">
630 <?php
631 if ($appt_enc != 0) {
632 echo text($appt_enc);
635 </td>
636 <?php } ?>
637 <?php if ($GLOBALS['ptkr_date_range'] == '1') { ?>
638 <td class="detail text-center" name="kiosk_hide">
639 <?php echo text(oeFormatShortDate($appointment['pc_eventDate']));
641 </td>
642 <?php } ?>
643 <td class="detail text-center">
644 <?php echo text(oeFormatTime($appt_time)); ?>
645 </td>
646 <td class="detail text-center">
647 <?php
648 if ($newarrive) {
649 echo text(oeFormatTime($newarrive));
652 </td>
653 <td class="detail text-center ">
654 <?php if (empty($tracker_id)) { //for appt not yet with tracker id and for recurring appt ?>
655 <a class="btn btn-primary btn-sm" onclick="return calendarpopup(<?php echo attr_js($appt_eid) . "," . attr_js($date_squash); // calls popup for add edit calendar event?>)">
656 <?php } else { ?>
657 <a class="btn btn-primary btn-s" onclick="return bpopup(<?php echo attr_js($tracker_id); // calls popup for patient tracker status?>)">
658 <?php } ?>
659 <?php
660 if ($appointment['room'] > '') {
661 echo text(getListItemTitle('patient_flow_board_rooms', $appt_room));
662 } else {
663 echo text(getListItemTitle("apptstat", $status)); // drop down list for appointment status
666 </a>
667 </td>
669 <?php
670 //time in current status
671 $to_time = strtotime(date("Y-m-d H:i:s"));
672 $yestime = '0';
673 if (strtotime($newend) != '') {
674 $from_time = strtotime($newarrive);
675 $to_time = strtotime($newend);
676 $yestime = '0';
677 } else {
678 $from_time = (($appointment['start_datetime'] ?? null) ? strtotime($appointment['start_datetime']) : null);
679 $yestime = '1';
682 $timecheck = round(abs($to_time - ($from_time ?? null)) / 60, 0);
683 if ($timecheck >= $statalert && ($statalert > '0')) { // Determine if the time in status limit has been reached.
684 echo "<td class='text-center js-blink-infinite small' nowrap> "; // and if so blink
685 } else {
686 echo "<td class='detail text-center' nowrap> "; // and if not do not blink
688 if (($yestime == '1') && ($timecheck >= 1) && (strtotime($newarrive) != '')) {
689 echo text($timecheck . ' ' . ($timecheck >= 2 ? xl('minutes') : xl('minute')));
690 } elseif (($icon_here ?? null) || ($icon2_here ?? null)) {
691 echo "<span style='font-size:0.7rem;' onclick='return calendarpopup(" . attr_js($appt_eid) . "," . attr_js($date_squash) . ")'>" . implode($icon_here) . $icon2_here . "</span> " . $icon_4_CALL;
692 } elseif ($logged_in ?? null) {
693 $pat = $MedEx->display->possibleModalities($appointment);
694 echo "<span style='font-size:0.7rem;' onclick='return calendarpopup(" . attr_js($appt_eid) . "," . attr_js($date_squash) . ")'>" . $pat['SMS'] . $pat['AVM'] . $pat['EMAIL'] . "</span>";
696 //end time in current status
697 echo "</td>";
699 <td class="detail text-center" name="kiosk_hide">
700 <?php echo xlt($appointment['pc_title']); ?>
701 </td>
702 <?php
703 if (count($chk_prov) > 1) { ?>
704 <td class="detail text-center d-sm-table-cell">
705 <?php echo text($docname); ?>
706 </td>
707 <?php
708 } ?>
709 <td class="detail text-center">
710 <?php
711 // total time in practice
712 if (strtotime($newend) != '') {
713 $from_time = strtotime($newarrive);
714 $to_time = strtotime($newend);
715 } else {
716 $from_time = strtotime($newarrive);
717 $to_time = strtotime(date("Y-m-d H:i:s"));
719 $timecheck2 = round(abs($to_time - $from_time) / 60, 0);
720 if (strtotime($newarrive) != '' && ($timecheck2 >= 1)) {
721 echo text($timecheck2 . ' ' . ($timecheck2 >= 2 ? xl('minutes') : xl('minute')));
723 // end total time in practice
724 echo text($appointment['pc_time'] ?? ''); ?>
725 </td>
726 <td class="detail text-center">
727 <?php
728 if (strtotime($newend) != '') {
729 echo text(oeFormatTime(substr($newend, 11))) ;
732 </td>
733 <?php
734 if ($GLOBALS['ptkr_show_staff'] == '1') {
736 <td class="detail text-center" name="kiosk_hide">
737 <?php echo text($appointment['user']) ?>
738 </td>
739 <?php
741 if ($GLOBALS['drug_screen']) {
742 if (strtotime($newarrive) != '') { ?>
743 <td class="detail text-center" name="kiosk_hide">
744 <?php
745 if ($appointment['random_drug_test'] == '1') {
746 echo xlt('Yes');
747 } else {
748 echo xlt('No');
749 } ?>
750 </td>
751 <?php
752 } else { ?>
753 <td class="detail text-center" name="kiosk_hide"></td>
754 <?php }
755 if (strtotime($newarrive) != '' && $appointment['random_drug_test'] == '1') { ?>
756 <td class="detail text-center" name="kiosk_hide">
757 <?php
758 if (strtotime($newend) != '') {
759 // the following block allows the check box for drug screens to be disabled once the status is check out ?>
760 <input type='checkbox' disabled='disable' class="drug_screen_completed" id="<?php echo attr($appointment['pt_tracker_id']) ?>" <?php echo ($appointment['drug_screen_completed'] == "1") ? "checked" : ""; ?> />
761 <?php
762 } else {
764 <input type='checkbox' class="drug_screen_completed" id='<?php echo attr($appointment['pt_tracker_id']) ?>' name="drug_screen_completed" <?php echo ($appointment['drug_screen_completed'] == "1") ? "checked" : ""; ?> />
765 <?php
766 } ?>
767 </td>
768 <?php
769 } else { ?>
770 <td class="detail text-center" name="kiosk_hide"></td>
771 <?php }
774 </tr>
775 <?php
776 } //end foreach
778 </tbody>
779 </table>
780 </div>
782 <?php
784 if (!($_REQUEST['flb_table'] ?? null)) { ?>
785 </div>
786 </div>
787 </div>
788 </div><?php //end container ?>
789 <!-- form used to open a new top level window when a patient row is clicked -->
790 <form name='fnew' method='post' target='_blank' action='../main/main_screen.php?auth=login&site=<?php echo attr_url($_SESSION['site_id']); ?>'>
791 <input type="hidden" name="csrf_token_form" value="<?php echo attr(CsrfUtils::collectCsrfToken()); ?>" />
792 <input type='hidden' name='patientID' value='0' />
793 <input type='hidden' name='encounterID' value='0' />
794 </form>
796 <?php echo myLocalJS(); ?>
797 </body>
798 </html>
799 <?php
800 } //end of second !$_REQUEST['flb_table']
803 exit;
805 function myLocalJS()
808 <script>
809 var auto_refresh = null;
810 //this can be refined to redact HIPAA material using @media print options.
811 window.parent.$("[name='flb']").attr('allowFullscreen', 'true');
812 $("[name='kiosk_hide']").show();
813 $("[name='kiosk_show']").hide();
815 function print_FLB() {
816 window.print();
819 function toggleSelectors() {
820 top.restoreSession();
821 if ($("#flb_selectors").css('display') === 'none') {
822 $.post("<?php echo $GLOBALS['webroot'] . "/interface/patient_tracker/patient_tracker.php"; ?>", {
823 setting_selectors: 'block',
824 csrf_token_form: <?php echo js_escape(CsrfUtils::collectCsrfToken()); ?>
825 }).done(
826 function (data) {
827 $("#flb_selectors").slideToggle();
828 if($("#flb_caret").hasClass('text-danger')) {
829 $("#flb_caret").removeClass('text-danger');
831 $("#flb_caret").addClass('text-body');
833 } else {
834 $.post("<?php echo $GLOBALS['webroot'] . "/interface/patient_tracker/patient_tracker.php"; ?>", {
835 setting_selectors: 'none',
836 csrf_token_form: <?php echo js_escape(CsrfUtils::collectCsrfToken()); ?>
837 }).done(
838 function (data) {
839 $("#flb_selectors").slideToggle();
840 if($("#flb_caret").hasClass('text-body')) {
841 $("#flb_caret").removeClass('text-body');
843 $("#flb_caret").addClass('text-danger');
846 $("#print_caret").toggleClass('fa-caret-up').toggleClass('fa-caret-down');
850 * This function refreshes the whole flb_table according to our to/from dates.
852 function refreshMe(fromTimer) {
854 if (typeof fromTimer === 'undefined' || !fromTimer) {
855 //Show loader in the first loading or manual loading not by timer
856 $("#flb_table").html('');
857 $('#loader').show();
858 skip_timeout_reset = 0;
859 } else {
860 skip_timeout_reset = 1;
863 var startRequestTime = Date.now();
864 top.restoreSession();
865 var posting = $.post('../patient_tracker/patient_tracker.php', {
866 flb_table: '1',
867 form_from_date: $("#form_from_date").val(),
868 form_to_date: $("#form_to_date").val(),
869 form_facility: $("#form_facility").val(),
870 form_provider: $("#form_provider").val(),
871 form_apptstatus: $("#form_apptstatus").val(),
872 form_patient_name: $("#form_patient_name").val(),
873 form_patient_id: $("#form_patient_id").val(),
874 form_apptcat: $("#form_apptcat").val(),
875 kiosk: $("#kiosk").val(),
876 skip_timeout_reset: skip_timeout_reset,
877 csrf_token_form: <?php echo js_escape(CsrfUtils::collectCsrfToken()); ?>
878 }).done(
879 function (data) {
880 //minimum 400 ms of loader (In the first loading or manual loading not by timer)
881 if((typeof fromTimer === 'undefined' || !fromTimer) && Date.now() - startRequestTime < 400 ){
882 setTimeout(drawTable, 500, data);
883 } else {
884 drawTable(data)
889 function drawTable(data) {
891 $('#loader').hide();
892 $("#flb_table").html(data);
893 if ($("#kiosk").val() === '') {
894 $("[name='kiosk_hide']").show();
895 $("[name='kiosk_show']").hide();
896 } else {
897 $("[name='kiosk_hide']").hide();
898 $("[name='kiosk_show']").show();
901 refineMe();
903 initTableButtons();
907 function refreshme() {
908 // Just need this to support refreshme call from the popup used for recurrent appt
909 refreshMe();
913 * This function hides all then shows only the flb_table rows that match our selection, client side.
914 * It is called on initial load, on refresh and 'onchange/onkeyup' of a flow board parameter.
916 function refineMe() {
917 var apptcatV = $("#form_apptcat").val();
918 var apptstatV = $("#form_apptstatus").val();
919 var facV = $("#form_facility").val();
920 var provV = $("#form_provider").val();
921 var pidV = String($("#form_patient_id").val());
922 var pidRE = new RegExp(pidV, 'g');
923 var pnameV = $("#form_patient_name").val();
924 var pnameRE = new RegExp(pnameV, 'ig');
926 //and hide what we don't want to show
927 $('#flb_table tbody tr').hide().filter(function () {
928 var d = $(this).data();
929 meets_cat = (apptcatV === '') || (apptcatV == d.apptcat);
930 meets_stat = (apptstatV === '') || (apptstatV == d.apptstatus);
931 meets_fac = (facV === '') || (facV == d.facility);
932 meets_prov = (provV === '') || (provV == d.provider);
933 meets_pid = (pidV === '');
934 if ((pidV > '') && pidRE.test(d.pid)) {
935 meets_pid = true;
937 meets_pname = (pnameV === '');
938 if ((pnameV > '') && pnameRE.test(d.pname)) {
939 meets_pname = true;
941 return meets_pname && meets_pid && meets_cat && meets_stat && meets_fac && meets_prov;
942 }).show();
945 // popup for patient tracker status
946 function bpopup(tkid) {
947 top.restoreSession();
948 dlgopen('../patient_tracker/patient_tracker_status.php?tracker_id=' + encodeURIComponent(tkid) + '&csrf_token_form=' + <?php echo js_url(CsrfUtils::collectCsrfToken()); ?>, '_blank', 500, 250);
949 return false;
952 // popup for calendar add edit
953 function calendarpopup(eid, date_squash) {
954 top.restoreSession();
955 dlgopen('../main/calendar/add_edit_event.php?eid=' + encodeURIComponent(eid) + '&date=' + encodeURIComponent(date_squash), '_blank', 775, 500);
956 return false;
959 // used to display the patient demographic and encounter screens
960 function topatient(newpid, enc) {
961 if ($('#setting_new_window').val() === 'checked') {
962 openNewTopWindow(newpid, enc);
964 else {
965 top.restoreSession();
966 if (enc > 0) {
967 top.RTop.location = "<?php echo $GLOBALS['webroot']; ?>/interface/patient_file/summary/demographics.php?set_pid=" + encodeURIComponent(newpid) + "&set_encounterid=" + encodeURIComponent(enc);
969 else {
970 top.RTop.location = "<?php echo $GLOBALS['webroot']; ?>/interface/patient_file/summary/demographics.php?set_pid=" + encodeURIComponent(newpid);
975 // opens the demographic and encounter screens in a new window
976 function openNewTopWindow(newpid, newencounterid) {
977 document.fnew.patientID.value = newpid;
978 document.fnew.encounterID.value = newencounterid;
979 top.restoreSession();
980 document.fnew.submit();
983 //opens the two-way SMS phone app
985 * @return {boolean}
987 function SMS_bot(pid) {
988 top.restoreSession();
989 var from = <?php echo js_escape($from_date ?? ''); ?>;
990 var to = <?php echo js_escape($to_date ?? ''); ?>;
991 var oefrom = <?php echo js_escape(oeFormatShortDate($from_date ?? null)); ?>;
992 var oeto = <?php echo js_escape(oeFormatShortDate($to_date ?? null)); ?>;
993 window.open('../main/messages/messages.php?nomenu=1&go=SMS_bot&pid=' + encodeURIComponent(pid) + '&to=' + encodeURIComponent(to) + '&from=' + encodeURIComponent(from) + '&oeto=' + encodeURIComponent(oeto) + '&oefrom=' + encodeURIComponent(oefrom), 'SMS_bot', 'width=370,height=600,resizable=0');
994 return false;
997 function kiosk_FLB() {
998 $("#kiosk").val('1');
999 $("[name='kiosk_hide']").hide();
1000 $("[name='kiosk_show']").show();
1002 var i = document.getElementById("flb_table");
1003 // go full-screen
1004 if (i.requestFullscreen) {
1005 i.requestFullscreen();
1006 } else if (i.webkitRequestFullscreen) {
1007 i.webkitRequestFullscreen();
1008 } else if (i.mozRequestFullScreen) {
1009 i.mozRequestFullScreen();
1010 } else if (i.msRequestFullscreen) {
1011 i.msRequestFullscreen();
1013 // refreshMe();
1016 function KioskUp() {
1017 var kv = $("#kiosk").val();
1018 if (kv == '0') {
1019 $("#kiosk").val('1');
1020 $("[name='kiosk_hide']").show();
1021 $("[name='kiosk_show']").hide();
1022 } else {
1023 $("#kiosk").val('0');
1024 $("[name='kiosk_hide']").hide();
1025 $("[name='kiosk_show']").show();
1029 $(function () {
1030 refreshMe();
1031 $("#kiosk").val('');
1032 $("[name='kiosk_hide']").show();
1033 $("[name='kiosk_show']").hide();
1035 onresize = function () {
1036 var state = 1 >= outerHeight - innerHeight ? "fullscreen" : "windowed";
1037 if (window.state === state) return;
1038 window.state = state;
1039 var event = document.createEvent("Event");
1040 event.initEvent(state, true, true);
1041 window.dispatchEvent(event);
1044 ["fullscreenchange", "webkitfullscreenchange", "mozfullscreenchange", "msfullscreenchange"].forEach(
1045 eventType => document.addEventListener(eventType, KioskUp, false)
1048 <?php if ($GLOBALS['pat_trkr_timer'] != '0') { ?>
1049 var reftime = <?php echo js_escape($GLOBALS['pat_trkr_timer']); ?>;
1050 var parsetime = reftime.split(":");
1051 parsetime = (parsetime[0] * 60) + (parsetime[1] * 1) * 1000;
1052 if (auto_refresh) clearInteral(auto_refresh);
1053 auto_refresh = setInterval(function () {
1054 refreshMe(true) // this will run after every parsetime seconds
1055 }, parsetime);
1056 <?php } ?>
1058 $('.js-blink-infinite').each(function () {
1059 // set up blinking text
1060 var elem = $(this);
1061 setInterval(function () {
1062 if (elem.css('visibility') === 'hidden') {
1063 elem.css('visibility', 'visible');
1064 } else {
1065 elem.css('visibility', 'hidden');
1067 }, 500);
1069 // toggle of the check box status for drug screen completed and ajax call to update the database
1070 $('body').on('click', '.drug_screen_completed', function () {
1071 top.restoreSession();
1072 if (this.checked) {
1073 testcomplete_toggle = "true";
1074 } else {
1075 testcomplete_toggle = "false";
1077 $.post("../../library/ajax/drug_screen_completed.php", {
1078 trackerid: this.id,
1079 testcomplete: testcomplete_toggle,
1080 csrf_token_form: <?php echo js_escape(CsrfUtils::collectCsrfToken()); ?>
1084 // mdsupport - Immediately post changes to setting_new_window
1085 $('body').on('click', '#setting_new_window', function () {
1086 $('#setting_new_window').val(this.checked ? 'checked' : ' ');
1087 top.restoreSession();
1088 $.post("<?php echo $GLOBALS['webroot'] . "/interface/patient_tracker/patient_tracker.php"; ?>", {
1089 setting_new_window: $('#setting_new_window').val(),
1090 csrf_token_form: <?php echo js_escape(CsrfUtils::collectCsrfToken()); ?>
1091 }).done(
1092 function (data) {
1096 $('#filter_submit').click(function (e) {
1097 e.preventDefault;
1098 refreshMe();
1101 $('[data-toggle="tooltip"]').tooltip();
1103 $('.datepicker').datetimepicker({
1104 <?php $datetimepicker_timepicker = false; ?>
1105 <?php $datetimepicker_showseconds = false; ?>
1106 <?php $datetimepicker_formatInput = true; ?>
1107 <?php require($GLOBALS['srcdir'] . '/js/xl/jquery-datetimepicker-2-5-4.js.php'); ?>
1108 <?php // can add any additional javascript settings to datetimepicker here; need to prepend first setting with a comma ?>
1113 function initTableButtons() {
1114 $('#refreshme').click(function () {
1115 refreshMe();
1116 refineMe();
1120 initTableButtons();
1122 </script>
1123 <?php }