I was trying to set up a rule whereby when content is created ( Entity: [node], Field: field_client_com_name => A simple text field) the rule uses the field content to create a new taxonomy item.
Event: After saving new content
Condition: Entity has field => field_client_com_name ( a text field)
Actions: Create Entity => Taxonomy Term
Value => [node:field-client-com-name] (the value of the field_client_com_name text field)
Vocabulary => Here is the problem ??
On the Vocabulary filed the Data Selector (required), the options given seem unrelate: node:source:author, node:source:source, node:source:body:
Wouldn't this filed show the name of Vocabularies available to pick from? Or am I using this wrong at all?
Comments
Comment #1
fagoYep, we need to add support for directly selecting specific entities. For now, you can workaround it by using the "Fetch entity" action to fetch the vocabulary before using the entity create action.
Comment #2
3rdLOF commentedThanks for that tip fago.
Comment #3
fagoimplemented that :)
Comment #5
ace11 commentedCan you be more spesific how the solution for this goes?
Comment #6
ace11 commentedSorry for opening this but need urgent help!
Comment #7
3rdLOF commentedI exported the rules I made. You need THREE rules to complete all the possible actions: Create, Update and Delete.
You will need to change the names of the fields, content types and the vocabulary number to match yours before importing these rules as they are set for my particular set up.
Here you go buddy:
This will create a taxonomy value from the node title
This one will UPDATE a taxonomy WHEN a node title is updated.
This one will DELETE a taxonomy value when a node is deleted:
Peace and good luck.
Comment #8
ace11 commentedOk, thanks! But is there any way to resolve vocabulary id without drush? How?
Comment #9
3rdLOF commentedDrush? There is no drush. Where do you get Drush from?
Comment #10
ace11 commentedI just tried to google about getting/finding out vocabulary id and there was instructions how to do it in drush.
But I just mean how to find out vocabulary id?
Comment #11
3rdLOF commentedJust look at your database....the "taxonomy_vocabulary" table...look at it and you will see a list of all your vocabularies. The ID is the "vid" field.
Comment #12
3rdLOF commentedOr install Schema and use it to look at the database from inside the admin
Comment #13
fagoPlease do not re-open fixed issues unless it really isn't fixed. Better create a separate support issue and e.g. link it from here.
Comment #14
ace11 commentedThanks kannary100! It really works :)
And yes, sorry for opening - wont do it again.
Comment #15
fago