dotCMS / dotCMS/core

Content Drive: adding a content-type filter to the global search hides matches the search alone found

Open
#37,211 1 comment 0 reactions 1 assignee View on GitHub

@ihoffmann-dot is already working on this.

Since Sep 11, 2026.

  • #37525 by @ihoffmann-dot — merged
Team : Scout Type : Defect
Dominant language
Java
Stars
970
Forks
486
Avg merge
3d 33m
Merged PRs (30d)
170

Description

Problem Statement

In Content Drive, the global search filter and a content-type filter don't compose correctly: typing a term in the global search should return all matching content, and narrowing further by content type should return a subset of those same matches. Instead, adding a content-type filter surfaces content that the plain global search did not return, and removing the content-type filter again makes that content disappear from the results — even though the same search term is used throughout. The Search All portlet composes global search + content-type correctly for the same term.

Steps to Reproduce

Video: content drive general filter difference.mov

  1. In Content Drive, use the global search filter only and type "capy".
  2. Expected capybara image assets (uploaded and matching by filename) are missing from the results.
  3. Without clearing the search term, add a content-type filter for File Asset.
  4. The same capybara images now appear.
  5. Remove the content-type filter again (keeping the search term) — the capybara images disappear from the results again.
  6. In the Search All portlet, typing "capy" in the global search (no content-type filter) returns the capybara images correctly, with no need for an additional filter.

Expected vs Actual

Expected: the global search filter alone returns every content item matching the term, matching what Search All returns; adding a content-type filter should only narrow that same set, never introduce results that weren't already found by the term alone.

Actual: Content Drive's global search filter alone misses matches; adding a content-type filter surfaces items the unfiltered search should have already found; removing the content-type filter makes them disappear again. The Search All portlet does not exhibit this inconsistency for the same term.

Acceptance Criteria

  • The global search filter alone returns every content item that would also be returned when a content-type filter is added for the same term
  • Adding a content-type filter to the global search only narrows the existing match set; it does not introduce items absent from the unfiltered search
  • Behavior is consistent with the Search All portlet for the same search term
  • Verified against a large dataset (~718,174 contentlets)

Parent Epic

#36814

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.