I have two problems:
1) How to "Load a referenced Node" as in D6 (I do not see the option)
2) Why can't I auto-populate a node referenced field into the term reference field on the same content type upon saving?
FIRST Issue
I would simply like to use D7 Rules to auto-populate my term reference and user reference fields like I did in D6. My attached image shows my Rule in D6.
In D6, I used the "Load a referenced node" option...
Let's say I have two content types, A & B
In content type A, I have term XYZ saved
Upon saving Content Type B, I want to auto-populate the term field as XYZ. But I can't do this because I don't see an option to Load a referenced Node like there was in the D6 version. What criteria would I set to apply my node reference field in Content type B so that I can reference other field tokens from Content Type A?
SECOND Issue
If, on the other hand, I simply want to grab the Node Reference field in the same content type and auto-populate that into my term field (again, same content type), i can't even do that!
On Content Type B, I have two fields:
a node reference to Content Type A called 'field_node_ref'
a term reference called 'field_term_ref'
Upon saving Content Type B, I simply want to auto-populate the 'field_term_ref' field with 'field_node_ref' field.
RULE
Event: After Saving New Content Type
Action: Set a new data value
selected data = node:field-term-ref:name (NAME)
And then set my token value to: [node:field-node-ref]
But upon saving new content in Content Type B, the [node:field-term-ref] is not auto-populating from [node:field-node-ref]
If, instead I use:
selected data = node:field-term-ref (TERM)
I do not see the option to add node:field-node-ref.
Thank you, kindly!
| Comment | File | Size | Author |
|---|---|---|---|
| rules example drupal 6.jpg | 24.61 KB | calefilm |
Comments
Comment #2
calefilm commentededited title
Comment #3
calefilm commentedComment #4
calefilm commentedSolution to both problems:
1) fixed here: http://drupal.stackexchange.com/questions/219743/how-to-entity-reference..., with available Rules Export for anyone trying to do the same thing.
2) I realized that I CANNOT reference a node reference name into a term reference name. I needed to reference a term ID into a term ID field, which is what i accomplished in my solution.
EVENT After saving new content of Car Review
CONDITION
Entity has field
data selector: node:field-car-review-node-reference
value: field_car_model_tag
ACTION
Fetch Entity by ID
value: node
data selector: node:field-car-review-node-reference:nid
Set a data value:
selected data (that i want to change): node:field-car-review-node-reference:field-car-model-tag
Export