RelationManager Call to undefined method HasMany::getQualifiedRelatedKeyName
Hey,
i do experience issues while implementing a RelationManager for my Filament application that i can not wrap my head around.
I do have a "Container" model that should be able to be related to other Containers - it does have a
I really don't understand why it does try to call
parent_id
column as well as a parent
(BelongsTo) & children
(HasMany) relationship.
However, when i try to "put one Container into the other" by attaching it, i do get the following exception: https://flareapp.io/share/LPdKbvdm#contextI really don't understand why it does try to call
getQualifiedRelatedKeyName
as this method has been removed from the Relation implementation in Laravel 5.5.
This is how i have defined the relationship column in my migration:
This is how i have implemented the relationships on the Container
Model:
This is how i have implemented the RelationManager:
Does anyone have an idea on what i am doing wrong? I do appreciate any help π
Thank youFlare
Call to undefined method Illuminate\Database\Eloquent\Relations\HasMany::getQualifiedRelatedKeyName() - The error occurred at http://localhost/app/containers/1/edit
Solution:Jump to solution
Ok, nevermind - i have to use the AssociateAction instead of the AttachAction π
1 Reply
Solution
Ok, nevermind - i have to use the AssociateAction instead of the AttachAction π