27 lines
1007 B
PHP
27 lines
1007 B
PHP
<?php
|
|
include ('includes/config/config.php');
|
|
include ('includes/auth/auth.php');
|
|
include ('includes/functions.php');
|
|
error_reporting(E_ERROR | E_PARSE);
|
|
?>
|
|
|
|
<?php
|
|
$query = "select a.*,b.*,c.*,d.designation_name,a.emp_cadre,f.employer_contractor_name,g.ohc_type_name from patient_master a left join patient_category b on a.patient_cat_id=b.patient_cat_id left join department c on a.dept_id=c.dept_id left join designation d on d.designation_id=a.designation_id left join emp_cadre e on e.emp_cadre_id=a.emp_cadre left join employer_contractor f on f.id=a.employer_contractor_id left join ohc_type g on g.ohc_type_id=a.ohc_type_id where emp_code='".$_POST['emp_code']."' ";
|
|
if (!$result = @mysqli_query($conn,$query)) {
|
|
exit(mysqli_error($conn));
|
|
}
|
|
$data = array();
|
|
if(mysqli_num_rows($result) > 0) {
|
|
while ($row = mysqli_fetch_assoc($result)) {
|
|
//extract($row);
|
|
$data = $row;
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
echo json_encode($data);
|
|
?>
|