Found the solution. The problem was that I was trying to access this pivot through order collection. You have to access it through products collection than individual product and than you can do things like this:
$product->pivot->quantity;
Hope it helps someone.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community