2017-06-29 08:54:05 +08:00
|
|
|
<table class="table table-responsive" id="pireps-table">
|
|
|
|
<thead>
|
2017-07-03 10:25:48 +08:00
|
|
|
<th>Pilot</th>
|
|
|
|
<th>Flight</th>
|
|
|
|
<th>Aircraft</th>
|
2017-06-29 08:54:05 +08:00
|
|
|
<th>Flight Time</th>
|
|
|
|
<th>Level</th>
|
2017-07-14 11:09:38 +08:00
|
|
|
<th colspan="3" style="text-align: right">Action</th>
|
2017-06-29 08:54:05 +08:00
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach($pireps as $pirep)
|
|
|
|
<tr>
|
2017-07-03 10:25:48 +08:00
|
|
|
<td>{!! $pirep->user->name !!}</td>
|
|
|
|
<td>
|
|
|
|
@if($pirep->flight)
|
|
|
|
<a href="{!! route('admin.flights.show', ['id' => $pirep->flight_id]) !!}">
|
|
|
|
{!! $pirep->flight->airline->code !!}{!! $pirep->flight->flight_number !!}
|
|
|
|
</a>
|
|
|
|
@else
|
|
|
|
-
|
|
|
|
@endif
|
|
|
|
</td>
|
|
|
|
<td>{!! $pirep->aircraft->registration !!} ({!! $pirep->aircraft->name !!})</td>
|
|
|
|
<td>{!! Utils::secondsToTime($pirep->flight_time) !!}</td>
|
2017-06-29 08:54:05 +08:00
|
|
|
<td>{!! $pirep->level !!}</td>
|
2017-07-14 11:09:38 +08:00
|
|
|
<td style="text-align: right;">
|
2017-06-29 08:54:05 +08:00
|
|
|
{!! Form::open(['route' => ['admin.pireps.destroy', $pirep->id], 'method' => 'delete']) !!}
|
|
|
|
<div class='btn-group'>
|
|
|
|
<a href="{!! route('admin.pireps.show', [$pirep->id]) !!}" class='btn btn-default btn-xs'><i class="glyphicon glyphicon-eye-open"></i></a>
|
|
|
|
<a href="{!! route('admin.pireps.edit', [$pirep->id]) !!}" class='btn btn-default btn-xs'><i class="glyphicon glyphicon-edit"></i></a>
|
|
|
|
{!! Form::button('<i class="glyphicon glyphicon-trash"></i>', ['type' => 'submit', 'class' => 'btn btn-danger btn-xs', 'onclick' => "return confirm('Are you sure?')"]) !!}
|
|
|
|
</div>
|
|
|
|
{!! Form::close() !!}
|
|
|
|
</td>
|
|
|
|
</tr>
|
2017-07-03 10:25:48 +08:00
|
|
|
@if($pirep->notes)
|
|
|
|
<tr>
|
|
|
|
<td> </td>
|
|
|
|
<td colspan="8"><strong>Notes:</strong> {!! $pirep->notes !!}</td>
|
|
|
|
</tr>
|
|
|
|
@endif
|
2017-06-29 08:54:05 +08:00
|
|
|
@endforeach
|
|
|
|
</tbody>
|
|
|
|
</table>
|