$csrr = null; // ConceptSearchResultsRenderer object $enable_search_results_export = false; // Whether to show "Export" link if ($full_search_query) { // Create the ConceptSearch object $cs = new ConceptSearch($full_search_query); if ($mcl_mode == MCL_MODE_OPENMRS_ONLY) { $cs->load_concept_list_names = false; } $cs->include_retired = (bool) $arr_param['retired']; $cs->setAllSources($coll_source); $cs->setSelectedSources($coll_source_query); // Apply concept class and datatype filters foreach ($coll_selected_class->getKeys() as $key) { $cs->addFilter($coll_selected_class->Get($key)); } foreach ($coll_selected_datatype->getKeys() as $key) { $cs->addFilter($coll_selected_datatype->Get($key)); } // Perform the search if ($cs->Count()) { $csr = $csf->search($cs); } // Setup the renderer if ($csr && $csr->getVisibleCount()) { $csrr = new ConceptSearchResultsRenderer($csr); // TODO: Add in other url parameters too $csrr->arr_url_pararm['source'] = $arr_param['source']; $csrr->arr_url_pararm['retired'] = (int) $cs->include_retired; $csrr->highlight_list = false;