forked from openemr/openemr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add bootstrap to modernize work school note form (openemr#6947)
* Add bootstrap to modernize * removing short tags
- Loading branch information
1 parent
b1149d5
commit 7572f0d
Showing
1 changed file
with
75 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,11 +10,12 @@ | |
* @copyright Copyright (c) 2004-2005 Nikolai Vitsyn | ||
* @copyright Copyright (c) Open Source Medical Software | ||
* @copyright Copyright (c) 2019 Brady Miller <[email protected]> | ||
* [email protected] added bootstrap 2023 | ||
* @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3 | ||
*/ | ||
|
||
|
||
require_once(__DIR__ . "/../../globals.php"); | ||
require_once dirname(__FILE__, 3) . "/globals.php"; | ||
require_once("$srcdir/api.inc.php"); | ||
|
||
use OpenEMR\Common\Csrf\CsrfUtils; | ||
|
@@ -26,95 +27,82 @@ | |
/* name of this form */ | ||
$form_name = "note"; | ||
?> | ||
|
||
<html><head> | ||
|
||
<?php Header::setupHeader('datetime-picker'); ?> | ||
|
||
<script> | ||
// required for textbox date verification | ||
var mypcc = <?php echo js_escape($GLOBALS['phone_country_code']); ?>; | ||
</script> | ||
|
||
<html> | ||
<head> | ||
<?php Header::setupHeader('datetime-picker'); ?> | ||
<script> | ||
// required for textbox date verification | ||
const mypcc = <?php echo js_escape($GLOBALS['phone_country_code']); ?>; | ||
|
||
$(function () { | ||
$('.datepicker').datetimepicker({ | ||
<?php $datetimepicker_timepicker = true; ?> | ||
<?php $datetimepicker_showseconds = true; ?> | ||
<?php $datetimepicker_formatInput = true; ?> | ||
<?php require($GLOBALS['srcdir'] . '/js/xl/jquery-datetimepicker-2-5-4.js.php'); ?> | ||
<?php // can add any additional javascript settings to datetimepicker here; need to prepend first setting with a comma ?> | ||
}); | ||
}); | ||
</script> | ||
</head> | ||
|
||
<body class="body_top"> | ||
<?php echo text(date("F d, Y", time())); ?> | ||
|
||
<form method=post action="<?php echo $rootdir . "/forms/" . $form_name . "/save.php?mode=new";?>" name="my_form" id="my_form"> | ||
<input type="hidden" name="csrf_token_form" value="<?php echo attr(CsrfUtils::collectCsrfToken()); ?>" /> | ||
|
||
<span class="title"><?php echo xlt('Work/School Note'); ?></span><br /><br /> | ||
|
||
<div style="margin: 10px;"> | ||
<input type="button" class="save" value=" <?php echo xla('Save'); ?> "> | ||
<input type="button" class="dontsave" value="<?php echo xla('Don\'t Save'); ?>"> | ||
</div> | ||
|
||
<select name="note_type"> | ||
<option value="WORK NOTE"><?php echo xlt('WORK NOTE'); ?></option> | ||
<option value="SCHOOL NOTE"><?php echo xlt('SCHOOL NOTE'); ?></option> | ||
</select> | ||
<br /> | ||
<b><?php echo xlt('MESSAGE:'); ?></b> | ||
<br /> | ||
<textarea name="message" id="message" rows="7" cols="47"></textarea> | ||
<br /> | ||
|
||
<?php | ||
// commented out below private field, because no field in database, and causes error. | ||
?> | ||
<!-- | ||
<input type="checkbox" name="private" id="private"><label for="private">This note is private</label> | ||
<br /> | ||
--> | ||
|
||
<br /> | ||
<b><?php echo xlt('Signature:'); ?></b> | ||
<br /> | ||
|
||
<table> | ||
<tr><td> | ||
<?php echo xlt('Doctor:'); ?> | ||
<input type="text" name="doctor" id="doctor" value="<?php echo attr($provider_results["fname"]) . ' ' . attr($provider_results["lname"]); ?>"> | ||
</td> | ||
|
||
<td> | ||
<span class="text"><?php echo xlt('Date'); ?></span> | ||
<input type='text' size='10' class='datepicker' name='date_of_signature' id='date_of_signature' | ||
value='<?php echo attr(date('Y-m-d', time())); ?>' | ||
title='<?php echo xla('yyyy-mm-dd'); ?>' /> | ||
</td> | ||
</tr> | ||
</table> | ||
|
||
<div style="margin: 10px;"> | ||
<input type="button" class="save" value=" <?php echo xla('Save'); ?> "> | ||
<input type="button" class="dontsave" value="<?php echo xla('Don\'t Save'); ?>"> | ||
</div> | ||
|
||
</form> | ||
|
||
<body> | ||
<div class="container"> | ||
<div class="row"> | ||
<div class="col-sm-12 mt-5"> | ||
<h1><?php echo xlt('Work/School Note'); ?></h1> | ||
<?php echo text(date("F d, Y", time())); ?> | ||
</div> | ||
<div class="row"> | ||
<div class="col-sm-12"> | ||
<form class="form" method=post action="<?php echo $rootdir . "/forms/" . $form_name . "/save.php?mode=new";?>" name="my_form" id="my_form"> | ||
<input type="hidden" name="csrf_token_form" value="<?php echo attr(CsrfUtils::collectCsrfToken()); ?>" /> | ||
|
||
<div style="margin: 10px;"> | ||
<input type="button" class="btn btn-primary save" value=" <?php echo xla('Save'); ?> "> | ||
<input type="button" class="btn btn-warning dontsave" value="<?php echo xla('Don\'t Save'); ?>"> | ||
</div> | ||
|
||
<select class="form-control" name="note_type"> | ||
<option value="WORK NOTE"><?php echo xlt('WORK NOTE'); ?></option> | ||
<option value="SCHOOL NOTE"><?php echo xlt('SCHOOL NOTE'); ?></option> | ||
</select> | ||
<br /> | ||
<b><?php echo xlt('MESSAGE:'); ?></b> | ||
<br /> | ||
<textarea class="form-control" name="message" id="message" rows="7" cols="47"></textarea> | ||
<br /> | ||
|
||
<br /> | ||
<b><?php echo xlt('Signature:'); ?></b> | ||
<br /> | ||
<table class="table"> | ||
<tr><td> | ||
<?php echo xlt('Doctor:'); ?> | ||
<input class="form-control" type="text" name="doctor" id="doctor" value="<?php echo attr($provider_results["fname"]) . ' ' . attr($provider_results["lname"]); ?>"> | ||
</td> | ||
|
||
<td> | ||
<span class="text"><?php echo xlt('Date'); ?></span> | ||
<input class="datepicker form-control" type='text' size='10' class='datepicker' name='date_of_signature' id='date_of_signature' | ||
value='<?php echo attr(date('Y-m-d', time())); ?>' | ||
title='<?php echo xla('yyyy-mm-dd'); ?>' /> | ||
</td> | ||
</tr> | ||
</table> | ||
<div style="margin: 10px;"> | ||
<input type="button" class="btn btn-primary save" value=" <?php echo xla('Save'); ?> "> | ||
<input type="button" class="btn btn-warning dontsave" value="<?php echo xla('Don\'t Save'); ?>"> | ||
</div> | ||
</form> | ||
</div> | ||
</div> | ||
</div> | ||
</body> | ||
|
||
<script> | ||
|
||
// jQuery stuff to make the page a little easier to use | ||
|
||
$(function () { | ||
$(".save").click(function() { top.restoreSession(); $('#my_form').submit(); }); | ||
$(".dontsave").click(function() { parent.closeTab(window.name, false); }); | ||
//$("#printform").click(function() { PrintForm(); }); | ||
|
||
$('.datepicker').datetimepicker({ | ||
<?php $datetimepicker_timepicker = false; ?> | ||
<?php $datetimepicker_showseconds = false; ?> | ||
<?php $datetimepicker_formatInput = false; ?> | ||
<?php require($GLOBALS['srcdir'] . '/js/xl/jquery-datetimepicker-2-5-4.js.php'); ?> | ||
<?php // can add any additional javascript settings to datetimepicker here; need to prepend first setting with a comma ?> | ||
// jQuery stuff to make the page a little easier to use | ||
$(function () { | ||
$(".save").click(function() { top.restoreSession(); $('#my_form').submit(); }); | ||
$(".dontsave").click(function() { parent.closeTab(window.name, false); }); | ||
}); | ||
}); | ||
|
||
</script> | ||
|
||
</html> |