You are here

function lingotek_bulk_mt_download_batch_finished in Lingotek Translation 7.2

Batch Finished: Bulk Machine Translation Complete.

1 string reference to 'lingotek_bulk_mt_download_batch_finished'
lingotek_bulk_mt_download_batch_create in ./lingotek.batch.inc
Batch Create - Download: Create a Bulk Machine Translate DOWNLOAD Batch.

File

./lingotek.batch.inc, line 330

Code

function lingotek_bulk_mt_download_batch_finished($success, $results, $operations) {
  $messages = array();
  $result_count = count($results);
  if ($success) {

    // The 'success' (TRUE/FALSE) means no fatal PHP errors were detected. All other error management should be handled using 'results'.
    $messages[] = t('The process finished successfully.');
    $messages[] = format_plural($result_count, 'One translated node has been downloaded.', '@count translated nodes have been downloaded.');
  }
  else {
    $messages[] = t('The process finished with an errors.  Some content may have been missed.');
    $messages[] = format_plural($result_count, 'One translated node has been downloaded.', '@count translated nodes have been downloaded.');
  }
  $_SESSION['bulk_mt_batch_download_results'] = $messages;

  // Save data before redirect.
  drupal_goto(LINGOTEK_BASE_URL . '/mt-content-downloaded');
}