hmmm, even if using an alias for the joined tables, like
$products = DB::table('products')
->leftJoin('stockstatus as s', 'stockstatus_id', '=', 's.id')
->leftJoin('manufacturers as m', 'manufacturer_id', '=', 'm.id')
->get();
i don't know how to get the individual fields displayed via blade.
no problem if the indivudual field names are different but with the same fieldnames but different tables i'm stuck.
// no individual 'name'
@foreach ($products as $p)
SKU: {{ $p->sku }} - Stock: {{ $p->name }} - Manufacturer: {{ $p->name }} <br>
@endforeach
// doesn't work (error):
@foreach ($products as $p)
SKU: {{ $p->sku }} - Stock: {{ $p->s.name }} - Manufacturer: {{ $p->m.name }} <br>
@endforeach
Any hints?