You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an issue with my embedded list which is between my classes Intern & Internships which is a ManyToMany relationship.
When an internship has at least one intern, it works fine and we can see it in the embedded list.
However, if my internship has no interns my embedded list shows every intern in my database.
I tried to debug it by looking into the embeddedListAction and I do not know if this is supposed to happen.
When looking at the $paginator variable in embeddedListAction I can see that when I have atleast one intern the query is :
"SELECT entity FROM App\Entity\Intern entity LEFT JOIN entity.person person WHERE entity.id IN (:form_filter_entity_id) ORDER BY entity.id DESC"
But if there are no intern in my internship the query changes to :
"SELECT entity FROM App\Entity\Intern entity ORDER BY entity.id DESC"
Is that an issue with my configuration or does embeddedListAction not support ManyToMany completely ?
The text was updated successfully, but these errors were encountered:
I understand why the WHERE has disappeared, this is limitation of IN operator in query builder. But I don't understand why the LEFT JOIN part is removed too. Did you override something about the list query builder ?
No, there shouldn't be any kind of override on this query. That's why i'm kinda surprised it does that.
I also tried to add an ext_filters: {'entity.internships': 'form:parent.data.id'} but that doesn't seems to work at all. It does not use it.
Hi,
I have an issue with my embedded list which is between my classes Intern & Internships which is a ManyToMany relationship.
When an internship has at least one intern, it works fine and we can see it in the embedded list.
However, if my internship has no interns my embedded list shows every intern in my database.
I tried to debug it by looking into the embeddedListAction and I do not know if this is supposed to happen.
When looking at the $paginator variable in embeddedListAction I can see that when I have atleast one intern the query is :
"SELECT entity FROM App\Entity\Intern entity LEFT JOIN entity.person person WHERE entity.id IN (:form_filter_entity_id) ORDER BY entity.id DESC"
But if there are no intern in my internship the query changes to :
"SELECT entity FROM App\Entity\Intern entity ORDER BY entity.id DESC"
Is that an issue with my configuration or does embeddedListAction not support ManyToMany completely ?
The text was updated successfully, but these errors were encountered: