I'm new on this site and also new to Laravel. I have 3 tables.
1) Product Table (column: id, product_name)
2) Purchase Table (Column: id, purchase_date)
3) Purchase Items (Colunn: id, purchase_id, product_id);
Releationships
I have oneToMany Relationship Between Purchase & PurchaseItem Model, and oneToMany relationship between Product & PurchaseItem.
My Problem
In my Purchase Model I'm getting purchaseItems Data easily as I have relationship between them. But I want to get Product Data also (Like: product_name) in Purchase Model. How can I get it? any idea?