- Issue created by @serverjohn
- ๐ท๐ดRomania amateescu
I tried to reproduce this using the steps in the issue summary and I couldn't get the view to display anything after adding the second contextual filter. Can you please update the steps with actual values? Even node title and values for the body field would help to ensure that I'm testing your specific scenario.
And you can leave out the parts about adding the modules, installing the site, etc. as they're not necessary :)
I am no longer able to produce the problem as described above. I do still have an instance of a full blown site that has this problem. I have been messing around with composer trying to get the proper versions of things that I had in place but I lack the experience necessary. It seems to be a problem with this combination:
- drupal 11.1.8
- trash 3.0.16
- views_contextual_filters_or 8.x-1.5
Here is an updated action list:
- Create and Article with "Test" in the title and body fields
- Create a Views page for the Article content type with the following
settings:- Page settings > Path > test-query-parameter-and-trash-module
- Advanced > Contextual filters > add > Title / Content
- Configure contextual filter: Content: Title
- When the filter value is NOT in the URL > Provide default
value - Type > Query parameter
- Query parameter > param
- When the filter value is NOT in the URL > Provide default
- Configure contextual filter: Content: Title
- Advanced > Contextual filters > add > Body (body) / Content
- Configure contextual filter: Content: Body (body)
- When the filter value is NOT in the URL > Provide default
value - Type > Query parameter
- Query parameter > param
- When the filter value is NOT in the URL > Provide default
- Configure contextual filter: Content: Body (body)
- Advanced > Other > Query settings > Contextual filters OR > checked
- Navigate to /test-query-parameter-and-trash-module/?param=test
- You should see the article created with test in the title and body
- Install the Trash module
- Navigate to /test-query-parameter-and-trash-module/?param=test
And here is the view config:
uuid: 7a10f1eb-ce0f-470b-b6fd-be8b85090aa1 langcode: en status: true dependencies: config: - core.entity_view_mode.node.teaser - node.type.article module: - node - user id: test_query_parameter_and_trash_module label: 'Test query parameter and Trash module' module: views description: '' tag: '' base_table: node_field_data base_field: nid display: default: id: default display_title: Default display_plugin: default position: 0 display_options: title: 'Test query parameter and Trash module' fields: title: id: title table: node_field_data field: title relationship: none group_type: group admin_label: '' entity_type: node entity_field: title plugin_id: field label: '' exclude: false alter: alter_text: false make_link: false absolute: false word_boundary: false ellipsis: false strip_tags: false trim: false html: false element_type: '' element_class: '' element_label_type: '' element_label_class: '' element_label_colon: false element_wrapper_type: '' element_wrapper_class: '' element_default_classes: true empty: '' hide_empty: false empty_zero: false hide_alter_empty: true click_sort_column: value type: string settings: link_to_entity: true group_column: value group_columns: { } group_rows: true delta_limit: 0 delta_offset: 0 delta_reversed: false delta_first_last: false multi_type: separator separator: ', ' field_api_classes: false pager: type: mini options: offset: 0 pagination_heading_level: h4 items_per_page: 10 total_pages: null id: 0 tags: next: โบโบ previous: โนโน expose: items_per_page: false items_per_page_label: 'Items per page' items_per_page_options: '5, 10, 25, 50' items_per_page_options_all: false items_per_page_options_all_label: '- All -' offset: false offset_label: Offset exposed_form: type: basic options: submit_button: Apply reset_button: false reset_button_label: Reset exposed_sorts_label: 'Sort by' expose_sort_order: true sort_asc_label: Asc sort_desc_label: Desc access: type: perm options: perm: 'access content' cache: type: tag options: { } empty: { } sorts: created: id: created table: node_field_data field: created relationship: none group_type: group admin_label: '' entity_type: node entity_field: created plugin_id: date order: DESC expose: label: '' field_identifier: '' exposed: false granularity: second arguments: title: id: title table: node_field_data field: title relationship: none group_type: group admin_label: '' entity_type: node entity_field: title plugin_id: string default_action: default exception: value: all title_enable: false title: All title_enable: false title: '' default_argument_type: query_parameter default_argument_options: query_param: param fallback: '' multiple: and summary_options: base_path: '' count: true override: false items_per_page: 25 summary: sort_order: asc number_of_records: 0 format: default_summary specify_validation: false validate: type: none fail: 'not found' validate_options: { } glossary: false limit: 0 case: none path_case: none transform_dash: false break_phrase: false body_value: id: body_value table: node__body field: body_value relationship: none group_type: group admin_label: '' plugin_id: string default_action: default exception: value: all title_enable: false title: All title_enable: false title: '' default_argument_type: query_parameter default_argument_options: query_param: param fallback: '' multiple: and summary_options: base_path: '' count: true override: false items_per_page: 25 summary: sort_order: asc number_of_records: 0 format: default_summary specify_validation: false validate: type: none fail: 'not found' validate_options: { } glossary: false limit: 0 case: none path_case: none transform_dash: false break_phrase: false filters: status: id: status table: node_field_data field: status entity_type: node entity_field: status plugin_id: boolean value: '1' group: 1 expose: operator: '' type: id: type table: node_field_data field: type entity_type: node entity_field: type plugin_id: bundle value: article: article style: type: table options: grouping: { } row_class: '' default_row_class: true columns: title: title default: '-1' info: title: sortable: false default_sort_order: asc align: '' separator: '' empty_column: false responsive: '' override: true sticky: false summary: '' empty_table: false caption: '' description: '' class: '' row: type: 'entity:node' options: view_mode: teaser query: type: views_query options: query_comment: '' disable_sql_rewrite: false distinct: false replica: false query_tags: { } contextual_filters_or: true relationships: { } group_by: true header: { } footer: { } display_extenders: { } cache_metadata: max-age: -1 contexts: - 'languages:language_content' - 'languages:language_interface' - url - url.query_args - 'user.node_grants:view' - user.permissions tags: { } block_1: id: block_1 display_title: Block display_plugin: block position: 2 display_options: exposed_block: true display_extenders: { } cache_metadata: max-age: -1 contexts: - 'languages:language_content' - 'languages:language_interface' - url - url.query_args - 'user.node_grants:view' - user.permissions tags: { } page_1: id: page_1 display_title: Page display_plugin: page position: 1 display_options: display_extenders: { } path: test-query-parameter-and-trash-module cache_metadata: max-age: -1 contexts: - 'languages:language_content' - 'languages:language_interface' - url - url.query_args - 'user.node_grants:view' - user.permissions tags: { }
I am closing this. I have unsuccessfully tried to reproduce this. I do have a site with many other modules installed where uninstalling the trash module allows the contextual or filter to work. However, a very basic site build no longer presents the problem. I'm not sure what changed. I even pulled up the initial build, from the first comment, that I still had on another computer. That also, no longer showed the problem as described. ::shrug::
Maybe it was the gremlins... or maybe I am just crazy...