You are here

function ca_actions_form_remove_action_submit in Ubercart 6.2

Remove action submit handler.

See also

ca_actions_form()

1 string reference to 'ca_actions_form_remove_action_submit'
ca_actions_form in ca/ca.admin.inc
Build a form for adding and editing actions on a predicate.

File

ca/ca.admin.inc, line 484
Conditional actions overview UI.

Code

function ca_actions_form_remove_action_submit($form, &$form_state) {

  // Save the existing actions to preserve any changes.
  ca_actions_form_update_actions($form_state['values']['pid'], $form_state['values']['actions']);

  // Remove the appropriate action from the predicate and save it.
  ca_remove_action($form_state['values']['pid'], $form_state['clicked_button']['#parents'][1]);
  drupal_set_message(t('Action removed.'));
}