Updated symfony in composer.json, but I get an error when trying to install a...
I upgrade Symfony to the 5.0 version.When I run the server, all is right. However, when I use composer (example composer remove tattali/calendar-bundle), I get these errors :...
View ArticleLoggin Symfony 4 with doctrine inheritance
I have multiple users types in my application which all inherit from their superclass named User.So I have : User > employee, customer, admin... Informations like password, name, nickame.. are in...
View ArticleSymfony HttpClient GET request with multiple query string parameters with...
I am trying to make an API request in the following format:/api/v1/courses?enrollment_state=active&include[]=total_students&include[]=term How can I do so using the HttpClient Component query...
View ArticleReusing Symfony's HTTP Client results in error, but executing the request...
My system needs to authenticate with an external service (out of my control in any way), and the authentication requires two HTTP requests in very short sequence (the token I get in the first request...
View ArticleHow to validate array of arrays in Symfony 4
I want to know how can I validate array of arrays in symfony. My validation rules are:User - NotBlankDate - Date and NotBlank Present - NotBlankSo far I have done this:$validator =...
View ArticleMapping multiple entities under a single field
Is there a way to have a single field in an entity tied to multiple different entities?I have a "Task" entity which can be associated with either the Customer entity or Supplier entity (never both)....
View Articlesonata group role by entity category in sonata admin without ACL in symfony 4
Here is my code. ->add('name') ->add('roles', SecurityRolesType::class, [ 'expanded' => true, 'multiple' => true, 'required' => false, ]) This is my present roles view. click hereBut I...
View ArticleHow to update OneToMany ressource
I am a beginner in API platform. I am working with two entities Author and Book with a OneToMany relationship: a user can have several books a book can belong to only one Author.I've tried POST, GET...
View ArticleIs there a solution for override a ReflectionMethod function in Symfony 4?
I created a custom annotation system to manage the cache with symfony 4, I implemented the annotations and I got their values, but I want to know if I can redefine a ReflectionMethod function to do...
View Articlewebpack encore and jquery ui (dateRangeSlider)
I'm having trouble integrating a jquery-ui plugin with my Symfony app using Webpack Encore. You can see the error (TypeError: t(...).dateRangeSlider is not a function[Learn More]) in the...
View ArticleCross-Origin Request Blocked on Firefox with two domains
I have 2 Frontends, company.com and product-of-company.com. Both with VueJS/Nuxt/Axios and one Symfony 4 Backend with API Platform (comes with Nelmio Cors). In Chrome, everything works fine, but in...
View ArticleWarning: strpos() expects parameter 1 to be string, object given when calling...
Just passing the class name to getRepository() method/** * @Rest\Route("/batches", name="isbn_list_batches", methods={"GET"}) * @Rest\QueryParam(name="page", default=1, requirements="\d+") *...
View ArticleLiip imagine bundle problems with resizing
My error that I get when I run the command php bin/console liip:imagine:cache:resolve public/images/5e57925688ede894214180.png --filter=thumbnail is `public/images/5e57925688ede894214180.png[thumbnail]...
View ArticleHow to setup Nightwatch.js with Symfony and VueJS?
I use Symfony 4 together with VueJS. In src/Controller I have HomeController.php which renders templates/home/index.html.twig. Inside this template I call the VueJS application:{% extends...
View ArticleSymfony 4 (Doctrine 2.7) Joined inheritance
I would like to split users per domain basis in my Symfony project.My Classes so far:<?php namespace App\Entity; use Doctrine\ORM\Mapping as ORM; /** * @ORM\Entity */ class Domain { /** * @ORM\Id *...
View ArticleSymfony SwiftMailer: not sending if the controller does not return a...
I have a Symfony project which (very simplified) looks like this:Controller/MyToolController.phpnamespace App\Controller; use App\Services\ToolsService; use...
View Articlesymfony 4 issues when i install vish uploader vundle
Hello to you all the programmer!2 days ago that I have been trying with this command in symfony 4 composer require vich / uploader-bundle,to be able to download images for my project, but it seemed...
View ArticleHow to best run Symfony Messenger Worker on Kubernetes
What's the best way to run the messenger:consume task on Kubernetes?Deployment?If we do it with a deployment with a certain number of replicas this could work, but what if we do a rolling update of the...
View ArticleSymfony 4 / Webpack Encore - Recover and apply CSS style dynamically from the...
I am currently developing a Symfony 4 application for a client. I obviously use Webpack Encore for asset management. But I find myself exposed to a problem. For the needs of the client it should be...
View ArticleSymfony 4.1: How to use Dependency Injection in UnitTest (Swift_Mailer)
In my Symfony4.1-project i am trying to test a method, which should send mails using SwiftMailer, via a unit test.My test class looks like thisnamespace App\Tests; use...
View Article