You are here

function heartbeat_messages_admin_overview_submit in Heartbeat 6.4

Same name and namespace in other branches
  1. 7 modules/heartbeat_ui/heartbeat_ui.admin.inc \heartbeat_messages_admin_overview_submit()

Process heartbeat_messages_admin_overview form submissions.

Execute the chosen 'Update option' on the selected comments, such as publishing, unpublishing or deleting.

File

./heartbeat.admin.inc, line 93
Admnistration tasks for heartbeat.

Code

function heartbeat_messages_admin_overview_submit($form, &$form_state) {
  if ($form_state['values']['operation'] == 'delete') {
    foreach ($form_state['values']['heartbeat-activity'] as $uaid => $value) {
      if ($value) {
        _heartbeat_activity_delete($uaid);
      }
    }
    drupal_set_message(t('The update has been performed.'));
    $form_state['redirect'] = 'admin/content/heartbeat';
  }
}