function JobForm::checkoutInfo

Helper function for retrieving the rendered job checkout information.

1 call to JobForm::checkoutInfo()

File

src/Form/JobForm.php, line 736

Class

JobForm
Form controller for the job edit forms.

Namespace

Drupal\tmgmt\Form

Code

function checkoutInfo(JobInterface $job) {

  // The translator might have been disabled or removed.
  if (!$job
    ->hasTranslator()) {
    return array(
      '#markup' => t('The job has no provider assigned.'),
    );
  }
  $translator = $job
    ->getTranslator();
  $plugin_ui = $this->translatorManager
    ->createUIInstance($translator
    ->getPluginId());
  return $plugin_ui
    ->checkoutInfo($job);
}