You are here

function party_attached_entity_remove_confirm_submit in Party 7

Same name and namespace in other branches
  1. 8.2 party.pages.inc \party_attached_entity_remove_confirm_submit()

Submit handler for the data set remove form.

File

./party.pages.inc, line 441
party.pages.inc

Code

function party_attached_entity_remove_confirm_submit($form, &$form_state) {
  $party = $form['#party'];
  $data_set_controller = $form['#data_set'];
  $data_set_controller
    ->detachEntity($form['#entity']);
  $data_set_controller
    ->save();

  // Redirect to the set piece.
  $form_state['redirect'] = 'party/' . $party->pid . '/' . $data_set_controller
    ->getDataInfo('path element');
}