I have just installed and activated the module Apachesolr Term which has now populated my index with selected vocabulary terms.

The facets are appearing and functioning properly, but they are displayed in the respective blocks using their machine names rather than the full names (see screenshot). I'm not sure whether this is Facet API or Apachesolr Term at play, however when I checked the schema of my Solr index, the bundles were indeed titled with their full names, so I'm assuming that the Apachesolr Term has done its job and saved them with the full titles.

Is there anything I'm missing here in terms of settings?

Comments

cpliakas’s picture

Project: Facet API » Apachesolr Term
Version: 7.x-1.0-rc1 » 7.x-1.x-dev
Component: Usability » Code

Hi samw.

Thanks for posting. If the Apache Solr Term module is changing how the terms are getting indexed, then I believe it is that module's responsibility to also provide a mapping callback that translates the machine names to the display names. I am not familiar with the Apachesolr Term module, so I am bumping it over there to get Nick's perspective. Will be happy to bump it back here once we get some more information. Might also be a case where Facet API's internal callback could be more flexible.

Thanks,
Chris

nick_vh’s picture

I'd be happy to help you here but this module does not do any mapping to obtain facets? The content type facet comes from the regular apache solr module and it seems there is some problem there.

Have you been able to fix this yet?

nick_vh’s picture

Status: Active » Postponed (maintainer needs more info)
jerdavis’s picture

Status: Postponed (maintainer needs more info) » Active

This is still an issue. With this module enabled for a vocabulary and the Content Type facet enabled, the Vocabulary shows up in the facet block as the machine name rather than the display name. For our vocabulary Data Variable, the facet is displayed "data_variable".

I can see if I can trace this a bit further, but it'd be good to have some more information on where the maintainers think this traces back to.

jerdavis’s picture

Status: Active » Needs review
StatusFileSize
new924 bytes

The attached patch corrects this.

cpliakas’s picture

I would also refer to #1878528: Content Type facet incorrectly handles bundles on entities other than node. Marking the patch as needs work because it assumes that nodes and taxonomy terms are the only entities indexed by Apache Solr. My suggestion would be to either append "taxonomy_term" to the map options array or have the Apache Solr Search Integration module build the map options based on which entities it knows that it indexes.

Thanks for the contribution and for taking a crack at this issue,
Chris