You are here

function lingotek_get_change_workflow_form_submit in Lingotek Translation 7.7

Same name and namespace in other branches
  1. 7.4 lingotek.module \lingotek_get_change_workflow_form_submit()
  2. 7.5 lingotek.module \lingotek_get_change_workflow_form_submit()
  3. 7.6 lingotek.module \lingotek_get_change_workflow_form_submit()
1 string reference to 'lingotek_get_change_workflow_form_submit'
lingotek_get_change_workflow_form in ./lingotek.module

File

./lingotek.module, line 1242

Code

function lingotek_get_change_workflow_form_submit($form, $form_state) {
  if (!empty($form_state['nids'])) {
    $nids = $form_state['nids'];
    $workflow_id = $form_state['values']['lingotek']['workflow_id'];
    if (isset($form_state['values']['lingotek']['prefill_phases_checkbox']) && $form_state['values']['lingotek']['prefill_phases_checkbox']) {
      $prefill_phase = $form_state['values']['lingotek']['prefill_phase_select'];
    }
    else {
      $prefill_phase = NULL;
    }
    $entity_type = $form_state['entity_type'];

    // SUBMIT THE WORKFLOW CHANGES TO TMS
    lingotek_entity_change_workflow($entity_type, $nids, $workflow_id, $prefill_phase);
  }
}