diff --git a/api/application/controllers/PD_Controller.php b/api/application/controllers/PD_Controller.php index 5fe8355a..d36c325e 100644 --- a/api/application/controllers/PD_Controller.php +++ b/api/application/controllers/PD_Controller.php @@ -419,7 +419,7 @@ class PD_Controller extends REST_Controller { $result_data['pd_documnets'] = $this->PD_Model->getSignedPDDocsURL($pdid); //Get All PD Template and It's Question with Answers - //$result_data['pd_question_answer'] = $this->getPDQuestionAnswer($pdid); + $result_data['pd_question_answer'] = $this->PD_Model->getPDQuestionAnswers($pdid); //Get All PD Logs $result_data['pd_logs'] = $this->PD_Model->getPDLogs($pdid); @@ -439,12 +439,12 @@ class PD_Controller extends REST_Controller { $pd_docs_msg = 'Documents Not Found'; } - // if(!count($result_data['pd_question_answer'])) - // { - // $pd_question_answer_msg = 'PD Details Not Found'; - // } + if(!count($result_data['pd_question_answer'])) + { + $pd_question_answer_msg = 'PD Details Not Found'; + } - if(!count($result_data['pd_logs'])) + if(!count($result_data['pd_logs']['pd_master_logs']) && !count($result_data['pd_logs']['pd_applicants_logs'])) { $pd_logs_msg = 'PD Logs Not Found'; } diff --git a/api/application/models/PD_Model.php b/api/application/models/PD_Model.php index 43cd169b..1bb33b2e 100644 --- a/api/application/models/PD_Model.php +++ b/api/application/models/PD_Model.php @@ -181,4 +181,12 @@ class PD_Model extends SPARQ_Model { return $result_array; } + + /* + *Get Completed PD Questions and Answers. + */ + public function getPDQuestionAnswers($pdid) + { + + } } \ No newline at end of file