diff --git a/api/application/controllers/PD_Controller.php b/api/application/controllers/PD_Controller.php index 1bab1867..79c76868 100644 --- a/api/application/controllers/PD_Controller.php +++ b/api/application/controllers/PD_Controller.php @@ -3488,10 +3488,10 @@ class PD_Controller extends REST_Controller { { $records = $this->post('records'); $pd_id = $records['pd_id']; - // $pd_form_id = $records['pd_form_id']; + $company_id = $records['company_id']; $final_array = array(); $fields = array('json'); - $where_condition_array = array('isactive' => 1,'fk_form_id'=>13,'fk_pd_id'=>$pd_id); + $where_condition_array = array('isactive' => 1,'fk_form_id'=>13,'fk_pd_id'=>$pd_id,'company_id' => $company_id); $rec = $this->PD_Model->selectCustomRecords($fields,$where_condition_array,PDFORMDETAILSJSON); //print_r($this->db->last_query()); //print_r($rec); @@ -3571,7 +3571,7 @@ class PD_Controller extends REST_Controller { { $data['dataStatus'] = false; $data['status'] = REST_Controller::HTTP_NO_CONTENT; - $data['msg'] = "Fill Business Form First!"; + $data['msg'] = "Fill Business Form First! / No Company Found at this ID $company_id!"; $this->response($data,REST_Controller::HTTP_OK); }