Relationship problems? (relationship with where)
Hello,
I have this relationship at my model:
The relationships work very well outside filamentphp (eg at controller and lavarel's blade)
At filamentphp I get an empty string.
If I remove the where statement the relationship returns data (but it is wrong)
This is a Filament bug?
7 Replies
I would install Laravel debugbar and see what SQL queries are executed, then you would trace the reason of that empty string
@povilas_korop thank you for your reply. Seems like the filament has its own logic for relationships.
This is what filament tryies to get from SQL
The two tables are the same (one is a copy of the other) and I just want to test the new logic of auto changing the product price.
I have dumped the
, at relationship, and seems that it is getting two empty product_id's
hello, i also have the same requirement for where conditions on relationship
this is my workaround, note the modifyQueryUsing
@shinra5252 so it looks like a filamentphp bug?
idk if its bug or intended, need an insight from the dev
What exactly are you trying to do with that relationship? Show the code where you reference it in your resource.