You are here

function party_archive_form_submit in Party 7

Submit handler for the party archive form.

File

./party.pages.inc, line 163
party.pages.inc

Code

function party_archive_form_submit($form, &$form_state) {
  if (!empty($form_state['values']['archive'])) {
    $form_state['party']->archived = TRUE;
  }
  elseif (!empty($form_state['values']['un-archive'])) {
    $form_state['party']->archived = FALSE;
  }
  else {
    return;
  }
  $form_state['party']
    ->save();
}