id, name
id, name
id, product_id, category_id
id, product_category_id, user, pass
as you can see i have four tables, products has many-to-many relationship with categories and cards has many-to-one relation with products_categories it means cards could belongs to many products_categories
i want to eager loading all categories with their products and also their product's cards, for this to happen should i create model class for products_categories table and what be it's relationships? or use sql query?
what you suggest..
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community