{{-- Write out the custom fields, and label if they're required --}} @foreach($pirepfields as $field) @endforeach
Airline
{!! Form::select('airline_id', $airlines, null, ['class' => 'custom-select select2']) !!}
Flight Number/Code/Leg
{!! Form::text('flight_number', null, ['placeholder' => 'Flight Number', 'class' => 'form-control']) !!} {!! Form::text('route_code', null, ['placeholder' => 'Code (optional)', 'class' => 'form-control']) !!} {!! Form::text('route_leg', null, ['placeholder' => 'Leg (optional)', 'class' => 'form-control']) !!}
Aircraft
{!! Form::select('aircraft_id', $aircraft, null, ['class' => 'custom-select select2']) !!}
Origin Airport
{!! Form::select('dpt_airport_id', $airports, null, ['class' => 'custom-select select2']) !!}
Arrival Airport
{!! Form::select('arr_airport_id', $airports, null, ['class' => 'custom-select select2']) !!}
Flight Time
{!! Form::number('hours', null, ['class' => 'form-control', 'placeholder' => 'hours']) !!} {!! Form::number('minutes', null, ['class' => 'form-control', 'placeholder' => 'minutes']) !!}
Route
{!! Form::textarea('route', null, ['class' => 'form-control', 'placeholder' => 'Route']) !!}
{!! $field->name !!} required
{!! Form::text('field_'.$field->id, null, [ 'class' => 'form-control' ]) !!}

Notes

{!! Form::textarea('notes', null, ['class' => 'form-control', 'placeholder' => 'Notes']) !!}
{!! Form::submit('Submit PIREP', ['class' => 'btn btn-primary']) !!}