See: http://drupal.org/node/1732990#comment-6354916

Need a way to stop apachesolr 'default' facets overriding those defined here.

Comments

dbolser’s picture

Assigned: Unassigned » dbolser
Status: Active » Needs review

I've managed to implement a fix, but I don't really know what I'm doing or why it works:

@@ -83,7 +85,11 @@ function apachesolr_external_index_apachesolr_search_result_alter($doc, $extra,
  * @return array
  *   An associative array keyed by unique name of the facet.
  */
-function apachesolr_external_index_facet_callback($searcher_info) {
+
+//function apachesolr_external_index_facet_callback($searcher_info) {
+
+// MY FIX
+function apachesolr_external_index_facetapi_facet_info($searcher_info) {
   $facets = array();
 
   $facets['obj_type'] = array(

This shows the 'default' facets for any given search environment, but the 'external specific' facets for the external environment... These facets are not disappearing when I clear the cache!

dbolser’s picture

Assigned: dbolser » pwolanin
dbolser’s picture

Update... I'm not sure when it happens, but now all facets (including the externals) are now shown in all search environments. This isn't ideal, but it's better than having facets go missing.