Problem/Motivation
At times it may be very useful to add relationships from the search index to entities – for example if you want to add a flag link.
It seems that the SearchApiViewsQuery class needs to be extended with some methods for this to work. I don't know if it makes sense to add these methods, and if it is even possible to do at a generic level. But here's a feature request anyway.
A related issue: #1818152: Exposing additional relationships for entity indexes
Proposed resolution
Find out if it is possible to add a relationship to entities, at a generic level.
Try to implement. Evaluate, iterate.
Remaining tasks
(everything)
User interface changes
When indexes are built from entities, relationships to those entities are available in Views.
API changes
?
Comments
Comment #1
donquixote commentedyes, this would be very useful.
My personal use case: I want to add an "is not empty" filter for a specific entity field.
Comment #2
stewart.adam commentedI'd love to see this as well and for the same reason. At the moment, my workaround has been to to index the field in question, then filter it in Views.
Comment #3
drunken monkeyNormally you should already have all the entity's fields available, as well as relationships to all related entities (node's author, referenced taxonomy terms, etc.). If the Flag field isn't available there, it probably means that Flag doesn't properly integrate with the Entity API (though I thought it did …).
Adding a relationship to the "normal" Views table (e.g.,
node) isn't possibly since the two use different backends and it's not possible to join across those. I guess it would be possible, in a very hacky way, but we wouldn't want to add that to this module. What we can do is try to provide the same functionality and features as the "normal" Views tables in our tables, too. In this case, I guess the Flag module would have to change something about its Entity API integration (or add one).Did I understand the request correctly? In that case, it would be a "Closed (won't fix)". Sorry!
Comment #4
legolasboThis issue has not seen activity in over 2,5 years. I am therefore closing this issue to clean up the issue queue. Feel free to re-open and update this issue if you feel this issue is still relevant and of importance.