Skip to content

Anchor categories are showing products of disabled subcategories #9002

@koenner01

Description

@koenner01

Categories that are set to anchor 'Yes' and have disabled subcategories will show the products from those disabled subcategories on the frontend

Preconditions

  1. PHP7.0
  2. MG2 2.1.x (tested on 2.1.2, 2.1.4 and 2.1.5)

Steps to reproduce

  1. Create a simple product 'Test' that is in stock and visible on catalog
  2. Create a category A (don't add products to it)
  3. Create a subcategory B (parent is A) and add our 'Test' product to it
  4. Goto category A on frontend

Expected result

  1. Category A should not have any products results

Actual result

  1. Category A is showing our 'Test' product

I did some digging into this issue and found a post from 2013 about MG1 having this exact same problem (https://www.proxiblue.com.au/blog/Collection_of_products_in_all_child_categories/).

Metadata

Metadata

Assignees

Labels

Component: CatalogIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.1.xThe issue has been reproduced on latest 2.1 releaseReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseReproduced on 2.3.xThe issue has been reproduced on latest 2.3 releasebug report

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions