You are here

protected function EntityBundle::defineOptions in Commerce Core 8.2

Same name in this branch
  1. 8.2 src/Plugin/views/filter/EntityBundle.php \Drupal\commerce\Plugin\views\filter\EntityBundle::defineOptions()
  2. 8.2 src/Plugin/views/field/EntityBundle.php \Drupal\commerce\Plugin\views\field\EntityBundle::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 InOperator::defineOptions

File

src/Plugin/views/filter/EntityBundle.php, line 32

Class

EntityBundle
Filters by entity bundle.

Namespace

Drupal\commerce\Plugin\views\filter

Code

protected function defineOptions() {
  $options = parent::defineOptions();
  $options['expose']['contains']['hide_single_bundle'] = [
    'default' => TRUE,
  ];
  return $options;
}