2018-02-25 05:38:25 +08:00
|
|
|
<table class="table table-responsive table-hover" id="flight-fields-table">
|
2020-02-02 02:05:56 +08:00
|
|
|
@if(count($pirep->fields))
|
2017-07-14 11:09:38 +08:00
|
|
|
<thead>
|
2018-02-25 05:38:25 +08:00
|
|
|
<th></th>
|
2017-07-14 11:09:38 +08:00
|
|
|
<th>Value</th>
|
|
|
|
<th>Source</th>
|
|
|
|
</thead>
|
2020-02-02 02:05:56 +08:00
|
|
|
@endif
|
|
|
|
<tbody>
|
|
|
|
@foreach($pirep->fields as $field)
|
|
|
|
<tr>
|
|
|
|
<td>
|
|
|
|
{{ $field->name }}
|
|
|
|
@if($field->required === true)
|
|
|
|
<span class="text-danger">*</span>
|
|
|
|
@endif
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<div class="form-group">
|
|
|
|
@if(!$field->read_only)
|
|
|
|
{{ Form::text($field->slug, $field->value, [
|
|
|
|
'class' => 'form-control'
|
|
|
|
]) }}
|
|
|
|
@else
|
|
|
|
<p>{{ $field->value }}</p>
|
|
|
|
@endif
|
|
|
|
</div>
|
|
|
|
<p class="text-danger">{{ $errors->first($field->slug) }}</p>
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
{{ PirepSource::label($field->source) }}
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
2017-07-14 11:09:38 +08:00
|
|
|
</table>
|