MDVA-40134: GraphQL does not return related products when the shared catalog is enabled
GraphQL does not return related products when the shared catalog is enabled. Quality patch MDVA-40134 for magento/module-catalog-permissions-graph-ql applies to Magento Open Source and Adobe Commerce 2.4.2 to 2.4.2-p2.
- Categories
- GraphQL
- Components
- magento/module-catalog-permissions-graph-ql
- Origin
- adobe-commerce-support
- Since QPT
- 1.1.2
Issue
GraphQL does not return related products when the shared catalog is enabled.
Steps to reproduce
1. Go to Stores > Configuration > General > B2B features and enable Company and Shared Catalog. 1. Go to Catalog > Shared Catalog and add all the products to the General Catalog. 1. Use the sample data and modify the Joust Duffle Bag (SKU 24-MB01). 1. Under Related Products, add the two Duffle bags (ID 7 and 13). 1. Send a Post request: <pre>{ products(filter: {sku: {eq: "24-MB01"}}, sort: {name: ASC}) { items { related_products { uid name } } } }</pre>
Adobe's page lists 2.4.2-p1 – 2.4.2-p2 as compatible; the versions below are resolved from the current QPT constraints and are the ones the tool will offer.
Install
Install the Quality Patches Tool with composer require magento/quality-patches, apply the prerequisites listed for all files applicable to your distribution and version first, then run vendor/bin/magento-patches apply MDVA-40134. On Cloud, add MDVA-40134 under stage.build.QUALITY_PATCHES in .magento.env.yaml.
For cweagans/composer-patches, choose a compatible version below and download the bundle. Copy its MDVA-40134/ folder into patches/composer/, merge composer.patches.json into composer.json, then run composer install. Bundle prerequisites the same way and list them first. Paths are relative to each package root, using the default -p1 level. Prefer local files when configuring composer-patches; a remote URL can change.
Patch files and compatible versions
magento/magento2-ee-base >=2.4.2 <2.4.3
- Magento Open Source
- —
- vendor/magento/module-catalog-permissions-graph-ql/Model/Store/StoreProcessor.php
