function trigger_unassign_submit
trigger_unassign_submit($form, &$form_state)
Form submission handler for trigger_unassign().
File
- modules/trigger/trigger.admin.inc, line 89
- Admin page callbacks for the trigger module.
Code
function trigger_unassign_submit($form, &$form_state) { if ($form_state['values']['confirm'] == 1) { $aid = actions_function_lookup($form_state['values']['aid']); db_delete('trigger_assignments') ->condition('hook', $form_state['values']['hook']) ->condition('aid', $aid) ->execute(); drupal_static_reset('trigger_get_assigned_actions'); $actions = actions_get_all_actions(); watchdog('actions', 'Action %action has been unassigned.', array('%action' => $actions[$aid]['label'])); drupal_set_message(t('Action %action has been unassigned.', array('%action' => $actions[$aid]['label']))); $form_state['redirect'] = 'admin/structure/trigger/' . $form_state['values']['module']; } else { drupal_goto('admin/structure/trigger'); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!trigger!trigger.admin.inc/function/trigger_unassign_submit/7.x