Thanks for the replies.
Mukesh Agarwal mukesh.agarwal17@gmail.com
I dont think entity reference or any other module does that. You'll have to create a module for that and it will be great if you can contribute that too. You might well need to create patches in entityreference module.
Looking further, the References module, which is a D7 version of Node References, does what I want, allowing a View of the nodes to be used as the values in the dropdown, plus it respects node access values, which is essential for me, and Entity Reference doesn't. It seems that References might be being deprecated in favour of the wider Entity References module, so if it is, I'll look to see if I can contribute patches to Entity Reference.
Vaibhav Jain:
I believe you should use form alter to change the content in the drop down provided by the entity api. make sure that the values for every option is same, as it would save the NID value in its tables. when you do node view as well, you can alter the values via nodeapi.
Steve Kessler skessler@denverdataman.com
The question if the values are dynamic or static. The other approach we have used to fetch and store values when the node is created.
Yes, this was the option I was trying to avoid...However, I guess a very custom module adding a list of relevant nodes using form alter and then loading the values during node view using nodeapi would probably be the most efficient way, so if I need anything more quirky/specific, I may go this route.
On Tue, Jan 17, 2012 at 3:54 AM, DTH david@hartster.org wrote:
In one of my content types, I want people to be able to select an existing node, so I can use some of the data from the existing node of content type "page".
I've installed Entity Reference. This works great but for the fact that I can only choose to show in a dropdown every page node, which in this case means a dropdown with nearly a thousand options, when really I want people to choose from a more limited section of options (e.g. where field1 = foo and field2 = bar etc). Especially as you can only see the Title of the node, which in some cases is repeated in irrelevant nodes.
I've looked at Entity Reference View Widget, which allows you to create a View, but the output isn't ideal (e.g. it's not a dropdown, but lists every filtered option with a checkbox, whereas I definitely want people to only choose one option).
Is there another module/better way/hook etc, which would allow me to filter further the Entities in the dropdown, more than just by Content Type?