methods['getStudentInfo_post']['limit'] = 500; // load the employee model $this->load->model('Studentview_model', 'studentview_model'); } /* *get student basic info * created by kms * */ public function getStudentInfo_post() { $requestedBy = $this->post('requestedBy'); $requestedFrom = $this->post('requestedFrom'); $studentListDetails = $this->studentview_model->getStudentInfo($requestedBy,$requestedFrom);// Check if the employee exist if ($studentListDetails) { $studentListDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit $this->response($studentListDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } else { // Set the response and exit $this->response([ 'message' => 'No users were found', 'status' => REST_Controller::HTTP_NOT_FOUND ], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } }