You are here

public function DebugWebformHandler::getSummary in Webform 6.x

Same name and namespace in other branches
  1. 8.5 src/Plugin/WebformHandler/DebugWebformHandler.php \Drupal\webform\Plugin\WebformHandler\DebugWebformHandler::getSummary()

Returns a render array summarizing the configuration of the webform handler.

Return value

array A render array.

Overrides WebformHandlerBase::getSummary

File

src/Plugin/WebformHandler/DebugWebformHandler.php, line 71

Class

DebugWebformHandler
Webform submission debug handler.

Namespace

Drupal\webform\Plugin\WebformHandler

Code

public function getSummary() {
  $settings = $this
    ->getSettings();
  switch ($settings['format']) {
    case static::FORMAT_JSON:
      $settings['format'] = $this
        ->t('JSON');
      break;
    case static::FORMAT_YAML:
    default:
      $settings['format'] = $this
        ->t('YAML');
      break;
  }
  return [
    '#settings' => $settings,
  ] + parent::getSummary();
}