WP Solr not respecting Toolset views filters

  • wowmatt
    Participant
    3 years, 1 month ago #25021

    Hey
    The pagination issue is on an archive.
    The filter boxes not working is on a view in a page.
    Thanks

    wpsolr
    Keymaster
    3 years, 1 month ago #25054

    Our Toolset 100K WooCommerce products is a Toolset archive. Looks like the pagination/filters are ok.

    wpsolr
    Keymaster
    3 years, 1 month ago #25055

    Do you see errors in WordPress debug.log, or in the chrome console?

    wpsolr
    Keymaster
    3 years, 1 month ago #25056

    If not, you can watch your current search engine queries with our Query monitor add-on.

    The add-on not only shows the query, but also the results and response times. The results section should show the total number of results that can be compared to the number of pages shown in the pagination bar.

    wowmatt
    Participant
    3 years, 1 month ago #25232

    Hi
    I have set up the query monitor plugin and enabled in WP Solr but the info doesn’t really make sense to me.
    As mentioned when I use filters they are ignored by WP Solr when the plugin is active.

    In my test I used the country filter on the site and set this to UK but it was ignored.

    From the “WPSolr Queries” in the debug menu the query was

    { "from": 0, "size": 10, "sort": [ { "title_s": { "order": "asc" } } ], "_source": [ "id", "PID", "type", "meta_type_s", "title", "numcomments", "comments", "displaydate", "displaymodified", "*categories_str", "author", "*post_thumbnail_href_str", "*post_href_str", "snippet_s" ], "query": { "bool": { "must": { "query_string": { "query": "text:(*)", "default_operator": "AND" } }, "filter": { "bool": { "must": [ { "terms": { "type": [ "post", "offer", "events", "network" ] } }, { "bool": { "must_not": [ { "terms": { "post_status_s": [ "draft", "pending", "trash", "future", "private", "auto-draft" ] } } ] } }, { "terms": { "type": [ "offer" ] } }, { "bool": { "must_not": [ { "terms": { "PID_i": [ 207 ] } } ] } }, { "bool": { "should": [ { "bool": { "must_not": [ { "bool": { "must": { "exists": { "field": "is_excluded_s" } } } } ] } }, { "terms": { "is_excluded_s": [ "n" ] } } ] } }, { "bool": { "must_not": [ { "terms": { "_id": [ "wpsolr_doc_id_attachment" ] } } ] } } ] } } } } }

    Also here is a screenshot:
    https://markuphero.com/share/fPlOWnYAWcVIShKT10y7

    Let me know if you need any more info or I should try something else?

    Thanks.

    wpsolr
    Keymaster
    3 years, 1 month ago #25246

    I understand now. You’re using Toolset filters, not WPSOLR filters.
    Can’t you use WPSOLR filters instead?

    wowmatt
    Participant
    3 years, 1 month ago #25247

    Hi
    How can I insert WPSolr filters? Are there shortcodes to use or blocks to use in the block editor?

    I can’t use Widgets as I don’t have a widget section on these pages.

    Thanks.

    wpsolr
    Keymaster
    3 years, 1 month ago #25248

    It is a widget indeed.

    Perhaps insert it with https://wordpress.org/plugins/widget-shortcode/ ?

    wpsolr
    Keymaster
Viewing 9 posts - 31 through 39 (of 39 total)

You must be logged in to reply to this topic.