Skip to content

Add Product associated-suppliers read endpoint - #286

Closed
PrestaEdit wants to merge 1 commit into
PrestaShop:devfrom
PrestaEdit:add-product-associated-suppliers
Closed

PrestaEdit wants to merge 1 commit into
PrestaShop:devfrom
PrestaEdit:add-product-associated-suppliers

Conversation

@PrestaEdit

Copy link
Copy Markdown
Contributor
Questions Answers
Description? Add the Product associated-suppliers read endpoint
Type? new feature
BC breaks? no
Deprecations? no
Fixed ticket? Related to PrestaShop/PrestaShop#39630
Sponsor company

Adds GET /products/{productId}/associated-suppliers — GetAssociatedSuppliers: returns the
product's default supplier id and the list of associated supplier ids. Companion read to the suppliers
association endpoints.

The integration test seeds an association and reads it back. Reuses the product_read scope.

Note: the (8.1, develop) integration job currently fails on an unrelated pre-existing warning
(EditOrderMessageHandler foreach, fixed by #284 / core PrestaShop/PrestaShop#41790), not on this
endpoint.

GET /products/{productId}/associated-suppliers (GetAssociatedSuppliers) returns the product's default
supplier id and the list of associated supplier ids. Companion read to the suppliers association
endpoints. The integration test seeds an association and reads it back.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@jolelievre

Copy link
Copy Markdown
Contributor

Closing without integrating: GetAssociatedSuppliers only returns supplier ids, which are already included in the response of GET /products/{productId}/suppliers (GetProductSupplierOptions) introduced by #410, the PR that centralizes all the pending Product-domain endpoints. It is now listed in GenerateApiTrackingTableCommand::EXCLUDED_CQRS_CLASSES so it is excluded from the tracking table and won't be picked up again. @PrestaEdit thanks for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants