diff --git a/composer.json b/composer.json index 1354ec110fcc1..5eaf4d7c37ae9 100644 --- a/composer.json +++ b/composer.json @@ -71,7 +71,7 @@ "prestashop/gsitemap": "^4", "prestashop/pagesnotfound": "^2", "prestashop/productcomments": "^6.0", - "prestashop/ps_apiresources": "dev-admin-api-renaming", + "prestashop/ps_apiresources": "dev-Issue-35687-command-on-single-shops-that-expects-shopids", "prestashop/ps_banner": "^2", "prestashop/ps_bestsellers": "^1.0", "prestashop/ps_brandlist": "^1.0", @@ -254,7 +254,7 @@ "repositories": { "ps_apiresources": { "type": "vcs", - "url": "https://github.com/jolelievre/ps_apiresources.git" + "url": "https://github.com/tleon/ps_apiresources.git" } }, "minimum-stability": "dev", diff --git a/composer.lock b/composer.lock index 68d2d73b0fb39..986589e4acdce 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "80be213164c5e7dcc619167a1b9f5121", + "content-hash": "3b161cf4a13fd7f6b9271bb6d0e26b8f", "packages": [ { "name": "api-platform/core", @@ -5579,16 +5579,16 @@ }, { "name": "prestashop/ps_apiresources", - "version": "dev-admin-api-renaming", + "version": "dev-Issue-35687-command-on-single-shops-that-expects-shopids", "source": { "type": "git", - "url": "https://github.com/jolelievre/ps_apiresources.git", - "reference": "58fe2edad43346d3b923b3b1616af412bf7d9374" + "url": "https://github.com/tleon/ps_apiresources.git", + "reference": "f7586dda75eb7c1d07544b8f0acc3c9c3f5094a9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/jolelievre/ps_apiresources/zipball/58fe2edad43346d3b923b3b1616af412bf7d9374", - "reference": "58fe2edad43346d3b923b3b1616af412bf7d9374", + "url": "https://api.github.com/repos/tleon/ps_apiresources/zipball/f7586dda75eb7c1d07544b8f0acc3c9c3f5094a9", + "reference": "f7586dda75eb7c1d07544b8f0acc3c9c3f5094a9", "shasum": "" }, "require": { @@ -5640,9 +5640,9 @@ "description": "PrestaShop - API Resources", "homepage": "https://github.com/PrestaShop/ps_apiresources", "support": { - "source": "https://github.com/jolelievre/ps_apiresources/tree/admin-api-renaming" + "source": "https://github.com/tleon/ps_apiresources/tree/Issue-35687-command-on-single-shops-that-expects-shopids" }, - "time": "2024-03-29T12:27:52+00:00" + "time": "2024-04-02T15:29:56+00:00" }, { "name": "prestashop/ps_banner", @@ -17989,5 +17989,5 @@ "platform-overrides": { "php": "8.1.0" }, - "plugin-api-version": "2.6.0" + "plugin-api-version": "2.3.0" } diff --git a/src/PrestaShopBundle/ApiPlatform/ContextParametersTrait.php b/src/PrestaShopBundle/ApiPlatform/ContextParametersTrait.php index 48f58979e0884..dd0e446956e32 100644 --- a/src/PrestaShopBundle/ApiPlatform/ContextParametersTrait.php +++ b/src/PrestaShopBundle/ApiPlatform/ContextParametersTrait.php @@ -50,6 +50,7 @@ protected function getContextParameters(): array 'isStrict' => $shopConstraint->isStrict(), ], 'shopId' => $this->shopContext->getId(), + 'shopIds' => $this->shopContext->getAssociatedShopIds(), 'langId' => $this->languageContext->getId(), 'apiClientId' => $this->apiClientContext->getApiClient()?->getId(), ],