Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ViewsBlock.php

function ViewsBlock::defaultConfiguration

Overrides ViewsBlockBase::defaultConfiguration

File

core/modules/views/src/Plugin/Block/ViewsBlock.php, line 104

Class

ViewsBlock
Provides a generic Views block.

Namespace

Drupal\views\Plugin\Block

Code

public function defaultConfiguration() {
    $settings = parent::defaultConfiguration();
    if ($this->displaySet) {
        $settings += $this->view->display_handler
            ->blockSettings($settings);
    }
    // Set custom cache settings.
    if (isset($this->pluginDefinition['cache'])) {
        $settings['cache'] = $this->pluginDefinition['cache'];
    }
    return $settings;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal