@extends('layouts.app') @section('header',$title) @section('content')
<div class="row"><h1>{{$title}}</h1></div><div class="panel"><table><tr>@foreach($columns as $c)<th>{{ucwords(str_replace('_',' ',$c))}}</th>@endforeach</tr>@forelse($items as $item)<tr>@foreach($columns as $c)<td>{{data_get($item,$c)}}</td>@endforeach</tr>@empty<tr><td colspan="{{count($columns)}}">No records yet.</td></tr>@endforelse</table>{{$items->links()}}</div>@endsection
