Posts

Showing posts with the label symfony

Transfer data from aprs server to symfony database

Image
Clash Royale CLAN TAG #URR8PPP Transfer data from aprs server to symfony database I would like to connect symfony to an "aprs-is" server. My data are received by the "aprs" server and i would like to insert them in the database i have created in the doctrine of symfony. My entities are ready but i can't figure out how to do that. I can make an up-link on "aprs" server to redirect the data but i don't know how to architect all that link on both side. Here is the link of aprs-is server archi: http://he.fi/aprsc/ By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Symfony 3.4 - Set a many to one API REST

Image
Clash Royale CLAN TAG #URR8PPP Symfony 3.4 - Set a many to one API REST I'm creating an API REST and I want to set for $userInterest an Entity named Category ( many to one ) I did the same thing for the User entity ( and I set the "Profile" entity ), but the Profile entity is passed as parameter and it's created in this function so it's simple and it works. $userInterest Category User Profile I do it like this: /** * * @RestPost( * path = "/users/register", * name = "api_users_add" * ) * @RestView(StatusCode=201, serializerGroups={"user_detail"}) * @ParamConverter( * "user", * converter="fos_rest.request_body", * options={"deserializationContent"={"groups"={"Deserialize"}}}, * ) * @ParamConverter( * "profile", * converter="fos_rest.request_body", * options={"deserializationContent"={"groups"={...

Symfony jms serializer enable when needed

Image
Clash Royale CLAN TAG #URR8PPP Symfony jms serializer enable when needed I have jms serializer and in my class entity have annotation. I have case when I need apply jms serializer annotation only in some case. How to do this ? First I think need move annotation from entity class to uml maybe and create some handler where I can enable this annotation for this entity, in the rest of the time jms are not applicable to entity my entity /** * @AnnotationExclusionPolicy("all") */ class Application implements ContainsRecordedMessages { /** * @var int * * @AnnotationGroups({ * "get_application" * }) * @AnnotationExpose() */ private $id; /** * @var int * * @AnnotationGroups({ * "post_application" * }) * @AnnotationSerializedName("company_id") * @AnnotationExpose() */ private $companyId; /** * @var string * * @AnnotationGroups({ * "post_application" * }) * @AnnotationSerializedName("channel_sale") ...