Skip to content

Attachment endpoints - #105

Closed
Codencode wants to merge 2 commits into
PrestaShop:devfrom
Codencode:attachment-endpoints
Closed

Codencode wants to merge 2 commits into
PrestaShop:devfrom
Codencode:attachment-endpoints

Conversation

@Codencode

@Codencode Codencode commented Nov 10, 2025 •

Copy link
Copy Markdown
Member
Questions Answers
Description?
Type? improvement
BC breaks? no
Deprecations? no
Fixed ticket?
Sponsor company Condencode
How to test?

IMPORTANT NOTE

This PR is affected by the same issue as ps_apiresources#82

This PR needs these PRs to work:

The integration tests failures are due to the absence of PR PrestaShop/PrestaShop#39966.

@boherm

boherm commented Apr 21, 2026

Copy link
Copy Markdown
Member

Hi @Codencode!
Is this PR still blocked by core? 🤔

@Codencode

Copy link
Copy Markdown
Member Author

Hi @boherm,
I think so, because in my opinion making this work required a core change. That’s why I opened this PR: PrestaShop/PrestaShop#39966

In this comment (PrestaShop/PrestaShop#39966 (comment)) I asked for feedback, but I didn’t receive any response.

Later, after the release of version 9.1.1, rebasing became necessary. I can do that, but before proceeding I’d prefer to understand whether this PR is actually needed or whether there is an alternative way to make it work.

@boherm

boherm commented Apr 21, 2026 •

Copy link
Copy Markdown
Member

Hum, after checking your PR, I think that you can reopened it for 9.1.x 🤔
The main problem that I see:
This ps_apiresource module need to be working from 9.0 to develop and if we fix this for 9.1 we made attachment endpoints nonfunctional with 9.0. BUT, we can only push security fixes in 9.0 but not this kind of fix... 🤔

(As we have a lot of notifications, we can't see all PRs 😭)

@Codencode

Copy link
Copy Markdown
Member Author

@boherm

Hum, after checking your PR, I think that you can reopened it for 9.1.x 🤔
The main problem that I see:
This ps_apiresource module need to be working from 9.0 to develop and if we fix this for 9.1 we made attachment endpoints nonfunctional with 9.0. BUT, we can only push security fixes in 9.0 but not this kind of fix... 🤔

So how should we proceed?
In your opinion, is there no alternative to the PR in the core?
I remember that when I implemented this PR, I didn't find any alternatives.

(As we have a lot of notifications, we can't see all PRs 😭)

Don't worry, I imagine it's not a concern for you!

boo-code pushed a commit to boo-code/ps_apiresources that referenced this pull request Jun 29, 2026
Complete the attachment Admin API resource with the two operations that
were missing alongside the CRUD endpoints: a paginated list sourced from
the attachment grid, and a bulk-delete endpoint.

These port the AttachmentList and BulkAttachments resources from PrestaShop#105,
adapted to the current conventions (strict types, camelCase fileSize with
ApiResourceMapping, CQRSDelete bulk operation, Count(min:1) validation).
The integration test is extended to cover the list (field and filter
mapping) and bulk-delete (including the empty-payload validation error).

Co-authored-by: Codencode <2463965+Codencode@users.noreply.github.com>
@Codencode Codencode closed this Jun 29, 2026
@Codencode
Codencode deleted the attachment-endpoints branch June 29, 2026 08:41
@github-project-automation github-project-automation Bot moved this from Ready for review to Closed in PR Dashboard Jun 29, 2026
@Codencode

Copy link
Copy Markdown
Member Author

Close in favour of: #295

boo-code pushed a commit to boo-code/ps_apiresources that referenced this pull request Oct 29, 2026
Complete the attachment Admin API resource with the two operations that
were missing alongside the CRUD endpoints: a paginated list sourced from
the attachment grid, and a bulk-delete endpoint.

These port the AttachmentList and BulkAttachments resources from PrestaShop#105,
adapted to the current conventions (strict types, camelCase fileSize with
ApiResourceMapping, CQRSDelete bulk operation, Count(min:1) validation).
The integration test is extended to cover the list (field and filter
mapping) and bulk-delete (including the empty-payload validation error).

Co-authored-by: Codencode <2463965+Codencode@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants