ESH/delete_employee.php

27 lines
831 B
PHP
Raw Permalink Normal View History

2024-10-23 18:28:06 +05:30
<?php
include('includes/config/config.php');
include('includes/functions.php');
include('log_entry.php');
error_log ( "Start Printing Request Attributes" );
$requestStr="";
foreach ( $_REQUEST as $key => $value ) {
$requestStr.=$key . " : " . $value . "\n";
error_log ( $key . " : " . $value . "<br />\r\n" );
}
error_log ( "End Printing Request Attributes" );
save_log($requestStr,'Patient','DELETE','delete_employee.php');
$query="";
if(!empty($_REQUEST['flex_opd_id'])){
$query = " delete p,emp_fm from patient_master p left join emp_family_members emp_fm on p.id=emp_fm.emp_id where p.id = '".$_REQUEST['flex_opd_id']."'";
error_log("dwfcewf".$query);
if (!$result = @mysqli_query($conn,$query)) {
exit(mysqli_error($conn));
echo json_encode("FAILURE");
}else{
echo json_encode("SUCCESS");
}
}
?>