Advertisement
Guest User

rule

a guest
Aug 15th, 2017
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 0.87 KB | None | 0 0
  1. { "rules_test_2" : {
  2.     "LABEL" : "test 2",
  3.     "PLUGIN" : "reaction rule",
  4.     "OWNER" : "rules",
  5.     "REQUIRES" : [ "rules" ],
  6.     "ON" : { "user_insert" : [] },
  7.     "DO" : [
  8.       { "entity_query" : {
  9.           "USING" : {
  10.             "type" : "user",
  11.             "property" : "field_passager_id",
  12.             "value" : [ "account:field-passager-id" ],
  13.             "limit" : "100"
  14.           },
  15.           "PROVIDE" : { "entity_fetched" : { "entity_fetched" : "Fetched entity" } }
  16.         }
  17.       },
  18.       { "LOOP" : {
  19.           "USING" : { "list" : [ "entity-fetched" ] },
  20.           "ITEM" : { "list_item" : "Current list item" },
  21.           "DO" : [
  22.             { "data_set" : { "data" : [ "list-item:field-passeur-io" ], "value" : "0" } }
  23.           ]
  24.         }
  25.       },
  26.       { "data_set" : { "data" : [ "account:field-passeur-io" ], "value" : "1" } }
  27.     ]
  28.   }
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement