core icon indicating copy to clipboard operation
core copied to clipboard

feat: add context parameter to document metadata

Open darthf1 opened this issue 3 years ago • 0 comments

Q A
Branch? main
Tickets https://github.com/api-platform/core/pull/4720#issuecomment-1157502265
License MIT
Doc PR Pending

See comment. This PR is to get the ball rolling, I guess a BC layer must be provided.

I need additional business logic to return the correct DocumentMetadata (the index name is dynamic based on business logic). Besides the context the Operation $operation could be passed as well.

But I'm not sure whether you want to continue this way or remove the DocumentMetadata in favor of extending the ApiPlatform\Metadata\Operation in ApiPlatform\Elasticsearch\Metadata\Operation (as mentioned here by @soyuka)

darthf1 avatar Jun 16 '22 11:06 darthf1