Problem/Motivation

When configuring a facet to display all items (by setting the Hard limit to "No limit"), the facet is still only displaying 10 items. This behavior is inconsistent with the expected functionality, where all available facet items should be displayed.

Steps to reproduce

  • Create or edit a facet
  • Set the facet's "Hard limit" setting to "No limit"
  • Save the facet configuration
  • View a page where the facet is displayed
  • Observe that only 10 items are shown in the facet, instead of all available items

Proposed resolution

Modify the FacetParamBuilder class to correctly handle "No limit" scenarios.

Implement the proposed changes in the FacetParamBuilder class.

Remaining tasks

  1. Write a merge request - merge request !88 created by @baikho in #2
  2. Review and feedback - done by @baikho in #5
  3. RTBC and feedback - done by @borisson_ in #7
  4. Commit - done by @mparker17 in #9
  5. Release - released by @mparker17 in 8.0.0-alpha5

User interface changes

N/A

API changes

N/A

Data model changes

N/A

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

baikho created an issue. See original summary.

baikho’s picture

Status: Active » Needs review
StatusFileSize
new1.13 KB
baikho’s picture

Status: Needs review » Needs work

Tests are failing

baikho’s picture

Status: Needs work » Needs review
sokru’s picture

Thanks for the issue and work so far. I'd prefer using the same approach that Search API OpenSearch used on #3508754: Facet limit can't be set to 'No limit'., the default should stay at 10, but unlimited means same as default max. buckets (10k).

borisson_’s picture

Status: Needs review » Reviewed & tested by the community

I think the changes in the MR look good.

mparker17’s picture

Status: Reviewed & tested by the community » Fixed

Looks good to me as well, merging!

Thank you very much @baikho for including tests in your merge request!

  • mparker17 committed 48c0aff2 on 8.0.x authored by baikho
    Issue #3519557 by baikho, sokru, borisson_: "No Limit" displays 10 items
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

mparker17’s picture

Issue summary: View changes

Updated steps to complete so I can say when it is released.

mparker17’s picture

Issue summary: View changes

(Fixed typo in issue summary)

mparker17’s picture

Issue summary: View changes

Released in in 8.0.0-alpha5!

mparker17’s picture

Issue summary: View changes

(making issue summary more consistent with newer issues)