You are here

protected function ChartsPluginDisplayChart::defineOptions in Charts 8

Same name and namespace in other branches
  1. 8.4 src/Plugin/views/display/ChartsPluginDisplayChart.php \Drupal\charts\Plugin\views\display\ChartsPluginDisplayChart::defineOptions()
  2. 8.3 src/Plugin/views/display/ChartsPluginDisplayChart.php \Drupal\charts\Plugin\views\display\ChartsPluginDisplayChart::defineOptions()
  3. 5.0.x src/Plugin/views/display/ChartsPluginDisplayChart.php \Drupal\charts\Plugin\views\display\ChartsPluginDisplayChart::defineOptions()

Information about options for all kinds of purposes will be held here.


'option_name' => array(
 - 'default' => default value,
 - 'contains' => (optional) array of items this contains, with its own
     defaults, etc. If contains is set, the default will be ignored and
     assumed to be array().
 ),

Return value

array Returns the options of this handler/plugin.

Overrides Attachment::defineOptions

File

src/Plugin/views/display/ChartsPluginDisplayChart.php, line 33
Contains the Chart display type (similar to Page, Block, Attachment, etc.)

Class

ChartsPluginDisplayChart
Display plugin to attach multiple chart configurations to the same chart.

Namespace

Drupal\charts\Plugin\views\display

Code

protected function defineOptions() {
  $options = parent::defineOptions();
  $options['style_plugin']['default'] = 'chart';
  $options['inherit_yaxis'] = array(
    'default' => '1',
  );
  return $options;
}