![]() If you typically only have a few nodes that may not be a real issue to worry about. Using the approach detailed above, the result of your adapted rule is that you will get 1 separate eMail for each node fetched via that first Rules Action (which created the list of nodes to be processed). However, in case you don't realize yet, you may have introduced a new challenge, as detailed below. With these changes you solve your limitation of 4 nodes maximum. However, the content of your eMail message body should now only (repeat: only!) refer to the "List item" being processed in the current iteration of the Rules loop (instead of those 4 items in your existing " mimemail" action).Īs you will probably understand, since you're now processing 1 single node in each iteration, and it doesn't matter how many nodes you have in your list of nodes, there is no more restriction to 4 nodes only.Īfter you completed the previous step, there is no more need for the existing (last) Rules action about " mimemail", so just delete that Rules Action. As you will notice while creating a similar Rules Action, you'll now be able to select/specify tokens that relate to. The actual Rules Action to add is similar to the (last) Rules Action you already have, with machine name " mimemail". ![]() That way the Rules Action you add, will be performed as part of the loop. Within that loop you added, use the link to the right of it (in the Rules UI), to "Add an action". List item: Single node with status sendmail (single_node_with_status_sendmail).When doing so, specify these options for it (note the looooong variable name for my 'List item', I bet you get its meaning just from its name. What you need to do to repair your Rules Actions, are these steps:ĪFTER your first Rules Action (which fetch those nodes, and which is fine), use the link "Add a loop" as the next (2nd) Rules Action. , entity-fetched:3, correspond to your 1st, 2nd, 3rd and 4th node in that list of fetched entities (nodes). The result of your first Rules Action is actually a list, which as per the " PROVIDE" that is shown in your exported rule, is stored in a variable named entity_fetched (BTW, try to use a more meaningful variable name for such variables, eg nodes_with_status_sendmail).Īs you seemed to have understood already, the entity-fetched:0. If you're not familiar with such loops, then I strongly recommend to have a look at the tutorial titled " Lists and loops". Your Rules Events and Conditions are pretty sure OK, but you're missing a crucial Rules Action: a Rules Loop. I would like to have the complete list with these flagged nodes. In the section Replacement patterns for Fetched entity I only have till available. ![]() The problem I'm facing here is that I have to put in the email body tokens like, , etc. The list with nodes with the field-status set to "sendmail" is indeed send out. Provides variables: Fetched entity (entity_fetched)" "Parameter: Entity type: Node, Property: Status, Value:, Limit result count: 100 I try to send a list of nodes with certain value in a specific field via the Rules module.Įvent: "After updating existing content of type M圜ontentType"Ĭonditions: "Parameter: Data to compare:, Data value: sendmail"
0 Comments
Leave a Reply. |