You are here

function workflow_ng_action_custom_php_upgrade in Rules 6

The following functions help converting the workflow-ng php condition/actions when upgrading from workflow-ng

Related topics

1 call to workflow_ng_action_custom_php_upgrade()
workflow_ng_condition_custom_php_upgrade in rules/modules/php.rules_forms.inc

File

rules/modules/php.rules_forms.inc, line 111
Rules configuration forms for the php module

Code

function workflow_ng_action_custom_php_upgrade(&$element) {
  $element['#name'] = 'rules_action_custom_php';
  $old_settings = $element['#settings'];
  $element['#settings'] = array(
    'code' => $old_settings['php'],
  );
  $element['#settings']['code_args'] = $old_settings['used_arguments'];
  $element['#settings']['vars'] = $old_settings['used_php_arguments'];
}