1735 lines
98 KiB
PHP
1735 lines
98 KiB
PHP
<link rel="stylesheet" href="assets/font-awesome/4.5.0/css/font-awesome.min.css" />
|
|
|
|
<!-- page specific plugin styles -->
|
|
<link rel="stylesheet" href="assets/css/jquery-ui.custom.min.css" />
|
|
<link rel="stylesheet" href="assets/css/chosen.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-datepicker3.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-timepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/daterangepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-datetimepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-colorpicker.min.css" />
|
|
<link rel="stylesheet" href="adminlte/bower_components/bootstrap/less/type.less" />
|
|
<script src="assets/js/jquery-ui.custom.min.js"></script>
|
|
<script src="assets/js/jquery.ui.touch-punch.min.js"></script>
|
|
<script src="assets/js/chosen.jquery.min.js"></script>
|
|
<script src="assets/js/spinbox.min.js"></script>
|
|
<script src="assets/js/bootstrap-datepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-timepicker.min.js"></script>
|
|
<script src="assets/js/jquery.dataTables.min.js"></script>
|
|
<script src="assets/js/jquery.dataTables.bootstrap.min.js"></script>
|
|
<script src="assets/js/dataTables.buttons.min.js"></script>
|
|
<script src="assets/js/buttons.flash.min.js"></script>
|
|
<script src="assets/js/buttons.html5.min.js"></script>
|
|
<script src="assets/js/buttons.print.min.js"></script>
|
|
<script src="assets/js/buttons.colVis.min.js"></script>
|
|
<script src="assets/js/dataTables.select.min.js"></script>
|
|
|
|
|
|
<script src="assets/js/moment.min.js"></script>
|
|
<script src="assets/js/daterangepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-datetimepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-colorpicker.min.js"></script>
|
|
<script src="assets/js/jquery.knob.min.js"></script>
|
|
<script src="assets/js/autosize.min.js"></script>
|
|
<script src="assets/js/jquery.inputlimiter.min.js"></script>
|
|
<script src="assets/js/jquery.maskedinput.min.js"></script>
|
|
<script src="assets/js/bootstrap-tag.min.js"></script>
|
|
<script src="assets/js/ace-elements.min.js"></script>
|
|
|
|
<script type="text/javascript">
|
|
$(document).ready(function() {
|
|
$(".glyphicon").css("top", "");
|
|
|
|
|
|
});
|
|
|
|
function open_treatments(appointment_id) {
|
|
$('#modal-add-consultation').modal("show");
|
|
|
|
}
|
|
</script>
|
|
<?php
|
|
include('includes/config/config.php');
|
|
$rolecode = $_SESSION['RoleCode'];
|
|
$id = $_REQUEST['appointmentId'];
|
|
|
|
if (isset($_REQUEST['appointmentId'])) {
|
|
$sql = "select * from employee_appointment where appointment_id='" . $_REQUEST['appointmentId'] . "'";
|
|
// echo "query:".$sql;error_log("APPOINTMENT QUERY::" .$query);
|
|
$result = mysqli_query($conn, $sql);
|
|
$num_rows = @mysqli_num_rows($result);
|
|
$row = null;
|
|
|
|
// echo fhfh;
|
|
if ($num_rows > 0) {
|
|
$row = @mysqli_fetch_array($result);
|
|
}
|
|
$sql_for_treatment = "select * from treatment where appointment_id='" . $_REQUEST['appointmentId'] . "' and is_display!='N'";
|
|
$result_for_treatment = @mysqli_query($conn, $sql_for_treatment);
|
|
$num_rows_treatment = @mysqli_num_rows($result_for_treatment);
|
|
|
|
$sql_for_treatment_external = "select * from treatment_external where appointment_id='" . $_REQUEST['appointmentId'] . "'";
|
|
$result_for_treatment_external = @mysqli_query($conn, $sql_for_treatment_external);
|
|
$num_rows_treatment_external = @mysqli_num_rows($result_for_treatment_external);
|
|
//If Its a follow up OPD/INJURY case - then add treatment details from the existing
|
|
$treatment_followup_picked = false;
|
|
if ($num_rows_treatment == 0 && $num_rows_treatment_external == 0 && ($row['followup_to_opd'] != null && $row['followup_to_opd'] != "0")) {
|
|
|
|
$sql_for_treatment = "select * from treatment where appointment_id='" . $row['followup_to_opd'] . "' and is_display!='N'";
|
|
$result_for_treatment = @mysqli_query($conn, $sql_for_treatment);
|
|
$num_rows_treatment = @mysqli_num_rows($result_for_treatment);
|
|
|
|
$sql_for_treatment_external = "select * from treatment_external where appointment_id='" . $row['followup_to_opd'] . "'";
|
|
$result_for_treatment_external = @mysqli_query($conn, $sql_for_treatment_external);
|
|
$num_rows_treatment_external = @mysqli_num_rows($result_for_treatment_external);
|
|
$treatment_followup_picked = true;
|
|
}
|
|
}
|
|
?>
|
|
<script>
|
|
var rolecode = '<?php echo $_SESSION['RoleCode'] ?>';
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<form id="opd_form" method="post">
|
|
<div class="widget-box" id="opd_form_pdf">
|
|
<div class="widget-header" data-action="fullscreen">
|
|
<h5 class="widget-title">Patient injury > <?php echo $patient_name ?> <a target="_blank"
|
|
href="emp_dashboard.php?flex_patient_id=<?php echo $row1['emp_id'] ?>"><i style="font-size: 17px;"
|
|
class="glyphicon glyphicon-user"></i></a>
|
|
|
|
|
|
<div class="widget-toolbar" style="float: right">
|
|
<div class="clearfix">
|
|
<div class="pull-right tableTools-container">
|
|
<div class="dt-buttons btn-overlap btn-group ">
|
|
<a class="dt-button buttons-csv buttons-html5 btn btn-white btn-primary btn-bold save_button"
|
|
style="float: left;" onclick="add_consume();"><i
|
|
class="fa fa-medkit bigger-110 red" onclick="add_consume();"></i>
|
|
CONSUMABLES</a>
|
|
|
|
|
|
<a href="<?php echo $_REQUEST['returnPage'] . '&backButon=back' ?>"
|
|
class="dt-button buttons-csv buttons-html5 btn btn-white btn-primary btn-bold save_button"
|
|
style="float: left;">Back</a>
|
|
<a onclick="convertToOPD()"
|
|
class="dt-button buttons-csv buttons-html5 btn btn-white btn-primary btn-bold save_button"
|
|
style="float: left;">Convert to OPD</a>
|
|
<a class="dt-button buttons-csv buttons-html5 btn btn-white btn-primary btn-bold save_button"
|
|
id="forwardButton" tabindex="0" aria-controls="dynamic-table" data-original-title=""
|
|
title=""><span><i class="fa fa-floppy-o bigger-110 green"></i> <span
|
|
class="hidden">Save</span></span></a>
|
|
<?php if ($row['doctor_attended_flag'] == 'Y') { ?> <a
|
|
class="dt-button buttons-print btn btn-white btn-primary btn-bold"
|
|
onclick="exporttopdf();" tabindex="0" aria-controls="dynamic-table"
|
|
data-original-title="" title=""><span><i class="fa fa-print bigger-110 grey"></i>
|
|
<span class="hidden">Print</span></span></a>
|
|
<?php } ?>
|
|
<a class="dt-button buttons-print btn btn-white btn-primary btn-bold"
|
|
data-action="fullscreen" tabindex="0" aria-controls="dynamic-table"
|
|
data-original-title="" title=""><span><i
|
|
class="fa fa fa-expand bigger-110 grey"></i> <span
|
|
class="hidden">Maximize</span></span></a> <input type="hidden"
|
|
name="attendedStatus" id="attendedStatus" <?php if ($rolecode == 'DOC') { ?>
|
|
value="<?php echo $__STATUS_DOCTOR_ATTENDED ?>" <?php } ?>
|
|
<?php if ($rolecode == 'DIS') { ?> value="<?php echo $__STATUS_PHARMACY_ATTENDED ?>"
|
|
<?php } ?> /> <input type="hidden" name="doctor_last_attended"
|
|
id="doctor_last_attended" <?php if ($rolecode == 'DOC') { ?>
|
|
value="<?php echo $_SESSION['user_id'] ?>" <?php } else { ?>
|
|
value="<?php echo $row['doctor_last_attended'] ?>" <?php } ?> />
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="widget-body">
|
|
<div class="widget-main">
|
|
<div class="row">
|
|
<div class="col-xs-9 table-responsive">
|
|
<div class="widget-box">
|
|
|
|
<div class="widget-body">
|
|
<div class="widget-main">
|
|
<div class="row">
|
|
<div class="col-xs-12">
|
|
<div class="row">
|
|
|
|
<div class="col-sm-2">
|
|
<label class="control-label" for="appoint"><strong
|
|
style="font-size: 11px">Medical Record No:</strong></label>
|
|
<input id="ticket_no" type="hidden" name="ticket_no"
|
|
value="<?php echo $row['ticket_no']; ?>" />
|
|
<div class="input-group">
|
|
|
|
|
|
<?php echo $row['ticket_no']; ?>
|
|
<input id="appoint" type="hidden" name="appoint"
|
|
value="<?php echo $_REQUEST['appointmentId'] ?> " />
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-sm-2">
|
|
<label class="control-label" for="appointment_date"><strong
|
|
style="font-size: 11px">In time</strong></label>
|
|
|
|
<div class="input-group">
|
|
<input id="emp_id" name="emp_id" type="hidden"
|
|
value="<?php echo $row['emp_id'] ?>" /> <input
|
|
id="appointment_id" name="appointment_id"
|
|
value="<?php echo $row_history['appointment_id'] ?>"
|
|
type="hidden" />
|
|
<input type="hidden" name="doctor_attended_flag"
|
|
id="doctor_attended_flag"
|
|
<?php if ($rolecode == 'DOC' || $row['doctor_attended_flag'] == 'Y') { ?>
|
|
value="Y" <?php } else { ?> value="N" <?php } ?>>
|
|
<input id="appointment_type" name="appointment_type"
|
|
type="hidden" value="I" /> <input id="appointment_date"
|
|
type="text" class="form-control" style="height: 30px"
|
|
name="appointment_date" /> <span class="input-group-addon">
|
|
<i style="height: 5px" class="fa fa-clock-o bigger-110"></i>
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<?php if ($_SESSION['RoleCode'] == 'DIS') { ?>
|
|
<div class="col-sm-2">
|
|
<label class="control-label" for="appointment_date"><strong
|
|
style="font-size: 11px">Clearance Time</strong></label>
|
|
|
|
<div class="input-group">
|
|
<input id="out_time" type="text" style="height: 30px"
|
|
class="form-control" name="out_time" /> <span
|
|
class="input-group-addon"> <i
|
|
class="fa fa-clock-o bigger-110"
|
|
style="height: 5px;"></i>
|
|
</span>
|
|
</div>
|
|
|
|
</div>
|
|
<? } ?>
|
|
|
|
<div class=" col-sm-3">
|
|
|
|
<label class="control-label" for="followup_to_opd"><strong
|
|
style="font-size: 11px">Case Type</strong></label>
|
|
|
|
|
|
<select class="form-control" id="case_type" name="case_type">
|
|
<option value="">None</option>
|
|
<option value="NEW" <?php if (strcmp($row['case_type'], 'NEW') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
New Case</option>
|
|
<option value="REP" <?php if (strcmp($row['case_type'], 'REP') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Repeat</option>
|
|
<option value="FUP" <?php if (strcmp($row['case_type'], 'FUP') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Follow up</option>
|
|
<option value="EFUP" <?php if (strcmp($row['case_type'], 'EFUP') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Executive Follow up</option>
|
|
<option value="MED" <?php if (strcmp($row['case_type'], 'MED') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Medication</option>
|
|
</select>
|
|
|
|
|
|
</div>
|
|
|
|
<div class=" col-sm-3">
|
|
<label class="control-label" for="followup_to_opd"><strong
|
|
style="font-size: 11px">Followup to(if
|
|
Applicable)</strong></label>
|
|
|
|
<div class="input-group">
|
|
<select id="followup_to_opd" name="followup_to_opd">
|
|
<option value="">None</option>
|
|
<?php echo generateOptionWithWhereClause('employee_appointment', "CONCAT(ticket_no,' ',DATE_FORMAT(appointment_date,'%d-%b-%Y %l:%i %p '))", 'appointment_id', '', '', 'emp_id', ($_REQUEST['flex_opd_id'] != '' ? $_REQUEST['flex_opd_id'] : $_REQUEST['flex_patient_id'])); ?>
|
|
</select>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
<div class="space-6"></div>
|
|
|
|
<div class="row">
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Referred By</strong></label>
|
|
<br>
|
|
|
|
|
|
<select class="form-control" id="referred_by" name="referred_by">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<?php echo generateOption('referred_by_master', 'referred_by', 'id', $row['referred_by'], '') ?>
|
|
</select>
|
|
|
|
|
|
</div>
|
|
<?php
|
|
$complaint_config = getFieldFromTable('value', 'config', 'key_name', 'complaint_tag_switch');
|
|
error_log("complaints_config tag switch " . $complaint_config . " compare " . strcmp(strtolower($complaint_config), "false"));
|
|
if (!strcmp(strtolower($complaint_config), "false")) {
|
|
?>
|
|
<div class="col-sm-3">
|
|
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Complaints</strong></label>
|
|
<br>
|
|
|
|
|
|
<div>
|
|
<select class="form-control chosen-select" name="complaints[]"
|
|
id="complaints" multiple>
|
|
<?php echo generateOption('complaints', 'complaint', 'complaint_id', '', '') ?>
|
|
</select>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<?php
|
|
} else { ?>
|
|
|
|
<div class="col-sm-3">
|
|
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Complaints</strong></label>
|
|
<br>
|
|
|
|
|
|
<div>
|
|
|
|
<input type="text" class="form-control" id="complaints"
|
|
name="complaints" data-placeholder="Complaints" />
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<?php } ?>
|
|
<?php
|
|
$examination_remarks_config = getFieldFromTable('value', 'config', 'key_name', 'examination_tag_switch');
|
|
error_log("examination_remarks_config tag switch " . $examination_remarks_config . " compare " . strcmp(strtolower($examination_remarks_config), "false"));
|
|
if (!strcmp(strtolower($examination_remarks_config), "false")) {
|
|
?>
|
|
<div class="col-sm-3">
|
|
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Examination
|
|
Findings</strong></label>
|
|
<br>
|
|
|
|
|
|
<div>
|
|
<select class="form-control chosen-select"
|
|
name="examination_remarks[]" id="examination_remarks"
|
|
multiple>
|
|
<?php echo generateOption('examination_findings', 'examination_finding', 'id', '', '') ?>
|
|
</select>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<?php
|
|
} else { ?>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Examination
|
|
Findings</strong></label>
|
|
<br>
|
|
|
|
<div>
|
|
|
|
<input type="text" class="form-control" id="examination_remarks"
|
|
name="examination_remarks"
|
|
data-placeholder="Examination findings" />
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<?php } ?>
|
|
<?php
|
|
$diagnosis_config = getFieldFromTable('value', 'config', 'key_name', 'diagnosis_tag_switch');
|
|
error_log("diagnosis tag switch " . $complaint_config . " compare " . strcmp(strtolower($complaint_config), "false"));
|
|
if (!strcmp(strtolower($diagnosis_config), "false")) {
|
|
?>
|
|
<div class="col-sm-3">
|
|
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Diagnosis</strong></label>
|
|
<br>
|
|
|
|
|
|
<div>
|
|
<select class="form-control chosen-select" name="ailment_new[]"
|
|
id="ailment_new" multiple>
|
|
<?php echo generateOption('ailment', 'ailment_name', 'ailment_id', '', '') ?>
|
|
</select>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<?php
|
|
} else { ?>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="ailment"><strong
|
|
style="font-size: 11px">Diagnosis</strong></label><br>
|
|
|
|
<div>
|
|
|
|
|
|
<input name="ailment[]" type="hidden"
|
|
data-placeholder="Ailments"
|
|
value="<?php echo $row['ailment_ids'] ?>">
|
|
<input type="text" class="form-control" id="ailment_new"
|
|
name="ailment_new" data-placeholder="Ailments">
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<?php } ?>
|
|
</div>
|
|
|
|
<div class="space-6"></div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="space-6"></div>
|
|
|
|
<div class="row">
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="ailment_system"><strong
|
|
style="font-size: 11px">Activity</strong></label>
|
|
|
|
<select class="form-control" id="activity" name="activity">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<option value="R" <?php if (strcmp($row['activity'], 'R') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Routine</option>
|
|
<option value="NR" <?php if (strcmp($row['activity'], 'NR') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Non-Routine</option>
|
|
<option value="E" <?php if (strcmp($row['activity'], 'E') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Emergency</option>
|
|
</select>
|
|
</div>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="ailment_system"><strong
|
|
style="font-size: 11px">PPE</strong></label>
|
|
|
|
<select class="form-control" id="ppe" name="ppe">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<option value="U" <?php if (strcmp($row['ppe'], 'U') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Used</option>
|
|
<option value="NU" <?php if (strcmp($row['ppe'], 'NU') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Unused</option>
|
|
<option value="NA" <?php if (strcmp($row['ppe'], 'NA') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Not Applicable</option>
|
|
</select>
|
|
</div>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Injury Location</strong></label>
|
|
<input type="text" class="form-control" name="incident_location"
|
|
id="incident_location"
|
|
value="<?php echo $row['incident_location'] ?>"
|
|
placeholder="Location where injury happend" maxLength="200">
|
|
</div>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Remarks/Follow-up Investigation
|
|
Details</strong></label>
|
|
|
|
<textarea rows="3" cols="6" class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"
|
|
name="remarks_rece" id="remarks_rece"
|
|
placeholder="Remarks/Follow-up Invetigation Details"
|
|
maxlength="500"><?php echo $row['remarks_rece'] ?></textarea>
|
|
</div>
|
|
</div>
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<div class="row">
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="ailment_system"><strong
|
|
style="font-size: 11px">Injury Area
|
|
category</strong></label>
|
|
|
|
<select class="form-control" id="injury_area_cat"
|
|
name="injury_area_cat">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<option value="IN" <?php if (strcmp($row['injury_area_cat'], 'IN') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Work Related</option>
|
|
<option value="NIN" <?php if (strcmp($row['injury_area_cat'], 'NIN') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Non Work Related</option>
|
|
|
|
</select>
|
|
</div>
|
|
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="ailment_system"><strong
|
|
style="font-size: 11px">Injury area type</strong></label>
|
|
|
|
<select class="form-control" id="injury_area_type"
|
|
name="injury_area_type">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<option value="M" <?php if (strcmp($row['injury_area_type'], 'M') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Manufacturing</option>
|
|
<option value="NM" <?php if (strcmp($row['injury_area_type'], 'NM') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Non Manufacturing</option>
|
|
|
|
</select>
|
|
</div>
|
|
|
|
<div class="col-sm-3">
|
|
|
|
|
|
<label class="control-label" for="shift_type">
|
|
<strong style="font-size: 11px">Shift</strong></label>
|
|
|
|
<select class="form-control" id="shift_type" name="shift_type">
|
|
<option value="A" <?php if (strcmp($row['shift_type'], 'A') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
A</option>
|
|
<option value="B" <?php if (strcmp($row['shift_type'], 'B') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
B</option>
|
|
<option value="C" <?php if (strcmp($row['shift_type'], 'C') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
C</option>
|
|
<option value="G" <?php if (strcmp($row['shift_type'], 'G') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
G</option>
|
|
</select>
|
|
|
|
|
|
</div>
|
|
<div class="col-sm-3">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">INJURY DEFINE</strong></label>
|
|
<br>
|
|
|
|
|
|
|
|
<select class="form-control" id="injury_def" name="injury_def">
|
|
<option value="" disabled selected>Please select an option
|
|
</option>
|
|
<option value="init" <?php if (strcmp($row['injury_def'], 'init') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Initiated
|
|
</option>
|
|
<option value="not-init" <?php if (strcmp($row['injury_def'], 'not-init') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Not Initiated
|
|
</option>
|
|
|
|
</select>
|
|
</strong></label>
|
|
<br>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<div class="row">
|
|
<div class="col-sm-12 table-responsive">
|
|
<label class="control-label" for="form-field-8"><strong
|
|
style="font-size: 11px">Injury</strong></label>
|
|
<table class="table table-bordered table-hover simple-table">
|
|
<thead>
|
|
<tr class="active">
|
|
|
|
<th><strong style="font-size: 11px">Type</strong></th>
|
|
<th><strong style="font-size: 11px">Part </strong></th>
|
|
<th><strong
|
|
style="font-size: 11px">Classification</strong>
|
|
</th>
|
|
<th><strong style="font-size: 11px">Mechanism</strong>
|
|
</th>
|
|
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
|
|
<tr>
|
|
<td class="col-sm-3"><select multiple=""
|
|
class="chosen-select form-control"
|
|
name="injury_type_new[]" id="injury_type_new"
|
|
placeholder="Injury Type"><?php echo generateOptionForMultiple('injury_type', 'injury_type_name', 'injury_type_id', $row['injury_types_new'], ''); ?></select>
|
|
</td>
|
|
<td class="col-sm-3">
|
|
<select multiple=""
|
|
class="chosen-select form-control"
|
|
name="injury_part" id="injury_part"
|
|
placeholder="Affected Body Parts..">
|
|
<?php echo generateOptionForMultiple('injury_part', 'inj_name', 'inj_id', $row['injury_parts_new'], ''); ?></select>
|
|
</td>
|
|
<td class="col-sm-3"><select multiple=""
|
|
class="chosen-select form-control"
|
|
name="injury_class_new[]" id="injury_class_new"
|
|
class="form-control"
|
|
placeholder="Injury Classification.."><?php echo generateOptionForMultiple('injury_class', 'inj_class_name', 'inj_class_id', $row['injury_classes_new'], ''); ?></select>
|
|
</td>
|
|
<td class="col-sm-3"><select multiple=""
|
|
class="chosen-select form-control"
|
|
name="injury_mech_new[]" id="injury_mech_new"
|
|
class="form-control"
|
|
placeholder="Injury Mechanism.."><?php echo generateOptionForMultiple('injury_mechanism', 'injury_mech_name', 'injury_mech_id', $row['injury_mech'], ''); ?></select>
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="remarks"><strong
|
|
style="font-size: 11px">Procedures Done(if
|
|
Any)</strong></label>
|
|
<textarea id="pro_remarks" name="pro_remarks"
|
|
placeholder="Procedure.." rows="3" cols="6"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['injury_procedure'] ?></textarea>
|
|
|
|
</div>
|
|
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 10px">Is the Patient taking any
|
|
Medications - Give Details:</strong></label>
|
|
|
|
<textarea placeholder="Enter medication details" rows="3" cols="8"
|
|
id="any_medication" name="any_medication"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['any_medication'] ?></textarea>
|
|
</div>
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">History of Drug
|
|
Allergies:</strong></label>
|
|
|
|
|
|
<textarea placeholder="Enter drug allergies" rows="3" cols="8"
|
|
id="drug_allergy" name="drug_allergy"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['drug_allergy'] ?></textarea>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
<br>
|
|
<div class="row">
|
|
<?php if ($rolecode != 'DIS') { ?>
|
|
<div class="col-sm-6">
|
|
<label class="control-label " for="medicine_disbursement"><strong
|
|
style="font-size: 11px">Medicine Disbursement</strong>
|
|
</label>
|
|
<input <?php if ($row['medi_disbursement'] == 'Y') {
|
|
echo 'checked="checked"';
|
|
} ?> type="radio"
|
|
name="medicine_disbursement" id="medicine_disbursement_yes"
|
|
value="Y" onchange="setFieldDisableOrEnable(this.value)"> Yes
|
|
<input <?php if ($row['medi_disbursement'] == 'N') {
|
|
echo 'checked="checked"';
|
|
} ?> type="radio"
|
|
name="medicine_disbursement" id="medicine_disbursement_no"
|
|
value="N" onchange="setFieldDisableOrEnable(this.value)"> No
|
|
</div>
|
|
<?php } else { ?>
|
|
<input type="hidden" name="medicine_disbursement"
|
|
id="medicine_disbursement" value="Y" />
|
|
<?php } ?>
|
|
<?php
|
|
// if not doctor already consulted
|
|
if ($row['doctor_attended_flag'] != 'Y' && $rolecode != 'DOC') {
|
|
?>
|
|
<div class="col-sm-6">
|
|
<label class=" control-label " for="doctor_discussed"><strong
|
|
style="font-size: 11px">Doctor Discussed?</strong> </label>
|
|
<input <?php if ($row['doctor_discussed'] == 'Y') {
|
|
echo 'checked="checked"';
|
|
} ?> type="radio"
|
|
name="doctor_discussed" id="doctor_discussed_yes" value="Y"
|
|
onchange="setDoctorDiscussed(this.value)"> Yes
|
|
<input <?php if ($row['doctor_discussed'] != 'Y') {
|
|
echo 'checked="checked"';
|
|
} ?> type="radio" name="doctor_discussed"
|
|
id="doctor_discussed_no" value="N"
|
|
onchange="setDoctorDiscussed(this.value)"> No
|
|
</div>
|
|
<?php } ?>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
|
|
|
|
<div class="row">
|
|
<div class="col-sm-12 table-responsive">
|
|
<table
|
|
id="treatmentTable<?php echo $row_history['appointment_id'] ?>"
|
|
class="table table-striped table-bordered table-responsive">
|
|
<thead>
|
|
<tr class="success">
|
|
<th style="font-size: 9px; text-align: center;">Medicine
|
|
</th>
|
|
<th style="font-size: 9px; text-align: center;">
|
|
Frequency</th>
|
|
<th style="font-size: 9px; text-align: center;">Timing
|
|
</th>
|
|
<th style="font-size: 9px; text-align: center;">Admin.
|
|
Route</th>
|
|
<th style="font-size: 9px; text-align: center;">Duration
|
|
</th>
|
|
<th style="font-size: 9px; text-align: center;">Dose Qty
|
|
</th>
|
|
<th style="font-size: 9px; text-align: center;">Total
|
|
Qty</th>
|
|
<th style="font-size: 9px; text-align: center;">
|
|
Available
|
|
Qty</th>
|
|
<th style="font-size: 9px; text-align: center;">Qty
|
|
Issued</th>
|
|
<th style="font-size: 9px; text-align: center;"></th>
|
|
</tr>
|
|
</thead>
|
|
</table>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<div class="col-sm-12 table-responsive">
|
|
<label class="control-label" for="referral"><strong
|
|
style="font-size: 11px">Additional
|
|
Recommendations</strong></label>
|
|
<textarea name="external_treatments" rows="4" cols="8"
|
|
id="external_treatments"
|
|
placeholder="Additional Treatment Recommendations"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['external_treatments'] ?></textarea>
|
|
</div>
|
|
</div>
|
|
<br>
|
|
<div class="row">
|
|
|
|
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="followup"><strong
|
|
style="font-size: 11px">Name of Safety
|
|
Officer</strong></label>
|
|
<input class="form-control" type="text" name="safety_officer"
|
|
id="safety_officer"
|
|
value="<?php echo $row['safety_officer'] ?>">
|
|
</div>
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="followup"><strong
|
|
style="font-size: 11px">Reporting Time to Safety
|
|
Officer</strong></label>
|
|
<div class="input-group">
|
|
<input id="report_time" type="text" class="form-control"
|
|
style="height: 30px" name="report_time" /> <span
|
|
class="input-group-addon"> <i style="height: 5px"
|
|
class="fa fa-clock-o bigger-110"></i>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="referral"><strong
|
|
style="font-size: 11px">Injury Remarks by Safety
|
|
Officer</strong></label>
|
|
<textarea name="injury_remarks" rows="4" cols="8"
|
|
id="injury_remarks" placeholder="Injury Remarks"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['injury_remarks'] ?></textarea>
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<?php if ($row['recommended_tests_new'] != "" && $row['recommended_tests_new'] != null) { ?>
|
|
<div class="row">
|
|
<div class="col-sm-12 table-responsive">
|
|
</br>
|
|
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Doctor Recommended Test Result
|
|
:</strong></label>
|
|
</div>
|
|
<div class="col-sm-12 table-responsive">
|
|
<input type="hidden" name="recommended_tests_new"
|
|
value="<?php echo $row['recommended_tests_new'] ?>">
|
|
<div class="row">
|
|
<?php $test_array = explode(",", $row['recommended_tests_new']);
|
|
for ($i = 0; $i < count($test_array); $i++) { ?>
|
|
<?php if ($i % 2 == 0) { ?>
|
|
</div>
|
|
<div class="row">
|
|
<?php } ?>
|
|
<div class="col-sm-6 table-responsive">
|
|
<?php echo $i + 1; ?> <?php echo $test_array[$i] ?>
|
|
<?php $test_map_array = getKeyValueMapWithWhere('doctor_recommended_test', 'test_name', 'test_result', 'appointment_id', $_REQUEST['appointmentId']); ?>
|
|
<textarea name="test_<?php echo $i ?>" rows="4" cols="4"
|
|
id="test_<?php echo $i ?>"
|
|
placeholder="<?php echo $test_array[$i] ?> Test Result"
|
|
class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $test_map_array[$test_array[$i]] ?></textarea>
|
|
</div>
|
|
|
|
<?php }
|
|
|
|
?>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
<?php } ?>
|
|
</div>
|
|
<!-- /.col-xs-12 -->
|
|
</div>
|
|
<!--row end-->
|
|
|
|
</div>
|
|
<!--end of widget-main-->
|
|
</div>
|
|
<!--end of widget-body-->
|
|
</div>
|
|
<!--end of widget-box-->
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="col-xs-3 table-responsive">
|
|
<div class="widget-box">
|
|
|
|
<div class="widget-body">
|
|
<div class="widget-main">
|
|
<div class="row">
|
|
<div class="col-sm-6">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Emergency?</strong></label> <select
|
|
class="form-control" style="height: 30px;" id="isEmergency"
|
|
name="isEmergency">
|
|
<option value="0" <?php if ($row['IsEmergency'] == 0) { ?> selected
|
|
<?php } ?>>No</option>
|
|
<option value="1" <?php if ($row['IsEmergency'] == 1) { ?> selected
|
|
<?php } ?>>Yes</option>
|
|
</select>
|
|
</div>
|
|
<div class="col-sm-6">
|
|
<label class="control-label" for="form-field-select-1"><strong style="font-size: 11px">Chargeable?</strong></label> <select class="form-control" style="height: 30px;" id="isChargeable" name="isChargeable">
|
|
<option value="1" <?php if ($row['IsChargeable'] == 1) { ?> selected <?php } ?>>Yes</option>
|
|
<option value="0" <?php if ($row['IsChargeable'] == 0) { ?> selected <?php } ?>>No</option>
|
|
</select>
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
|
|
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Weight</strong></label>
|
|
<input type="number" style="height: 30px;" min="0" max="1000"
|
|
placeholder="WEIGHT(kg)" id="weight" name="weight"
|
|
onchange="calculateBMI()" value="<?php echo $row['weight'] ?>">
|
|
</div>
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Height</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;"
|
|
id="height" name="height" placeholder="HEIGHT (cms)" min="0"
|
|
max="1000" onchange="calculateBMI()"
|
|
value="<?php echo $row['height'] ?>">
|
|
</div>
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">BMI</strong></label>
|
|
<input type="number" style="height: 30px;width: 85px" id="bmi"
|
|
name="bmi" placeholder="BMI(KG/m2)" min="0" max="200"
|
|
value="<?php echo $row['bmi'] ?>">
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">SBP</strong></label>
|
|
<input type="number" style="height: 30px;" min="0" max="1000"
|
|
placeholder="SBP" id="sbp" name="sbp"
|
|
value="<?php echo $row['bp_sbp'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">DBP</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;" id="DBP"
|
|
name="dbp" placeholder="DBP" min="0" max="1000"
|
|
value="<?php echo $row['bp_dbp'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Temperature</strong></label>
|
|
<input type="number" style="height: 30px;width: 85px" min="0" max="1000"
|
|
placeholder="Temp.(F)" id="temperature" name="temperature"
|
|
value="<?php echo $row['temperature'] ?>" maxlength="10">
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Respiratory Rate</strong></label>
|
|
<input type="number" style="height: 30px;" min="0" max="1000"
|
|
placeholder="Respiratory rate" id="resp_rate" name="resp_rate"
|
|
value="<?php echo $row['respiratory_rate'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Heart Rate</strong></label>
|
|
<input type="number" style="height: 30px;" id="heart_rate"
|
|
name="heart_rate" placeholder="Heart Rate(BPM)" min="0" max="200"
|
|
value="<?php echo $row['heart_rate'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">Urine output</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;width: 85px"
|
|
id="urine_output" name="urine_output" placeholder="Urine Output"
|
|
value="<?php echo $row['urine_output'] ?>">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">FBS</strong></label>
|
|
<input type="number" style="height: 30px;" min="0" max="1000"
|
|
placeholder="FBS" id="fbs" name="fbs"
|
|
value="<?php echo $row['blood_sugar_fbs'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">RBS</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;" id="rbs"
|
|
name="rbs" placeholder="RBS"
|
|
value="<?php echo $row['blood_sugar_rbs'] ?>">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">PPBS</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;width: 85px"
|
|
id="ppbs" name="ppbs" placeholder="PPBS"
|
|
value="<?php echo $row['blood_sugar_ppbs'] ?>">
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">SPO2</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;"
|
|
id="spo2_percent" name="spoc2_percent" placeholder="SPO2"
|
|
value="<?php echo $row['spo2_percent'] ?>" maxlength="10">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">AVPU</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;" id="avpu"
|
|
name="avpu" placeholder="AVPU" value="<?php echo $row['avpu'] ?>"
|
|
maxlength="10">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 11px">TRAMA</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;width: 85px"
|
|
id="trama" name="trama" placeholder="Trama"
|
|
value="<?php echo $row['trama'] ?>" maxlength="10">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="col-xs-4" style="margin-left: -12px">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 9px">oxygen supplementation</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;"
|
|
id="oxygen_supply" name="oxygen_supply"
|
|
placeholder="Oxygen supplementation"
|
|
value="<?php echo $row['oxygen_supply'] ?>" maxlength="10">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 9px">glasgow coma scale</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 30px;"
|
|
id="glasgow_coma_scale" name="glasgow_coma_scale"
|
|
placeholder="Glasgow coma scale"
|
|
value="<?php echo $row['glasgow_coma_scale'] ?>" maxlength="10">
|
|
</div>
|
|
|
|
<div class="col-xs-4">
|
|
<br>
|
|
<label class="control-label" for="form-field-select-1"><strong
|
|
style="font-size: 9px">Mobility</strong></label>
|
|
<input type="number" min="0" max="1000" style="height: 31px;width: 85px"
|
|
id="mobility" name="mobility" placeholder="Mobility"
|
|
value="<?php echo $row['mobility'] ?>" maxlength="10">
|
|
</div>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<!-- <?php
|
|
|
|
// if ($rolecode == 'DOC' || ($row['doctor_attended_flag'] == 'Y')) {
|
|
?> -->
|
|
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Health
|
|
Advices</strong></label>
|
|
|
|
</div>
|
|
<div class="col-sm-12">
|
|
|
|
<input type="text" name="health_advice_name_new" id="health_advice_name_new"
|
|
class="form-control" placeholder="Select or Add Health Advices.." />
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Recommended Tests</strong></label>
|
|
</div>
|
|
<div class="col-sm-12">
|
|
<input type="text" name="recommended_test_new" id="recommended_test_new"
|
|
value="" class="form-control" placeholder="Select or Add Lab Tests" />
|
|
</div>
|
|
</div>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Additional Precautions</strong></label>
|
|
<textarea name="remarks" placeholder="Additional Precautions.." rows="3"
|
|
cols="8" id="remarks" class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['remarks'] ?></textarea>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<?php //}
|
|
?>
|
|
<div class="space-6"></div>
|
|
<div class="row">
|
|
<div class="col-sm-12 table-responsive">
|
|
<label class="control-label" for="followup_remarks"><strong
|
|
style="font-size: 11px">Follow-Up Remarks(If Any)</strong></label>
|
|
<textarea name="followup_remarks" rows="4" cols="8" id="followup_remarks"
|
|
placeholder="Followup Remarks" class="autosize-transition form-control"
|
|
style="overflow: hidden; overflow-wrap: break-word;"><?php echo $row['followup_remarks'] ?></textarea>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-xs-9 table-responsive">
|
|
<div class="widget-box box box-success">
|
|
|
|
<div class="widget-body">
|
|
<div class="widget-main">
|
|
|
|
<div class="row">
|
|
<div class="col-xs-12">
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="referral"><strong
|
|
style="font-size: 11px">Referral</strong></label>
|
|
|
|
<div>
|
|
|
|
<input type="text" class="form-control" id="referral"
|
|
name="referral" data-placeholder="Ailments">
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Patient Admitted in Hospital: Yes/ No
|
|
(If yes give details of hospital and time at which reached the
|
|
hospital)</strong></label>
|
|
|
|
|
|
<div class="input-group" id="discharge">
|
|
<input id="discharge_time" type="text" class="form-control"
|
|
style="height: 30px" name="discharge_time" /> <span
|
|
class="input-group-addon"> <i style="height: 5px"
|
|
class="fa fa-clock-o bigger-110"></i>
|
|
</span>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="col-sm-4">
|
|
<label class="control-label" for="additional_advices"><strong
|
|
style="font-size: 11px">Ambulance Used: Yes/No</strong></label>
|
|
|
|
|
|
<select class="form-control" id="ambulance_used" name="ambulance_used">
|
|
<option value="" disabled selected>Please select an option</option>
|
|
<option value="Y" <?php if (strcmp($row['ambulance_used'], 'Y') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
Yes</option>
|
|
<option value="N" <?php if (strcmp($row['ambulance_used'], 'N') == 0) {
|
|
echo "selected";
|
|
} ?>>
|
|
No</option>
|
|
</select>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
</form>
|
|
|
|
|
|
<link rel="stylesheet" href="assets/font-awesome/4.5.0/css/font-awesome.min.css" />
|
|
|
|
<!-- page specific plugin styles -->
|
|
<link rel="stylesheet" href="assets/css/jquery-ui.custom.min.css" />
|
|
<link rel="stylesheet" href="assets/css/chosen.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-datepicker3.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-timepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/daterangepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-datetimepicker.min.css" />
|
|
<link rel="stylesheet" href="assets/css/bootstrap-colorpicker.min.css" />
|
|
<link rel="stylesheet" href="adminlte/bower_components/bootstrap/less/type.less" />
|
|
<script src="assets/js/jquery-ui.custom.min.js"></script>
|
|
<script src="assets/js/jquery.ui.touch-punch.min.js"></script>
|
|
<script src="assets/js/chosen.jquery.min.js"></script>
|
|
<script src="assets/js/spinbox.min.js"></script>
|
|
<script src="assets/js/bootstrap-datepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-timepicker.min.js"></script>
|
|
<script src="assets/js/jquery.dataTables.min.js"></script>
|
|
<script src="assets/js/jquery.dataTables.bootstrap.min.js"></script>
|
|
<script src="assets/js/dataTables.buttons.min.js"></script>
|
|
<script src="assets/js/buttons.flash.min.js"></script>
|
|
<script src="assets/js/buttons.html5.min.js"></script>
|
|
<script src="assets/js/buttons.print.min.js"></script>
|
|
<script src="assets/js/buttons.colVis.min.js"></script>
|
|
<script src="assets/js/dataTables.select.min.js"></script>
|
|
|
|
|
|
<script src="assets/js/moment.min.js"></script>
|
|
<script src="assets/js/daterangepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-datetimepicker.min.js"></script>
|
|
<script src="assets/js/bootstrap-colorpicker.min.js"></script>
|
|
<script src="assets/js/jquery.knob.min.js"></script>
|
|
<script src="assets/js/autosize.min.js"></script>
|
|
<script src="assets/js/jquery.inputlimiter.min.js"></script>
|
|
<script src="assets/js/jquery.maskedinput.min.js"></script>
|
|
<script src="assets/js/bootstrap-tag.min.js"></script>
|
|
<script src="assets/js/ace-elements.min.js"></script>
|
|
|
|
<script type="text/javascript">
|
|
// to update diagnosis value if config is false
|
|
<?php if (!strcmp(strtolower($diagnosis_config), "false")) { ?>
|
|
var ailment_names = '<?= $row['ailments_new'] ?>';
|
|
dataarray = ailment_names.split(",");
|
|
$("#ailment_new").val(dataarray);
|
|
$('#ailment_new').trigger('chosen:updated');
|
|
<?php } ?>
|
|
|
|
|
|
// to update findings value if config is false
|
|
<?php if (!strcmp(strtolower($examination_remarks_config), "false")) { ?>
|
|
var examination_finding_names = '<?= $row['examination_remarks'] ?>';
|
|
dataarray = examination_finding_names.split(",");
|
|
$("#examination_remarks").val(dataarray);
|
|
$('#examination_remarks').trigger('chosen:updated');
|
|
<?php } ?>
|
|
|
|
// to update complaints value if config is false
|
|
<?php if (!strcmp(strtolower($complaint_config), "false")) { ?>
|
|
var complaint_names = '<?= $row['complaints'] ?>';
|
|
dataarray = complaint_names.split(",");
|
|
$("#complaints").val(dataarray);
|
|
$('#complaints').trigger('chosen:updated');
|
|
<?php } ?>
|
|
|
|
|
|
$('#injury_type_new').trigger("chosen:updated");
|
|
$('#injury_part_new').trigger("chosen:updated");
|
|
$('#injury_class_new').trigger("chosen:updated");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!ace.vars['old_ie']) $('#appointment_date').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
<?php if ($row['appointment_date'] != '') { ?>
|
|
defaultDate: new Date("<?php echo $row['appointment_date'] ?>") <?php } else { ?>
|
|
defaultDate: new Date() <?php } ?>,
|
|
maxDate: new Date(),
|
|
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();
|
|
});
|
|
|
|
|
|
|
|
if (!ace.vars['old_ie']) $('#injury_time').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
<?php if ($row['injury_time'] != '') { ?> defaultDate: new Date(
|
|
"<?php echo $row['injury_time'] ?>") <?php } else { ?>
|
|
defaultDate: new Date() <?php } ?>,
|
|
maxDate: new Date(),
|
|
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();
|
|
});
|
|
|
|
$(document).ready(function() {
|
|
$(".glyphicon").css("top", "");
|
|
|
|
|
|
});
|
|
|
|
function open_treatments(appointment_id) {
|
|
$('#modal-add-consultation').modal("show");
|
|
|
|
}
|
|
|
|
function getBMI(height, weight) {
|
|
//var height=$("#"+heightField).val();
|
|
//var weight=$("#"+WeightField).val();
|
|
if (height != null && height != '' && weight != null && weight != '') {
|
|
height = parseFloat(height);
|
|
weight = parseFloat(weight);
|
|
if (height != 0.0)
|
|
var bmi = (weight / (height / 100 * height / 100));
|
|
return bmi.toFixed(1);
|
|
}
|
|
return "";
|
|
}
|
|
|
|
function calculateBMI() {
|
|
var height = $("#height").val();
|
|
var weight = $("#weight").val();
|
|
$("#bmi").val(getBMI(height, weight));
|
|
}
|
|
</script>
|
|
|
|
<script type="text/javascript">
|
|
function opd_form(id) {
|
|
$("#flex_opd_id").val(id);
|
|
$("#flex_form_opd_for").attr('method', 'POST');
|
|
$("#flex_form_opd_for").attr('action', 'opd_form.php');
|
|
$("#flex_form_opd_for").submit();
|
|
|
|
}
|
|
|
|
function convertToOPD() {
|
|
|
|
$.ajax({
|
|
url: 'update_appointment.php',
|
|
type: "POST",
|
|
data: $("#opd_form").serialize(),
|
|
success: function(data) {
|
|
BootstrapDialog.alert('Case converted to OPD successfully!');
|
|
location.href = "appointment_list.php";
|
|
return;
|
|
|
|
},
|
|
error: function(data) {
|
|
BootstrapDialog.alert('Error in conversion!');
|
|
return;
|
|
}
|
|
});
|
|
$('.close').click();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
jQuery(function($) {
|
|
|
|
|
|
$("#forwardButton").on("click", function() {
|
|
<?php if ($rolecode == 'DOC') { ?>
|
|
BootstrapDialog.show({
|
|
title: 'Forward',
|
|
|
|
message: '<select class="form-control" id="forward_status" style="margin-left:100px;width:60%">' +
|
|
'<option value="PHP">Forward To Dipensary</option>' +
|
|
'<option value="MRP">Forward To Medical Room</option>' +
|
|
'<option value="DET">Forward To Dispensary for detention</option>' +
|
|
'<option value="CLS">Save & Close</option>',
|
|
|
|
buttons: [{
|
|
label: 'OK',
|
|
action: function() {
|
|
$("#attendedStatus").val($("#forward_status").val());
|
|
validate_update('opd_form',
|
|
'<?php echo $row['appointment_id'] ?>')
|
|
$(".close").click();
|
|
}
|
|
}]
|
|
});
|
|
<?php } else if($rolecode == $__ROLE_DISPENSARY) { ?>
|
|
BootstrapDialog.show({
|
|
title: 'Forward',
|
|
|
|
message: '<select class="form-control" id="forward_status" style="margin-left:100px;width:60%">' +
|
|
'<option value="DRP">Forward To Doctor</option>' +
|
|
'<option value="CLS">Save & Close</option>',
|
|
|
|
buttons: [{
|
|
label: 'OK',
|
|
action: function() {
|
|
$("#attendedStatus").val($("#forward_status").val());
|
|
validate_update('opd_form',
|
|
'<?php echo $row['appointment_id'] ?>')
|
|
|
|
}
|
|
}]
|
|
});
|
|
<?php } ?>
|
|
|
|
});
|
|
|
|
$('#id-disable-check').on('click', function() {
|
|
var inp = $('#form-input-readonly').get(0);
|
|
if (inp.hasAttribute('disabled')) {
|
|
inp.setAttribute('readonly', 'true');
|
|
inp.removeAttribute('disabled');
|
|
inp.value = "This text field is readonly!";
|
|
} else {
|
|
inp.setAttribute('disabled', 'disabled');
|
|
inp.removeAttribute('readonly');
|
|
inp.value = "This text field is disabled!";
|
|
}
|
|
});
|
|
|
|
|
|
if (!ace.vars['touch']) {
|
|
$('.chosen-select').chosen({
|
|
allow_single_deselect: true
|
|
});
|
|
//resize the chosen on window resize
|
|
|
|
$(window)
|
|
.off('resize.chosen')
|
|
.on('resize.chosen', function() {
|
|
$('.chosen-select').each(function() {
|
|
var $this = $(this);
|
|
$this.next().css({
|
|
'width': $this.parent().width()
|
|
});
|
|
})
|
|
}).trigger('resize.chosen');
|
|
//resize chosen on sidebar collapse/expand
|
|
$(document).on('settings.ace.chosen', function(e, event_name, event_val) {
|
|
if (event_name != 'sidebar_collapsed') return;
|
|
$('.chosen-select').each(function() {
|
|
var $this = $(this);
|
|
$this.next().css({
|
|
'width': $this.parent().width()
|
|
});
|
|
})
|
|
});
|
|
|
|
|
|
$('#chosen-multiple-style .btn').on('click', function(e) {
|
|
var target = $(this).find('input[type=radio]');
|
|
var which = parseInt(target.val());
|
|
if (which == 2) $('#form-field-select-4').addClass('tag-input-style');
|
|
else $('#form-field-select-4').removeClass('tag-input-style');
|
|
});
|
|
}
|
|
|
|
|
|
$('[data-rel=tooltip]').tooltip({
|
|
container: 'body'
|
|
});
|
|
$('[data-rel=popover]').popover({
|
|
container: 'body'
|
|
});
|
|
|
|
autosize($('textarea[class*=autosize]'));
|
|
|
|
$('textarea.limited').inputlimiter({
|
|
remText: '%n character%s remaining...',
|
|
limitText: 'max allowed : %n.'
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
//datepicker plugin
|
|
//link
|
|
$('.date-picker').datepicker({
|
|
autoclose: true,
|
|
todayHighlight: true
|
|
})
|
|
//show datepicker when clicking on the icon
|
|
.next().on(ace.click_event, function() {
|
|
$(this).prev().focus();
|
|
});
|
|
|
|
//or change it into a date range picker
|
|
$('.input-daterange').datepicker({
|
|
autoclose: true
|
|
});
|
|
|
|
|
|
//to translate the daterange picker, please copy the "examples/daterange-fr.js" contents here before initialization
|
|
$('input[name=date-range-picker]').daterangepicker({
|
|
'applyClass': 'btn-sm btn-success',
|
|
'cancelClass': 'btn-sm btn-default',
|
|
locale: {
|
|
applyLabel: 'Apply',
|
|
cancelLabel: 'Cancel',
|
|
}
|
|
})
|
|
.prev().on(ace.click_event, function() {
|
|
$(this).next().focus();
|
|
});
|
|
|
|
|
|
$('#timepicker1').timepicker({
|
|
minuteStep: 1,
|
|
showSeconds: true,
|
|
showMeridian: false,
|
|
disableFocus: true,
|
|
icons: {
|
|
up: 'fa fa-chevron-up',
|
|
down: 'fa fa-chevron-down'
|
|
}
|
|
}).on('focus', function() {
|
|
$('#timepicker1').timepicker('showWidget');
|
|
}).next().on(ace.click_event, function() {
|
|
$(this).prev().focus();
|
|
});
|
|
|
|
|
|
|
|
|
|
if (!ace.vars['old_ie']) $('#appointment_date').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
defaultDate: new Date(),
|
|
maxDate: new Date(),
|
|
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();
|
|
});
|
|
if (!ace.vars['old_ie']) $('#injury_time').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
defaultDate: new Date(),
|
|
maxDate: new Date(),
|
|
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();
|
|
});
|
|
|
|
|
|
if (!ace.vars['old_ie']) $('#out_time').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
// defaultDate: new Date(),
|
|
<?php if (isset($row['clearance_time']) && $row['clearance_time'] != '0000-00-00 00:00:00') { ?>
|
|
defaultDate: new Date("<?php echo $row['clearance_time'] ?>"),
|
|
<?php } else { ?>
|
|
defaultDate: new Date(),
|
|
<?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();
|
|
});
|
|
|
|
if (!ace.vars['old_ie']) $('#discharge_time').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
<?php if (isset($row['discharge_time']) && $row['discharge_time'] != '0000-00-00 00:00:00') { ?>
|
|
defaultDate: new Date("<?php echo $row['discharge_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();
|
|
});
|
|
|
|
if (!ace.vars['old_ie']) $('#report_time').datetimepicker({
|
|
format: 'DD/MM/YYYY h:mm A', //use this option to display seconds
|
|
<?php if (isset($row['report_time']) && $row['report_time'] != '0000-00-00 00:00:00') { ?>
|
|
defaultDate: new Date("<?php echo $row['report_time'] ?>"),
|
|
<?php } ?>
|
|
maxDate: new Date(new Date().setDate(new Date().getDate() + 30)),
|
|
// endDate: '+30d',
|
|
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();
|
|
});
|
|
|
|
|
|
$(document).one('ajaxloadstart.page', function(e) {
|
|
autosize.destroy('textarea[class*=autosize]')
|
|
|
|
$('.limiterBox,.autosizejs').remove();
|
|
$('.daterangepicker.dropdown-menu,.colorpicker.dropdown-menu,.bootstrap-datetimepicker-widget.dropdown-menu')
|
|
.remove();
|
|
});
|
|
|
|
});
|
|
|
|
function exporttopdf() {
|
|
|
|
var appointment_id_pdf = $("#appointment_id").val();
|
|
//alert(appointment_id_pdf);
|
|
window.open('injury_form_pdf.php?appointment_id_pdf=' + appointment_id_pdf + '');
|
|
|
|
}
|
|
|
|
function add_consume() {
|
|
$('#consumables').modal("show");
|
|
|
|
}
|
|
|
|
function showDetail(value) {
|
|
if (value == 'Y') {
|
|
$("#is_admitted").hide();
|
|
$("#discharge").show();
|
|
} else {
|
|
$("#is_admitted").show();
|
|
$("#discharge").hide();
|
|
}
|
|
}
|
|
</script>
|
|
<?php include('opd_injury_common_code.php'); ?>
|
|
<?php include('consumables.php'); ?>
|