You are here

function lingotek_clear_exceptions_modal in Lingotek Translation 7.5

Same name and namespace in other branches
  1. 7.6 lingotek.module \lingotek_clear_exceptions_modal()
1 string reference to 'lingotek_clear_exceptions_modal'
lingotek_menu in ./lingotek.module
Implements hook_menu().

File

./lingotek.module, line 2389

Code

function lingotek_clear_exceptions_modal($bundle_name) {
  ctools_include('node.pages', 'node', '');
  ctools_include('modal');
  ctools_include('ajax');
  $form_state = array(
    'ajax' => TRUE,
    'entity_type' => 'node',
    'bundle_name' => $bundle_name,
  );
  $output = ctools_modal_form_wrapper('lingotek_clear_exceptions_form', $form_state);
  if (!empty($form_state['executed'])) {
    $commands = array();
    $commands[] = ctools_modal_command_dismiss();
    $commands[] = ctools_ajax_command_reload();
    print ajax_render($commands);
    drupal_exit();
  }
  print ajax_render($output);
}