You are here

function commerce_generate_batch_finished in Commerce Bulk 8

Batch finish handler for implementations of DevelGeneratePlugin.

1 string reference to 'commerce_generate_batch_finished'
GenerateProducts::batchGenerateProducts in modules/commerce_generate/src/Plugin/DevelGenerate/GenerateProducts.php

File

modules/commerce_generate/commerce_generate.module, line 38
Contains commerce_generate.module.

Code

function commerce_generate_batch_finished($success, $results, $operations) {
  if ($success) {
    $message = t('Creation of elements successfully finished.');
  }
  else {
    $message = t('Finished with an error.');
  }
  \Drupal::messenger()
    ->addMessage($message);
}