I would love to see some rules conditions like:

  • Is referenced by entity (req. arg1: entity_type, opt. arg2: entity_bundle, opt. arg3: entity_id, provides referencing entity objects)
  • Is referencing entity (req. arg1: entity_type, opt. arg2: entity_bundle, opt. arg3: entity_id, provides referenced entity objects)

Comments

iMiksu’s picture

My use case is to create an page redirect when user goes to view node page which is referenced by other node. The goal is to redirect user into that referencing node page instead current one...

airb’s picture

i think you can do the same with entity reference too.
http://dev.nodeone.se/en/learn-page-manager-part-2-introduction-and-more

Chaulky’s picture

I think the use case in that video is the opposite of what iMiksu wants to do. In the video, it's redirecting from a node to a node it references. iMiksu wants to go from a node to a node that references it.

iMiksu’s picture

That is correct.

airb’s picture

you have to create a view to find the node, and set up your rule different.
maybe rules bonus pack is needed too.

views
create a view (w. context + relationship) to find the nid of the referencing node (possibly not only one) - you can use sorting to create hierarchy of referencing nodes.

rule
conditions:
check number of results returned by VBO

actions:
load a view -> get nid of first element
redirect to node

airb’s picture

Issue summary: View changes

Improved formatting.