Displaying a view for entities created by Entity Construction Kit (ECK) leads into an SQL exception as soon as Display Suite takes over rendering for the view:
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'eck_faq.nid' in 'field list'
The issue is caused by the hard coded values in the ds_views_3_support() methods for base tables and base fields.
I did not solve this common problem of hard coded values itself, but added some logic to deal with ECK quickly.
I attached a patch.
| Comment | File | Size | Author |
|---|---|---|---|
| ds_views_eck.patch | 1.62 KB | mkalkbrenner |
Comments
Comment #1
swentel commentedInteresting, does this effectively also render the entities as well then ?
Comment #2
mkalkbrennerYes, you can do anything with views and display suite with these entities after applying the patch.
Comment #3
swentel commentedHmm, ok, I pushed this patch already, thanks for that. I'm going to test some more though because by looking at my own code I can't believe it so far it renders entities, as there's no 'ds_views_row_render_ENTITY_TYPE' function, so wondering how that works now :)
Comment #4
mkalkbrennerI see. I used fields, not rendered entities.
Beside views, I noticed that even rendering eck entities referenced in a node via entity reference is not working using custom view modes created by display suite.
I'll have a look ...
Comment #5
swentel commentedClosing in favor of #1839254: Entity Construction Kit compatibility for ds_views where I'm going to fix this once and for all.
Comment #6
weseze commentedI think you ment this one swentel: #1864882: Fix base table and base id support in views (entities & fields) ;)
Comment #7
swentel commentedoh, right, I sometimes make such link mistakes, thanks for correcting :)