private function test_parse_csv() { $mentor_model = new Mentor_Model(); $file_path = "C:\\Users\\naveen\\Downloads\\sample-database.csv"; $fellows_data = $mentor_model->load_data_from_csv($file_path); $this->unit->run(empty($fellows_data), false, "Parse Fellows CSV"); }
public function index() { $model = new Fellow_Model(); $mentor_model = new Mentor_Model(); $mentors = $mentor_model->get_mentors_child(get_current_user_id()); $fellows = $model->get_fellows(get_current_user_id()); if (empty($fellows)) { $fellows = array(); } $data['fellows'] = $fellows; if (empty($mentors)) { $this->template->title("Avanti Fellows - Mentor Platform"); $this->template->build('mentor_fellows_view', $data); } else { $data['mentors'] = $mentors; $this->template->title("Avanti Fellows - Mentor Platform"); $this->template->build('team_view', $data); } }