Unverified Commit 88143a7b authored by JonGold's avatar JonGold

Support deleting action conditions

parent 01a4b9eb
......@@ -7,6 +7,7 @@ Version 1.8
* Fixed issue when output handler is not set breaking the whole form processor.
* Implemented Grouped Parameter Specification (requires Action Provider version 1.20 or newer).
* Support deleting conditions from actions.
Version 1.7
===========
......
......@@ -113,7 +113,13 @@ class CRM_FormProcessor_BAO_FormProcessorAction extends CRM_FormProcessor_DAO_Fo
$action->mapping = json_encode($action->mapping);
}
if (is_array($action->condition_configuration)) {
$action->condition_configuration = json_encode($action->condition_configuration);
// Delete condition if set to "No condition".
if ($action->condition_configuration['name']) {
$action->condition_configuration = json_encode($action->condition_configuration);
}
else {
$action->condition_configuration = '';
}
}
if (is_array($action->delay_configuration)) {
$action->delay_configuration = json_encode($action->delay_configuration);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment