fixed admin route prefix problem and invalid validations

This commit is contained in:
Nabeel Shahzad
2017-06-11 15:37:57 -05:00
parent 8e6313492b
commit 38d8371e0b
13 changed files with 98 additions and 59 deletions

View File

@@ -1,6 +1,6 @@
<!-- ICAO Field -->
<div class="form-group col-sm-6">
{!! Form::label('icao', 'ICAO:') !!}
{!! Form::label('icao', 'ICAO:') !!} (<a class="small" href="https://www.icao.int/publications/DOC8643/Pages/Search.aspx" target="_blank">find</a>)
{!! Form::text('icao', null, ['class' => 'form-control']) !!}
</div>
@@ -10,24 +10,24 @@
{!! Form::text('name', null, ['class' => 'form-control']) !!}
</div>
<!-- Full Name Field -->
<div class="form-group col-sm-6">
{!! Form::label('full_name', 'Full Name:') !!}
{!! Form::text('full_name', null, ['class' => 'form-control']) !!}
</div>
<!-- Registration Field -->
<div class="form-group col-sm-6">
{!! Form::label('registration', 'Registration:') !!}
{!! Form::text('registration', null, ['class' => 'form-control']) !!}
</div>
<!-- Tail Number Field -->
<div class="form-group col-sm-6">
{!! Form::label('tail_number', 'Tail Number:') !!}
{!! Form::text('tail_number', null, ['class' => 'form-control']) !!}
</div>
<!-- Active Field -->
<div class="form-group col-sm-6">
{!! Form::label('active', 'Active:') !!}
<label class="checkbox-inline">
{!! Form::hidden('active', false) !!}
{!! Form::checkbox('active', '1', null) !!} 1
{!! Form::checkbox('active', '1', true) !!}
</label>
</div>

View File

@@ -1,47 +1,35 @@
<!-- Id Field -->
<div class="form-group">
{!! Form::label('id', 'ID:') !!}
<p>{!! $aircraft->id !!}</p>
</div>
<!-- Icao Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('icao', 'ICAO:') !!}
<p>{!! $aircraft->icao !!}</p>
</div>
<!-- Name Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('name', 'Name:') !!}
<p>{!! $aircraft->name !!}</p>
</div>
<!-- Full Name Field -->
<div class="form-group">
{!! Form::label('full_name', 'Full Name:') !!}
<p>{!! $aircraft->full_name !!}</p>
</div>
<!-- Registration Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('registration', 'Registration:') !!}
<p>{!! $aircraft->registration !!}</p>
</div>
<!-- Active Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('active', 'Active:') !!}
<p>{!! $aircraft->active !!}</p>
</div>
<!-- Created At Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('created_at', 'Created At:') !!}
<p>{!! $aircraft->created_at !!}</p>
</div>
<!-- Updated At Field -->
<div class="form-group">
<div class="form-group col-sm-6">
{!! Form::label('updated_at', 'Updated At:') !!}
<p>{!! $aircraft->updated_at !!}</p>
</div>

View File

@@ -9,7 +9,7 @@
<tbody>
@foreach($aircraft as $ac)
<tr>
<td>{!! $ac->icao !!}</td>
<td><a href="{!! route('admin.aircraft.show', [$ac->id]) !!}">{!! $ac->icao !!}</a></td>
<td>{!! $ac->name !!}</td>
<td>{!! $ac->registration !!}</td>
<td>{!! $ac->active !!}</td>