Skip to content
Snippets Groups Projects

Add proposed code to check remember setting when fetching exposed input from session.

Open catch requested to merge issue/drupal-3506696:3506696-viewexecutable-should-not into 11.x
1 unresolved thread

Closes #3506696

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
774 *
775 * @return bool
776 * Returns TRUE if the "Remember" setting is enabled for any
777 * of the user's roles, FALSE otherwise.
778 */
779 public function isFilterRememberEnabled() {
780 $roles = $this->getUser()->getRoles();
781 // Loop through the exposed input filters.
782 foreach ($this->exposed_input as $filter_name => $input) {
783 // Check if the filter exists in the display handler's filter options.
784 if (isset($this->display_handler->getOption('filters')[$filter_name])) {
785 // Retrieve the configuration for the current filter.
786 $filter_config = $this->display_handler->getOption('filters')[$filter_name];
787 // Check if the "Remember" setting is enabled.
788 if ($filter_config['expose']['remember']) {
789 foreach ($roles as $role) {
  • added 1 commit

    • 09b99890 - Updated to use hasRole instead of loading all roles.

    Compare with previous version

  • Please register or sign in to reply
    Loading