Commit e22c994d by Jansa Jose

search doctors date3

parent 76824f9c
......@@ -1123,8 +1123,9 @@ class Webservice_model extends CI_Model {
if ($query->num_rows() > 0) {
if(isset($data['date']) && strlen($data['date'])){
$date = $data['date'];
//SELECT * FROM `tbl_doctor_leave` WHERE NOT(1532304000 > `tbl_doctor_leave`.`start_date` OR 1532304000 < `tbl_doctor_leave`.`end_date`)
//$where = '$date<tbl_doctor_leave.start_date OR $date>tbl_doctor_leave.end_date';
$this->db->where("($date<tbl_doctor_leave.start_date OR $date>tbl_doctor_leave.end_date)");
$this->db->where_not_in("($date<tbl_doctor_leave.start_date OR $date>tbl_doctor_leave.end_date)");
$leave_query = $this->db->get('tbl_doctor_leave')->result();
echo $this->db->last_query();
echo "<pre>";print_r($leave_query);exit();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment