104 lines
3.8 KiB
PHP
104 lines
3.8 KiB
PHP
![]() |
<script>
|
||
|
function validate() {
|
||
|
|
||
|
var entry_time = $('#entry_time').val();
|
||
|
if (entry_time == '' || entry_time == null) {
|
||
|
BootstrapDialog.alert('Please Enter Time.!!!');
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
|
||
|
var hos_remark = $('#hos-remark').val();
|
||
|
if (hos_remark == '' || hos_remark == null) {
|
||
|
BootstrapDialog.alert('Please Enter Details.!!!');
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
|
||
|
var appointment_id = $("#appointment_id").val();
|
||
|
save_hos_details(appointment_id);
|
||
|
}
|
||
|
</script>
|
||
|
|
||
|
|
||
|
|
||
|
<style>
|
||
|
#modal-add-hos-details {
|
||
|
overflow-y: scroll;
|
||
|
}
|
||
|
</style>
|
||
|
|
||
|
<div class="modal fade" id="modal-add-hos-details" role="dialog" aria-hidden="true">
|
||
|
<form role="form" id="hos_form" name="hos_form" action="#" method="post">
|
||
|
<div class="modal-dialog">
|
||
|
<div class="modal-content">
|
||
|
<div class="widget-header">
|
||
|
<h5 class="widget-title">Hospitalization Details Form</h5>
|
||
|
<div class="widget-toolbar">
|
||
|
<div class="widget-menu">
|
||
|
<a href="#" class="close" data-action="close" data-dismiss="modal">
|
||
|
<i class="ace-icon fa fa-times"></i>
|
||
|
</a>
|
||
|
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
<div class="modal-body">
|
||
|
|
||
|
<div class="form-group">
|
||
|
<label class="control-label" for="additional_advices"><strong style="font-size: 11px">Time:</strong></label>
|
||
|
|
||
|
|
||
|
<div class="input-group" id="discharge">
|
||
|
<input id="entry_time" type="text" class="form-control" style="height: 30px"
|
||
|
name="entry_time" /> <span class="input-group-addon"> <i style="height: 5px"
|
||
|
class="fa fa-clock-o bigger-110"></i>
|
||
|
</span>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
|
||
|
<div class="form-group">
|
||
|
<label for="hos-remark">Additional Details</label>
|
||
|
<input type="hidden" class="form-control" name="appointment_id" id="appointment_id" value=""
|
||
|
required />
|
||
|
<textarea class="form-control" name="hos-remark" id="hos-remark" cols="30" rows="5"></textarea>
|
||
|
|
||
|
</div>
|
||
|
|
||
|
|
||
|
</div>
|
||
|
<div class="widget-toolbox padding-8 clearfix">
|
||
|
<button type="button" class="btn btn-info btn-sm save_button" onclick="validate();"><i
|
||
|
class="ace-icon fa fa-floppy-o bigger-110"></i>Save </button>
|
||
|
<button type="button" class="btn btn-danger btn-sm" data-dismiss="modal"><i
|
||
|
class="ace-icon fa fa-times bigger-110"></i>Cancel</button>
|
||
|
</div>
|
||
|
|
||
|
</div>
|
||
|
</div>
|
||
|
</form>
|
||
|
</div>
|
||
|
|
||
|
<script>
|
||
|
if (!ace.vars['old_ie']) $('#entry_time').datetimepicker({
|
||
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
||
|
<?php if (isset($row['entry_time']) && $row['entry_time'] != '0000-00-00 00:00:00') { ?>
|
||
|
defaultDate: new Date("<?php echo $row['entry_time'] ?>"),
|
||
|
<?php } ?>
|
||
|
maxDate: new Date(new Date().setDate(new Date().getDate() + 30)),
|
||
|
icons: {
|
||
|
time: 'fa fa-clock-o',
|
||
|
date: 'fa fa-calendar',
|
||
|
up: 'fa fa-chevron-up',
|
||
|
down: 'fa fa-chevron-down',
|
||
|
previous: 'fa fa-chevron-left',
|
||
|
next: 'fa fa-chevron-right',
|
||
|
today: 'fa fa-arrows ',
|
||
|
clear: 'fa fa-trash',
|
||
|
close: 'fa fa-times'
|
||
|
}
|
||
|
}).next().on(ace.click_event, function () {
|
||
|
$(this).prev().focus();
|
||
|
});
|
||
|
</script>
|