You are here

public function Notifications_Subscription::form_submit in Notifications 7

Process form submission

File

./notifications.subscription.inc, line 375
Drupal Notifications Framework - Default class file

Class

Notifications_Subscription
Common base for subscription type and subscription instance

Code

public function form_submit($form, &$form_state) {
  $triggering_element = isset($form_state['triggering_element']['#name']) ? $form_state['triggering_element']['#name'] : '';
  switch ($triggering_element) {
    case 'cancel':
    case 'delete':
      $operation = $triggering_element;
      break;
    default:
      $operation = $form_state['values']['operation'];
      $this
        ->set_properties_from_submission($form, $form_state);
      break;
  }
  return $this
    ->form_operation($operation, $form, $form_state);
}