Exposed filters always set to "All"

Created on 22 November 2023, 7 months ago
Updated 14 June 2024, 14 days ago

Problem/Motivation

The latest version sets always the exposed filters as "All" or "Any" no matter what value the user selects, this doesn't happen when the view has AJAX enabled and could be a workaround but there's a requirement for the url to change and it doesn't happen when that option is enabled. Also tested this with views_ajax_history module and the behavior is the same as it was without AJAX

Steps to reproduce

  1. Create a view and set up 1 or 2 exposed filters
  2. Create a node with a Views Reference Field and configured with the extra setting "Exposed Filters - editor view"
  3. On the node creation select the view, display and enable "Show filters on page"
  4. Save the node and try to use the filters
  5. The page reloads but it shows always all rows

Proposed resolution

Noticed the query doesn't get executed, the project has 2 custom views filters and they worked on the view preview, but not on the node. Debugging led us to the viewsreference.module and to an alterView() function that sets that value to "All" always. That pre_view hook should check the user input filters too.

There's a custom patch that it's working with our current setup, attaching it just in case someone needs it.

πŸ› Bug report
Status

Postponed: needs info

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @dantesinferno
  • Status changed to Postponed: needs info 14 days ago
  • πŸ‡¬πŸ‡§United Kingdom scott_euser

    I don't see 'Show filters on page' in the code, is it perhaps a custom Views Reference Settings plugin you are using?

Production build 0.69.0 2024