1

I'm using Apigility on ZF2 and I have a Doctrine-connected service and I want to send a custom field that doesn't exist in the table the service is connected to.

For example, I'm uploading an image to the API, and storing the necessary data to the table and uploading the image to a CDN. I would then want to return the CDN-generated URL to the consumer along with the entity. Unfortunately, I am not able to store the URL in the table as the URL is generated per request.

What would be the best way to solve this?

PC NV
  • 11
  • 2
  • In this case you may want to consider extending the entity class and add the $url property. Just by implementing getter and setter, you should be allright. – Francesco Panina May 18 '15 at 22:51

0 Answers0