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.

CommentFileSizeAuthor
ds_views_eck.patch1.62 KBmkalkbrenner

Comments

swentel’s picture

Interesting, does this effectively also render the entities as well then ?

mkalkbrenner’s picture

Yes, you can do anything with views and display suite with these entities after applying the patch.

swentel’s picture

Hmm, 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 :)

mkalkbrenner’s picture

I 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 ...

swentel’s picture

Status: Needs review » Closed (duplicate)

Closing in favor of #1839254: Entity Construction Kit compatibility for ds_views where I'm going to fix this once and for all.

weseze’s picture

swentel’s picture

oh, right, I sometimes make such link mistakes, thanks for correcting :)