Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
When using the Content Type facet, the labels for Profile2 bundles are displayed as their machine name instead of the display label stored in the entity data.
Other Solr modules, like Apache Solr Attachments and ApacheSolr Term implement a hook to include their entity type in the list to map for bundle names. For example, see: #1415618: Taxonomy term facet bundles are displayed as machine name and http://cgit.drupalcode.org/apachesolr_attachments/tree/apachesolr_attach...
Proposed resolution
Use hook_facetapi_facet_info_alter() to register the profile2 entity type for Facet API's bundle name mapping.
Comment | File | Size | Author |
---|---|---|---|
#1 | profile2_apachesolr-2297617-1-fix_bundle_facet_labels.patch | 1.1 KB | arithmetric |
Comments
Comment #1
arithmetric CreditAttribution: arithmetric commentedAttached is a patch to implement hook_facetapi_facet_info_alter() to register the profile2 entity type for Facet API's bundle name mapping.
Comment #2
arithmetric CreditAttribution: arithmetric commentedComment #3
davidburnsWorks as expected!