Skip to main content
replaced http://drupal.stackexchange.com/ with https://drupal.stackexchange.com/
Source Link

Here are the steps to get this to work (whatever your existing Rule looks like ...):

  1. Assume your current rule has some actions (= SomeRulesActions).

  2. Create a new Rules Component like so:

  • Use parameters related to the user (= say ParmUser) and payment (= say ParmPayment).
  • Add the Rules Conditions related to your custom field, which you should have available via the ParmUser.
  • Add Rules conditions identical to SomeRulesActions, using ParmUser and/or ParmPayment.
  • QA-test your Rules Component using the "Execute" link in front of it (in the Rues UI).
  1. Update your existing rule like so:
  • Delete all Rules Actions corresponding to SomeRulesActions (their equivalents are now included in the Rules Component you created in the previous step.
  • Add a Rules Action to execute the Rules Component you created in the previous step.

Easy, no?

An alternative solution where you don't need an extra Rules Component, is to rework your Rules logic by using the Conditional Rules module. If you wonder how to do that, use this linkthis link.

Ps: I'm assuming this is about D7.

Here are the steps to get this to work (whatever your existing Rule looks like ...):

  1. Assume your current rule has some actions (= SomeRulesActions).

  2. Create a new Rules Component like so:

  • Use parameters related to the user (= say ParmUser) and payment (= say ParmPayment).
  • Add the Rules Conditions related to your custom field, which you should have available via the ParmUser.
  • Add Rules conditions identical to SomeRulesActions, using ParmUser and/or ParmPayment.
  • QA-test your Rules Component using the "Execute" link in front of it (in the Rues UI).
  1. Update your existing rule like so:
  • Delete all Rules Actions corresponding to SomeRulesActions (their equivalents are now included in the Rules Component you created in the previous step.
  • Add a Rules Action to execute the Rules Component you created in the previous step.

Easy, no?

An alternative solution where you don't need an extra Rules Component, is to rework your Rules logic by using the Conditional Rules module. If you wonder how to do that, use this link.

Ps: I'm assuming this is about D7.

Here are the steps to get this to work (whatever your existing Rule looks like ...):

  1. Assume your current rule has some actions (= SomeRulesActions).

  2. Create a new Rules Component like so:

  • Use parameters related to the user (= say ParmUser) and payment (= say ParmPayment).
  • Add the Rules Conditions related to your custom field, which you should have available via the ParmUser.
  • Add Rules conditions identical to SomeRulesActions, using ParmUser and/or ParmPayment.
  • QA-test your Rules Component using the "Execute" link in front of it (in the Rues UI).
  1. Update your existing rule like so:
  • Delete all Rules Actions corresponding to SomeRulesActions (their equivalents are now included in the Rules Component you created in the previous step.
  • Add a Rules Action to execute the Rules Component you created in the previous step.

Easy, no?

An alternative solution where you don't need an extra Rules Component, is to rework your Rules logic by using the Conditional Rules module. If you wonder how to do that, use this link.

Ps: I'm assuming this is about D7.

Source Link
Pierre.Vriens
  • 36k
  • 40
  • 50
  • 182

Here are the steps to get this to work (whatever your existing Rule looks like ...):

  1. Assume your current rule has some actions (= SomeRulesActions).

  2. Create a new Rules Component like so:

  • Use parameters related to the user (= say ParmUser) and payment (= say ParmPayment).
  • Add the Rules Conditions related to your custom field, which you should have available via the ParmUser.
  • Add Rules conditions identical to SomeRulesActions, using ParmUser and/or ParmPayment.
  • QA-test your Rules Component using the "Execute" link in front of it (in the Rues UI).
  1. Update your existing rule like so:
  • Delete all Rules Actions corresponding to SomeRulesActions (their equivalents are now included in the Rules Component you created in the previous step.
  • Add a Rules Action to execute the Rules Component you created in the previous step.

Easy, no?

An alternative solution where you don't need an extra Rules Component, is to rework your Rules logic by using the Conditional Rules module. If you wonder how to do that, use this link.

Ps: I'm assuming this is about D7.