function FilterBooleanOperatorStringTest::getGroupedExposedFilters
Same name in other branches
- 9 core/modules/views/tests/src/Kernel/Handler/FilterBooleanOperatorStringTest.php \Drupal\Tests\views\Kernel\Handler\FilterBooleanOperatorStringTest::getGroupedExposedFilters()
- 10 core/modules/views/tests/src/Kernel/Handler/FilterBooleanOperatorStringTest.php \Drupal\Tests\views\Kernel\Handler\FilterBooleanOperatorStringTest::getGroupedExposedFilters()
- 11.x core/modules/views/tests/src/Kernel/Handler/FilterBooleanOperatorStringTest.php \Drupal\Tests\views\Kernel\Handler\FilterBooleanOperatorStringTest::getGroupedExposedFilters()
Provides grouped exposed filter configuration.
Return value
array Returns the filter configuration for exposed filters.
1 call to FilterBooleanOperatorStringTest::getGroupedExposedFilters()
- FilterBooleanOperatorStringTest::testFilterGroupedExposed in core/
modules/ views/ tests/ src/ Kernel/ Handler/ FilterBooleanOperatorStringTest.php - Tests the Boolean filter with grouped exposed form enabled.
File
-
core/
modules/ views/ tests/ src/ Kernel/ Handler/ FilterBooleanOperatorStringTest.php, line 180
Class
- FilterBooleanOperatorStringTest
- Tests the core Drupal\views\Plugin\views\filter\BooleanOperatorString handler.
Namespace
Drupal\Tests\views\Kernel\HandlerCode
protected function getGroupedExposedFilters() {
$filters = [
'status' => [
'id' => 'status',
'table' => 'views_test_data',
'field' => 'status',
'relationship' => 'none',
'exposed' => TRUE,
'expose' => [
'operator' => 'status_op',
'label' => 'status',
'identifier' => 'status',
],
'is_grouped' => TRUE,
'group_info' => [
'label' => 'status',
'identifier' => 'status',
'default_group' => 'All',
'group_items' => [
1 => [
'title' => 'Active',
'operator' => '=',
'value' => '1',
],
2 => [
'title' => 'Blocked',
'operator' => '=',
'value' => '0',
],
],
],
],
];
return $filters;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.