Answer the question
In order to leave comments, you need to log in
How to create a join table with laravel extra column?
There are two tables: categories, attributes. Each category has several attributes. The category_attribute table is intended to be a link table. Laravel allows you to get attributes that belong to a category and categories that have an attribute. You must set each of the attributes to a specific value for each category. For example, the "description" attribute will be different for each category.
To solve this problem, I want to add a value column to the category_attribute spanning table in addition to the identity columns, which will store the attribute values for the categories. The question is this. How to get all attributes of a category and get the values of those attributes? If the idea with the connecting table is wrong, then tell me in which direction to move.
Thank you.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question