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.
Hi,
I'm trying to use display suite in a search view, but "display suite" plugin is not available in the display settings. Only " display suite fields" is available, however, when it is selected, it throws "Fatal error: Call to undefined method SearchApiViewsQuery::add_field() in /home/drupal7/public_html/sites/all/modules/views/plugins/views_plugin_row.inc on line 117 error." (attachment.jpg).
I'm a newbie so I don't understand much, but I thought I should report this here, since I'm only experiencing problems with display suite in the search index views.
Thanks,
Susana
Comment | File | Size | Author |
---|---|---|---|
attachment.jpg | 154.06 KB | srsbl |
Comments
Comment #1
drunken monkeyThanks for reporting!
However, the problem lies in the display code, which doesn't seem to work with query plugins other than the Views default. Maybe this can be fixed, but I don't know. Moving to the (hopefully) right project, please set the right version number!
Comment #2
Ravenight CreditAttribution: Ravenight commentedJust wanted to report I am having the same result with the latest dev version ( I changed the version to reflect this, I'm not sure if this is proper etiquette or not, so please forgive me if I should have created a new bug report but this is the exact same issue I am seeing ).
Display Suite 7.x-2.0-beta1+5-dev
I had to switch to Panel Fields in views and that worked but doesn't give me the same level of detail DS does so I too hope a solution can be found to this issue.
I also have the following related modules installed:
Search API - 7.x-1.2
Solr Search - 7.x-1.0-rc2
Comment #3
swentel CreditAttribution: swentel commentedDisplay Suite simply doesn't support search api or solr search at this point, only core and the individual apachesolr search module.
Comment #4
miiimooo@swentel: Could you explain the problem a bit? I haven't looked at the DS code. I wonder does it wrap around views and so it doesn't load the right includes as needed or is it a different problem? Maybe someone here can help if they know what the problem is, especially the ape-who-is-no-enemy-of-the-drink certainly knows his way around drupal.
Comment #5
fox_01 CreditAttribution: fox_01 commentedThere is also a problem with the indexing of display suite view modes.
Comment #6
muschpusch CreditAttribution: muschpusch commentedYou can render the entity using content -> rendered node. This makes it possible to render e.g. a DS themed teaser view
Comment #7
fox_01 CreditAttribution: fox_01 commentedIf you use the renderedversion from database not the search index then you need to query the db for every result. that should be prevented from the indexing of complete entity view modes.
Comment #8
Exploratus CreditAttribution: Exploratus commentedI have this problem. Cant get a entity view mode to display custom html.
Comment #9
aspilicious CreditAttribution: aspilicious commentedI'm not going to fix this for DS as it is not a real core feature. And we are focusing on that at the moment.
We solve this issue with a combination of "search api" and custom code. It's not really trivial and certainly not configurable through the UI.
But that's the best we have for D7.
In Drupal 8 search api will have support for view modes in search views.