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
I needed a way to get the collation query when solr spellcheck is active and collation is enabled.
Proposed resolution
I added code to the SearchApiSpellcheckSolr class that gets the collation if available and saves it into the collation public field. There are no workarounds.
Remaining tasks
Reviews needed, documentation needed.
User interface changes
None
API changes
Here is how I used this:
if (!empty($results['search_api_spellcheck'])) {
$solr_sp = $results['search_api_spellcheck'];
$collation = "";
if (!empty($solr_sp->collation))
$collation = $solr_sp->collation;
Comment | File | Size | Author |
---|---|---|---|
solr-collation.patch | 740 bytes | kudorgyozo | |
Comments
Comment #1
OanaIlea CreditAttribution: OanaIlea at bio.logis Genetic Information Management GmbH commentedThis issue was closed due to lack of activity over a long period of time. If the issue is still acute for you, feel free to reopen it and describe the current state.