Ability to filter views of unpublished content

Created on 25 March 2024, 9 months ago

Problem/Motivation

I want to test my views before content is published. Content editors need to know what the page will look like too.

That is not possible when using this filter since it relies on the taxonomy _index table which in turn does not work when
https://www.drupal.org/project/drupal/issues/962664 Taxonomy Index for unpublished entities Needs work

Steps to reproduce

Create a search api view. Create some unpublished content of a type included in the index.
Do not include any published status filter conditions on the view.
Remove the entity status processor from the index.
Re-index if necessary.

Proposed resolution

Option 1: Allow users to configure fields to use for the query. Build the entity query.
Option 2: Rely on the contrib module taxonomy_entity_index
https://www.drupal.org/project/taxonomy_entity_index
Option 3: Document issue on module and point to core patch.
(This option is not suitable for our use case but may work for some)

Remaining tasks

Choose an option and implement tasks.

User interface changes

Option 1 Adds a config field

API changes

Option 1 changes the schema
Option 2 adds a new dependency

Data model changes

Option 1 changes the schema

Feature request
Status

Active

Version

1.0

Component

Code

Created by

🇨🇦Canada lolcode

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

Comments & Activities

Production build 0.71.5 2024