You are here

public function SimpleSitemapDisplayExtender::optionsSummary in Simple XML sitemap (Views integration) 8

Provide the default summary for options in the views UI.

This output is returned as an array.

Overrides DisplayExtenderPluginBase::optionsSummary

File

src/Plugin/views/display_extender/SimpleSitemapDisplayExtender.php, line 226
Contains Simple XML Sitemap display extender.

Class

SimpleSitemapDisplayExtender
Simple XML Sitemap display extender plugin.

Namespace

Drupal\simple_sitemap_views\Plugin\views\display_extender

Code

public function optionsSummary(&$categories, &$options) {
  if ($this
    ->hasSitemapSettings()) {
    $categories['simple_sitemap'] = [
      'title' => $this
        ->t('Simple XML Sitemap'),
      'column' => 'second',
    ];
    $options['simple_sitemap'] = [
      'category' => 'simple_sitemap',
      'title' => $this
        ->t('Status'),
      'value' => $this
        ->isIndexingEnabled() ? $this
        ->t('Included in sitemap') : $this
        ->t('Excluded from sitemap'),
    ];
  }
}