Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
drupal.org
better_exposed_filters
Commits
62cddeb3
Commit
62cddeb3
authored
Jan 23, 2020
by
Martin Keereman
Browse files
Issue #3106332 by dmitry.korhov: Undefined index: exposed_form_options
parent
abcf30f9
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/Plugin/views/exposed_form/BetterExposedFilters.php
View file @
62cddeb3
...
...
@@ -188,7 +188,7 @@ class BetterExposedFilters extends InputRequired {
// User raw user input for AJAX callbacks.
$user_input
=
$form_state
->
getUserInput
();
$bef_input
=
$user_input
[
'exposed_form_options'
][
'bef'
];
$bef_input
=
$user_input
[
'exposed_form_options'
][
'bef'
]
??
NULL
;
/*
* General BEF settings
...
...
@@ -559,7 +559,7 @@ class BetterExposedFilters extends InputRequired {
// Validate exposed filter configuration.
if
(
$type
===
'filter'
)
{
foreach
(
$config
as
$filter_id
=>
$filter_options
)
{
$plugin_id
=
$filter_options
[
'configuration'
][
'plugin_id'
];
$plugin_id
=
$filter_options
[
'configuration'
][
'plugin_id'
]
??
NULL
;
if
(
!
$plugin_id
)
{
continue
;
}
...
...
@@ -574,7 +574,7 @@ class BetterExposedFilters extends InputRequired {
}
// Validate exposed pager/sort configuration.
elseif
(
in_array
(
$type
,
[
'pager'
,
'sort'
]))
{
$plugin_id
=
$config
[
'configuration'
][
'plugin_id'
];
$plugin_id
=
$config
[
'configuration'
][
'plugin_id'
]
??
NULL
;
if
(
!
$plugin_id
)
{
continue
;
}
...
...
@@ -625,7 +625,7 @@ class BetterExposedFilters extends InputRequired {
// Save exposed filter configuration.
if
(
$type
===
'filter'
)
{
foreach
(
$config
as
$filter_id
=>
$filter_options
)
{
$plugin_id
=
$filter_options
[
'configuration'
][
'plugin_id'
];
$plugin_id
=
$filter_options
[
'configuration'
][
'plugin_id'
]
??
NULL
;
/** @var \Drupal\better_exposed_filters\Plugin\BetterExposedFiltersWidgetInterface $plugin */
if
(
!
$plugin_id
)
{
unset
(
$bef_options
[
'filter'
][
$filter_id
]);
...
...
@@ -645,7 +645,7 @@ class BetterExposedFilters extends InputRequired {
}
// Save exposed pager/sort configuration.
elseif
(
in_array
(
$type
,
[
'pager'
,
'sort'
]))
{
$plugin_id
=
$config
[
'configuration'
][
'plugin_id'
];
$plugin_id
=
$config
[
'configuration'
][
'plugin_id'
]
??
NULL
;
if
(
!
$plugin_id
)
{
unset
(
$bef_options
[
$type
]);
continue
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment