Multiple Select with BelongsToMany relationship
I'm just recently using Filamentphp and need to get into the mindset of how it works.
I have two sql tables:
Article
Article_pivot_games
In article_pivot_games I have the columns:
in the model Article.php
However, how do I tell the select to use that function? Also am I using the right method?
Before filamentphp I used a custom admin of my own, in which I had a column in Article with the id_games column containing "1,6,123,532," and I used this:
I have two sql tables:
Article
Article_pivot_games
In article_pivot_games I have the columns:
- id
-article_id
-games_id
in the model Article.php
However, how do I tell the select to use that function? Also am I using the right method?
Before filamentphp I used a custom admin of my own, in which I had a column in Article with the id_games column containing "1,6,123,532," and I used this: