Hi Craig,
Thank you for waiting.
I've been performing some testing and research and here are my findings.
With the introduction of Blocks, there have been some major changes around how the query filters and the respective search form fields interact with each other. The query filter is more tightly integrated to the front-end search form fields now, which means that the workaround that you've been using by adding a single search form filter for querying multiple custom fields through the same URL parameter will no longer work. This especially becomes challenging as the custom fields involved are checkboxes type fields, which store data in a special serialized format.
To achieve this with the latest version of the Toolset plugins, you'll need some extra steps:
1. From your view's "Query Filter" section please remove the existing query filter for those 10 custom fields and add them again using the "New filter" button in the "Search and Pagination".
This will add the query filter and the search form select field for each field separately, with a unique URL parameter.
Screenshot of "Query Filter" section:
hidden link
Screenshot of "Search and Pagination" section:
hidden link
2. Now that each custom field will have its own select field in the search form, you'll need some custom script, to select the same value in all the select fields (where applicable), when a value is selected for the first "choose-by-area" field:
( you can add this script in the "JS editor" tab below the "Search and Pagination" section )
jQuery( document ).on( 'js_event_wpv_pagination_completed js_event_wpv_parametric_search_results_updated ready', function( event, data ) {
jQuery('select[name="wpv-wpcf-choose-by-area"]').on('change', function() {
jQuery('.wpv-filter-form select.js-wpv-filter-trigger').val(this.value);
});
});
3. In the "Custom Search Settings" you can select the "Update the View results only when clicking on the search button" and the "Reload the page to update the View results" options.
( screenshot: hidden link )
4. To make sure that these custom field queries are processed with "OR" relationship and not "AND", you'll also need a custom function attached to the "wpv_filter_query" filter:
( ref: https://toolset.com/documentation/programmer-reference/views-filters/#wpv_filter_query )
add_filter( 'wpv_filter_query', 'filter_team_custom_fn', 1000 , 3 );
function filter_team_custom_fn( $query_args, $view_settings ) {
if ( ( !is_admin() && isset($view_settings['view_id'] ) ) && ( $view_settings['view_id'] == 4569 ) )
{
$query_args['meta_query']['relation'] = "OR";
}
return $query_args;
}
5. The last step would be to include some custom CSS code in the "CSS editor" tab below the "Search and Pagination" section so that only the first search filter for the "choose-by-area" field is visible on the front-end and others are hidden:
.wpv-filter-form .form-group {
display: none;
}
.wpv-filter-form .form-group:nth-of-type(1) {
display: block;
}
I hope this helps and please let me know if any step is not clear.
regards,
Waqar