Month: May 2020

Testing Controllers in Symfony 4.4 while using annotations

I’m facing a problem of testing my Controllers in Symfony 4.4 with FOSRestBundle & JMSSserializer. My controllers are pretty simple, usually containing nothing but call to another services, but I’m using ParamConverter, Serializer, Deserializer etc. I’m never sure if fields…

Single id is not allowed on composite primary key in entity AdminBundleEntityComptable

I created a simple entity with primary key id and when I try to generate my entity, I get this error : [DoctrineORMMappingMappingException] Single id is not allowed on composite primary key in entity AdminBundleEntityComptable Here is the entity that…

Symfony : uploading file, working from Postman, not from Javascript nor cURL

I’m trying to make a request from a Javascript file to an upload file route made with Symfony and API Platform. REQUESTS : With Postman, using the file input under form-data and using the GUI, the upload works (201 response)….