Hey

References
http://drupal.org/project/references

is being deprecated in favor of Entity Reference
http://drupal.org/project/entityreference

Please update the code so we can use Entity Reference

CommentFileSizeAuthor
#9 #1-1719206.png5.98 KBnithinkolekar
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

geerlingguy’s picture

Patches welcome :)

The main project I'm using this module on is using References, and we won't be migrating to Entity Reference in any near-term timeframe, so I don't think I'll be able to work on this or do much testing at this point, but you never know.

lpalgarvio’s picture

Title: Migrate to Entity Reference » Test with Entity Reference, add to documentation/readme/project page
Component: Code » Documentation

actually, seems it's working fine as is with both modules =)
i've put both in use in a production site.

just needs a litle further testing and a notice in the project page / readme / docs.

geerlingguy’s picture

Version: 7.x-2.0 » 7.x-2.x-dev
Status: Active » Needs work

I've added a note on the project page: http://drupal.org/project/views_tree

If you or someone else could write up a quick tutorial on how to use it with Entity References on the documentation page, that'd be awesome! (Even if it's a really rough step-by-step guide, doesn't need to be fancy).

Documentation page, for reference, is here: http://drupal.org/node/1493366

geerlingguy’s picture

Status: Needs work » Fixed

I added kingswoodute's excellent step-by-step instructions from #1911510-1: Support for the Relation Module. (See below).

geerlingguy’s picture

Whoops! I added directions for the Relation module, not Entity Reference. This issue is still open—see the TODO on the Views tree documentation page.

jfarry’s picture

Status: Fixed » Needs work

I struggled pretty badly with this and Entity Reference. I'm not sure if you (LPCA) and I were trying to achieve different things, but my references always seemed to be around the wrong way, ie, the child node (in the relationship) would only work as the parent field in the Tree view, with the parent node under it.

In the end my requirements dictated that I needed a third level of tree anyway, which sent me to the Views Field View module anyhow.

groovedork’s picture

Issue summary: View changes

I have the same experience. I'm not able to have more than 2 levels with entity reference, and when I do they are in the wrong order. This is not a criticism, as on the page it says that support is very basic at this point.

My situation:

Content type A
- Content type B, points to A through entity reference field X
- - Content type C, points to B through entity reference field Y

(I chose to use two reference fields so that users can only ever point one level up in the selection interface. But I'm starting to suspect that the most-used solution for this is to use only one entity reference field and then at each level of the hierarchy restrict what parents can be selected through views).

Making a complex hierarchy with entity reference has been a bit of a time waster unfortunately.

Related posts:
https://www.drupal.org/node/2486633
https://www.drupal.org/node/991760

digitgopher’s picture

Just noting here that using the documentation for References works when you have entity reference field to a parent item.

https://www.drupal.org/node/2122735#comment-10475422
https://www.drupal.org/node/1493366#comment-7766885

nithinkolekar’s picture

FileSize
5.98 KB

Out of the box module is not working with simple entity referenced nodes. No special configuration is needed to reproduce except documentation steps for ER.

following is the screenshot where "chief minister" should be rendered as parent but it isn't.
view-tree-1719206