You are here

function node_gallery_api_batch_sorting_finished in Node Gallery 7

Batch API sorting finished callback.

2 string references to 'node_gallery_api_batch_sorting_finished'
node_gallery_api_sort_items_form_set_chronological_sorting in ./node_gallery_api.pages.inc
Submit function to set image weights reflecting chronological order of their making
node_gallery_api_sort_items_form_submit in ./node_gallery_api.pages.inc
Submit handler for sort form.

File

./node_gallery_api.inc, line 278
Node Gallery API function

Code

function node_gallery_api_batch_sorting_finished($success, $results, $operation) {
  if ($success) {

    // $results contains ['ngid'] as well as the actual results,
    // so we subtract one here.
    $message = format_plural(count($results) - 1, 'One image processed.', '@count images processed.');
  }
  else {
    $message = t('Finished with an error.');
  }
  node_gallery_api_clear_gallery_caches($results['ngid']);
  drupal_set_message($message);
}