Fixing XSS vulnerability by using the proper output tags
This commit is contained in:
@@ -2,34 +2,34 @@
|
||||
<tr>
|
||||
<td>
|
||||
@if($pirep->state === PirepState::PENDING || $pirep->state === PirepState::REJECTED)
|
||||
{!! Form::open(['url' => route('admin.pirep.status', ['id' => $pirep->id]),
|
||||
{{ Form::open(['url' => route('admin.pirep.status', ['id' => $pirep->id]),
|
||||
'method' => 'post',
|
||||
'name' => 'accept_'.$pirep->id,
|
||||
'id' => $pirep->id.'_accept',
|
||||
'pirep_id' => $pirep->id,
|
||||
'new_status' => PirepState::ACCEPTED,
|
||||
'class' => $on_edit_page ? 'pirep_change_status': 'pirep_submit_status']) !!}
|
||||
{!! Form::button('Accept', ['type' => 'submit', 'class' => 'btn btn-success']) !!}
|
||||
{!! Form::close() !!}
|
||||
'class' => $on_edit_page ? 'pirep_change_status': 'pirep_submit_status']) }}
|
||||
{{ Form::button('Accept', ['type' => 'submit', 'class' => 'btn btn-success']) }}
|
||||
{{ Form::close() }}
|
||||
@endif
|
||||
</td>
|
||||
<td> </td>
|
||||
<td>
|
||||
@if($pirep->state === PirepState::PENDING || $pirep->state === PirepState::ACCEPTED)
|
||||
{!! Form::open(['url' => route('admin.pirep.status', ['id' => $pirep->id]),
|
||||
{{ Form::open(['url' => route('admin.pirep.status', ['id' => $pirep->id]),
|
||||
'method' => 'post',
|
||||
'name' => 'reject_'.$pirep->id,
|
||||
'id' => $pirep->id.'_reject',
|
||||
'pirep_id' => $pirep->id,
|
||||
'new_status' => PirepState::REJECTED,
|
||||
'class' => $on_edit_page ? 'pirep_change_status': 'pirep_submit_status']) !!}
|
||||
{!! Form::button('Reject', ['type' => 'submit', 'class' => 'btn btn-danger']) !!}
|
||||
{!! Form::close() !!}
|
||||
'class' => $on_edit_page ? 'pirep_change_status': 'pirep_submit_status']) }}
|
||||
{{ Form::button('Reject', ['type' => 'submit', 'class' => 'btn btn-danger']) }}
|
||||
{{ Form::close() }}
|
||||
@endif
|
||||
</td>
|
||||
<td> </td>
|
||||
<td>
|
||||
<a href="{!! route('admin.pireps.edit', [$pirep->id]) !!}"
|
||||
<a href="{{ route('admin.pireps.edit', [$pirep->id]) }}"
|
||||
class='btn btn-info btn-icon'>
|
||||
<i class="fas fa-pencil-alt"></i> Edit</a>
|
||||
</td>
|
||||
|
||||
@@ -9,23 +9,23 @@
|
||||
@foreach($pirep->comments as $comment)
|
||||
<tr>
|
||||
<td width="1%" nowrap="" style="vertical-align: text-top">
|
||||
<a href="{!! route('admin.users.show', [$comment->user_id]) !!}">
|
||||
{!! $comment->user->name !!}
|
||||
<a href="{{ route('admin.users.show', [$comment->user_id]) }}">
|
||||
{{ $comment->user->name }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{!! $comment->comment !!}</p>
|
||||
<p class="small">{!! show_datetime($comment->created_at) !!}</p>
|
||||
<p>{{ $comment->comment }}</p>
|
||||
<p class="small">{{ show_datetime($comment->created_at) }}</p>
|
||||
</td>
|
||||
<td align="right">
|
||||
{!! Form::open(['url' => url('/admin/pireps/'.$pirep->id.'/comments'),
|
||||
'method' => 'delete', 'class' => 'pjax_form form-inline']) !!}
|
||||
{!! Form::hidden('comment_id', $comment->id) !!}
|
||||
{!! Form::button('<i class="fa fa-times"></i>', ['type' => 'submit',
|
||||
{{ Form::open(['url' => url('/admin/pireps/'.$pirep->id.'/comments'),
|
||||
'method' => 'delete', 'class' => 'pjax_form form-inline']) }}
|
||||
{{ Form::hidden('comment_id', $comment->id) }}
|
||||
{{ Form::button('<i class="fa fa-times"></i>', ['type' => 'submit',
|
||||
'class' => 'btn btn-danger btn-small',
|
||||
'onclick' => "return confirm('Are you sure?')",
|
||||
]) !!}
|
||||
{!! Form::close() !!}
|
||||
]) }}
|
||||
{{ Form::close() }}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@@ -35,12 +35,12 @@
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<div class="text-right">
|
||||
{!! Form::open(['url' => url('/admin/pireps/'.$pirep->id.'/comments'),
|
||||
'method' => 'post', 'class' => 'pjax_form form-inline']) !!}
|
||||
{!! Form::input('text', 'comment', null, ['class' => 'form-control input-sm']) !!}
|
||||
{!! Form::button('<i class="fa fa-plus"></i> Add', ['type' => 'submit',
|
||||
'class' => 'btn btn-success btn-small']) !!}
|
||||
{!! Form::close() !!}
|
||||
{{ Form::open(['url' => url('/admin/pireps/'.$pirep->id.'/comments'),
|
||||
'method' => 'post', 'class' => 'pjax_form form-inline']) }}
|
||||
{{ Form::input('text', 'comment', null, ['class' => 'form-control input-sm']) }}
|
||||
{{ Form::button('<i class="fa fa-plus"></i> Add', ['type' => 'submit',
|
||||
'class' => 'btn btn-success btn-small']) }}
|
||||
{{ Form::close() }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -4,9 +4,9 @@
|
||||
<div class="content">
|
||||
<div class="card border-blue-bottom">
|
||||
<div class="content">
|
||||
{!! Form::open(['route' => 'admin.pireps.store']) !!}
|
||||
{{ Form::open(['route' => 'admin.pireps.store']) }}
|
||||
@include('admin.pireps.fields')
|
||||
{!! Form::close() !!}
|
||||
{{ Form::close() }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<h5 style="margin-top: 0px;">
|
||||
Filed By: <a href="{!! route('admin.users.edit', [$pirep->user_id]) !!}" target="_blank">
|
||||
{!! $pirep->user->pilot_id !!} {!! $pirep->user->name !!}
|
||||
Filed By: <a href="{{ route('admin.users.edit', [$pirep->user_id]) }}" target="_blank">
|
||||
{{ $pirep->user->pilot_id }} {{ $pirep->user->name }}
|
||||
</a>
|
||||
</h5>
|
||||
</div>
|
||||
@@ -22,9 +22,9 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{!! Form::model($pirep, ['route' => ['admin.pireps.update', $pirep->id], 'method' => 'patch']) !!}
|
||||
{{ Form::model($pirep, ['route' => ['admin.pireps.update', $pirep->id], 'method' => 'patch']) }}
|
||||
@include('admin.pireps.fields')
|
||||
{!! Form::close() !!}
|
||||
{{ Form::close() }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
<div class="pull-right">
|
||||
<button id="recalculate-finances"
|
||||
class="btn btn-success"
|
||||
data-pirep-id="{!! $pirep->id !!}">Recalcuate Finances</button>
|
||||
data-pirep-id="{{ $pirep->id }}">Recalcuate Finances</button>
|
||||
</div>
|
||||
<h4>transactions</h4>
|
||||
@include('admin.pireps.transactions')
|
||||
|
||||
@@ -8,17 +8,17 @@
|
||||
<tbody>
|
||||
@foreach($aircraft->subfleet->fares as $fare)
|
||||
<tr>
|
||||
<td>{!! $fare->name !!} ({!! $fare->code !!})</td>
|
||||
<td>{{ $fare->name }} ({{ $fare->code }})</td>
|
||||
<td>
|
||||
<div class="form-group">
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->{'fare_'.$fare->id} !!}</p>
|
||||
{!! Form::hidden('fare_'.$fare->id) !!}
|
||||
<p>{{ $pirep->{'fare_'.$fare->id} }}</p>
|
||||
{{ Form::hidden('fare_'.$fare->id) }}
|
||||
@else
|
||||
{!! Form::number('fare_'.$fare->id, null, [
|
||||
{{ Form::number('fare_'.$fare->id, null, [
|
||||
'class' => 'form-control',
|
||||
'min' => 0,
|
||||
'readonly' => $read_only]) !!}
|
||||
'readonly' => $read_only]) }}
|
||||
@endif
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -8,21 +8,21 @@
|
||||
@foreach($pirep->fields as $field)
|
||||
<tr>
|
||||
<td>
|
||||
{!! $field->name !!}
|
||||
{{ $field->name }}
|
||||
@if($field->required === true)
|
||||
<span class="text-danger">*</span>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<div class="form-group">
|
||||
{!! Form::text($field->slug, null, [
|
||||
{{ Form::text($field->slug, null, [
|
||||
'class' => 'form-control'
|
||||
]) !!}
|
||||
]) }}
|
||||
</div>
|
||||
<p class="text-danger">{{ $errors->first($field->slug) }}</p>
|
||||
</td>
|
||||
<td>
|
||||
{!! PirepSource::label($field->source) !!}
|
||||
{{ PirepSource::label($field->source) }}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
@@ -9,31 +9,31 @@
|
||||
@endif
|
||||
<div class="row">
|
||||
<div class="form-group col-sm-6">
|
||||
{!! Form::label('flight_number', 'Flight Number/Route Code/Leg') !!}
|
||||
{{ Form::label('flight_number', 'Flight Number/Route Code/Leg') }}
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->ident !!}
|
||||
{!! Form::hidden('flight_number') !!}
|
||||
{!! Form::hidden('flight_code') !!}
|
||||
{!! Form::hidden('flight_leg') !!}
|
||||
<p>{{ $pirep->ident }}
|
||||
{{ Form::hidden('flight_number') }}
|
||||
{{ Form::hidden('flight_code') }}
|
||||
{{ Form::hidden('flight_leg') }}
|
||||
</p>
|
||||
@else
|
||||
<div class="row">
|
||||
<div class="col-sm-4">
|
||||
{!! Form::text('flight_number', null, [
|
||||
{{ Form::text('flight_number', null, [
|
||||
'placeholder' => 'Flight Number',
|
||||
'class' => 'form-control']) !!}
|
||||
'class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('flight_number') }}</p>
|
||||
</div>
|
||||
<div class="col-sm-4">
|
||||
{!! Form::text('route_code', null, [
|
||||
{{ Form::text('route_code', null, [
|
||||
'placeholder' => 'Code (optional)',
|
||||
'class' => 'form-control']) !!}
|
||||
'class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('route_code') }}</p>
|
||||
</div>
|
||||
<div class="col-sm-4">
|
||||
{!! Form::text('route_leg', null, [
|
||||
{{ Form::text('route_leg', null, [
|
||||
'placeholder' => 'Leg (optional)',
|
||||
'class' => 'form-control']) !!}
|
||||
'class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('route_leg') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -41,59 +41,59 @@
|
||||
</div>
|
||||
<div class="form-group col-sm-6">
|
||||
<p class="description">Filed Via:</p>
|
||||
{!! PirepSource::label($pirep->source) !!}
|
||||
{{ PirepSource::label($pirep->source) }}
|
||||
@if(filled($pirep->source_name))
|
||||
({!! $pirep->source_name !!})
|
||||
({{ $pirep->source_name }})
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-sm-3">
|
||||
{!! Form::label('airline_id', 'Airline') !!}
|
||||
{{ Form::label('airline_id', 'Airline') }}
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->airline->name !!}</p>
|
||||
{!! Form::hidden('airline_id') !!}
|
||||
<p>{{ $pirep->airline->name }}</p>
|
||||
{{ Form::hidden('airline_id') }}
|
||||
@else
|
||||
{!! Form::select('airline_id', $airlines_list, null, [
|
||||
{{ Form::select('airline_id', $airlines_list, null, [
|
||||
'class' => 'form-control select2',
|
||||
'readonly' => $read_only]) !!}
|
||||
'readonly' => $read_only]) }}
|
||||
<p class="text-danger">{{ $errors->first('airline_id') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
<div class="form-group col-sm-3">
|
||||
{!! Form::label('aircraft_id', 'Aircraft:') !!}
|
||||
{{ Form::label('aircraft_id', 'Aircraft:') }}
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->aircraft->name !!}</p>
|
||||
{!! Form::hidden('aircraft_id') !!}
|
||||
<p>{{ $pirep->aircraft->name }}</p>
|
||||
{{ Form::hidden('aircraft_id') }}
|
||||
@else
|
||||
{!! Form::select('aircraft_id', $aircraft_list, null, [
|
||||
{{ Form::select('aircraft_id', $aircraft_list, null, [
|
||||
'id' => 'aircraft_select',
|
||||
'class' => 'form-control select2',
|
||||
'readonly' => $read_only
|
||||
]) !!}
|
||||
]) }}
|
||||
<p class="text-danger">{{ $errors->first('aircraft_id') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
<div class="form-group col-sm-3">
|
||||
{!! Form::label('dpt_airport_id', 'Departure Airport:') !!}
|
||||
{{ Form::label('dpt_airport_id', 'Departure Airport:') }}
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->dpt_airport->id !!} - {!! $pirep->dpt_airport->name !!}</p>
|
||||
{!! Form::hidden('dpt_airport_id') !!}
|
||||
<p>{{ $pirep->dpt_airport->id }} - {{ $pirep->dpt_airport->name }}</p>
|
||||
{{ Form::hidden('dpt_airport_id') }}
|
||||
@else
|
||||
{!! Form::select('dpt_airport_id', $airports_list, null, [
|
||||
{{ Form::select('dpt_airport_id', $airports_list, null, [
|
||||
'class' => 'form-control select2',
|
||||
'readonly' => $read_only]) !!}
|
||||
'readonly' => $read_only]) }}
|
||||
<p class="text-danger">{{ $errors->first('dpt_airport_id') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="form-group col-sm-3">
|
||||
{!! Form::label('arr_airport_id', 'Arrival Airport:') !!}
|
||||
{{ Form::label('arr_airport_id', 'Arrival Airport:') }}
|
||||
@if($read_only)
|
||||
<p>{!! $pirep->arr_airport->id !!} - {!! $pirep->arr_airport->name !!}</p>
|
||||
{!! Form::hidden('arr_airport_id') !!}
|
||||
<p>{{ $pirep->arr_airport->id }} - {{ $pirep->arr_airport->name }}</p>
|
||||
{{ Form::hidden('arr_airport_id') }}
|
||||
@else
|
||||
{!! Form::select('arr_airport_id', $airports_list, null, ['class' => 'form-control select2']) !!}
|
||||
{{ Form::select('arr_airport_id', $airports_list, null, ['class' => 'form-control select2']) }}
|
||||
<p class="text-danger">{{ $errors->first('arr_airport_id') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
@@ -101,26 +101,26 @@
|
||||
<div class="row">
|
||||
<!-- Flight Time Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
{!! Form::label('flight_time', 'Flight Time (hours & minutes):') !!}
|
||||
{{ Form::label('flight_time', 'Flight Time (hours & minutes):') }}
|
||||
@if($read_only)
|
||||
<p>
|
||||
{!! $pirep->hours !!} hours, {!! $pirep->minutes !!} minutes
|
||||
{!! Form::hidden('hours') !!}
|
||||
{!! Form::hidden('minutes') !!}
|
||||
{{ $pirep->hours }} hours, {{ $pirep->minutes }} minutes
|
||||
{{ Form::hidden('hours') }}
|
||||
{{ Form::hidden('minutes') }}
|
||||
</p>
|
||||
@else
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
{!! Form::number('hours', null, [
|
||||
{{ Form::number('hours', null, [
|
||||
'class' => 'form-control',
|
||||
'placeholder' => 'hours',
|
||||
'readonly' => $read_only]) !!}
|
||||
'readonly' => $read_only]) }}
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
{!! Form::number('minutes', null, [
|
||||
{{ Form::number('minutes', null, [
|
||||
'class' => 'form-control',
|
||||
'placeholder' => 'minutes',
|
||||
'readonly' => $read_only]) !!}
|
||||
'readonly' => $read_only]) }}
|
||||
</div>
|
||||
<p class="text-danger">{{ $errors->first('hours') }}</p>
|
||||
<p class="text-danger">{{ $errors->first('minutes') }}</p>
|
||||
@@ -130,10 +130,10 @@
|
||||
|
||||
<!-- Level Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
{!! Form::label('level', 'Flight Level:') !!}
|
||||
{{ Form::label('level', 'Flight Level:') }}
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
{!! Form::number('level', null, ['class' => 'form-control', 'min' => 0]) !!}
|
||||
{{ Form::number('level', null, ['class' => 'form-control', 'min' => 0]) }}
|
||||
<p class="text-danger">{{ $errors->first('level') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -142,15 +142,15 @@
|
||||
<div class="row">
|
||||
<!-- Route Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
{!! Form::label('route', 'Route:') !!}
|
||||
{!! Form::textarea('route', null, ['class' => 'form-control']) !!}
|
||||
{{ Form::label('route', 'Route:') }}
|
||||
{{ Form::textarea('route', null, ['class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('route') }}</p>
|
||||
</div>
|
||||
|
||||
<!-- Notes Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
{!! Form::label('notes', 'Notes:') !!}
|
||||
{!! Form::textarea('notes', null, ['class' => 'form-control']) !!}
|
||||
{{ Form::label('notes', 'Notes:') }}
|
||||
{{ Form::textarea('notes', null, ['class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('notes') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -185,8 +185,8 @@
|
||||
<div class="row">
|
||||
<div class="form-group col-sm-12">
|
||||
<div class="pull-right">
|
||||
{!! Form::button('Save', ['type' => 'submit', 'class' => 'btn btn-success']) !!}
|
||||
<a href="{!! route('admin.pireps.index') !!}" class="btn btn-warn">Cancel</a>
|
||||
{{ Form::button('Save', ['type' => 'submit', 'class' => 'btn btn-success']) }}
|
||||
<a href="{{ route('admin.pireps.index') }}" class="btn btn-warn">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
<tbody>
|
||||
@foreach($pirep->acars_logs as $log)
|
||||
<tr>
|
||||
<td nowrap="true">{!! show_datetime($log->created_at) !!}</td>
|
||||
<td>{!! $log->log !!}</td>
|
||||
<td nowrap="true">{{ show_datetime($log->created_at) }}</td>
|
||||
<td>{{ $log->log }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
@section('title', 'Pilot Reports')
|
||||
@section('actions')
|
||||
<li><a href="{!! route('admin.pirepfields.index') !!}"><i class="ti-menu-alt"></i>PIREP Fields</a></li>
|
||||
<li><a href="{!! route('admin.pireps.index') !!}?search=status:0"><i class="ti-plus"></i>Pending</a></li>
|
||||
<li><a href="{!! route('admin.pireps.index') !!}"><i class="ti-plus"></i>View All</a></li>
|
||||
<li><a href="{{ route('admin.pirepfields.index') }}"><i class="ti-menu-alt"></i>PIREP Fields</a></li>
|
||||
<li><a href="{{ route('admin.pireps.index') }}?search=status:0"><i class="ti-plus"></i>Pending</a></li>
|
||||
<li><a href="{{ route('admin.pireps.index') }}"><i class="ti-plus"></i>View All</a></li>
|
||||
@endsection
|
||||
@section('content')
|
||||
@include('admin.pireps.table')
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<div id="pirep_{!! $pirep->id !!}_container">
|
||||
<div id="pirep_{{ $pirep->id }}_container">
|
||||
<div class="card border-blue-bottom pirep_card_container">
|
||||
<div class="card-block" style="min-height: 0px">
|
||||
<div class="row">
|
||||
<div class="col-sm-2 text-center">
|
||||
<h5>
|
||||
<a class="text-c"
|
||||
href="{!! route('admin.pireps.edit', [$pirep->id]) !!}">
|
||||
{!! $pirep->ident !!}
|
||||
href="{{ route('admin.pireps.edit', [$pirep->id]) }}">
|
||||
{{ $pirep->ident }}
|
||||
</a>
|
||||
</h5>
|
||||
<div>
|
||||
@@ -19,7 +19,7 @@
|
||||
@else
|
||||
<div class="badge badge-info">
|
||||
@endif
|
||||
{!! PirepState::label($pirep->state) !!}</div>
|
||||
{{ PirepState::label($pirep->state) }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-10">
|
||||
@@ -28,39 +28,39 @@
|
||||
<div>
|
||||
<span class="description">
|
||||
<b>DEP</b>
|
||||
{!! $pirep->dpt_airport->icao !!}
|
||||
{{ $pirep->dpt_airport->icao }}
|
||||
<b>ARR</b>
|
||||
{!! $pirep->arr_airport->icao !!}
|
||||
{{ $pirep->arr_airport->icao }}
|
||||
</span>
|
||||
</div>
|
||||
<div>
|
||||
<span class="description"><b>Flight Time</b>
|
||||
{!! Utils::minutesToTimeString($pirep->flight_time) !!}
|
||||
{{ Utils::minutesToTimeString($pirep->flight_time) }}
|
||||
</span>
|
||||
</div>
|
||||
<div><span class="description"><b>Aircraft</b>
|
||||
{!! $pirep->aircraft->registration !!}
|
||||
({!! $pirep->aircraft->name !!})
|
||||
{{ $pirep->aircraft->registration }}
|
||||
({{ $pirep->aircraft->name }})
|
||||
</span>
|
||||
</div>
|
||||
@if(filled($pirep->level))
|
||||
<div>
|
||||
<span class="description"><b>Flight Level</b>
|
||||
{!! $pirep->level !!}
|
||||
{{ $pirep->level }}
|
||||
</span>
|
||||
</div>
|
||||
@endif
|
||||
<div>
|
||||
<span class="description"><b>Filed Using</b>
|
||||
{!! PirepSource::label($pirep->source) !!}
|
||||
{{ PirepSource::label($pirep->source) }}
|
||||
@if(filled($pirep->source_name))
|
||||
({!! $pirep->source_name !!})
|
||||
({{ $pirep->source_name }})
|
||||
@endif
|
||||
</span>
|
||||
</div>
|
||||
<div>
|
||||
<span class="description"><b>File Date</b>
|
||||
{!! show_datetime($pirep->created_at) !!}
|
||||
{{ show_datetime($pirep->created_at) }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -72,7 +72,7 @@
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<div id="pirep_{!! $pirep->id !!}_actionbar" class="pull-right">
|
||||
<div id="pirep_{{ $pirep->id }}_actionbar" class="pull-right">
|
||||
@include('admin.pireps.actions', ['pirep' => $pirep, 'on_edit_page' => false])
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -25,10 +25,10 @@ $(document).ready(() => {
|
||||
console.log('aircraft select change: ', aircraft_id);
|
||||
|
||||
$.ajax({
|
||||
url: "{!! url('/admin/pireps/fares') !!}?aircraft_id=" + aircraft_id,
|
||||
url: "{{ url('/admin/pireps/fares') }}?aircraft_id=" + aircraft_id,
|
||||
type: 'GET',
|
||||
headers: {
|
||||
'x-api-key': '{!! Auth::user()->api_key !!}'
|
||||
'x-api-key': '{{ Auth::user()->api_key }}'
|
||||
},
|
||||
success: (data) => {
|
||||
console.log('returned new fares', data);
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
<div class="box box-solid">
|
||||
<div class="box-header with-border">
|
||||
{{--<i class="fa fa-text-width"></i>--}}
|
||||
<h3 class="box-title">{!! Form::label('dpt_airport_id', 'Dep ICAO') !!}</h3>
|
||||
<h3 class="box-title">{{ Form::label('dpt_airport_id', 'Dep ICAO') }}</h3>
|
||||
</div>
|
||||
<div class="box-body"><p class="lead">
|
||||
{!! $pirep->dpt_airport->icao !!} - {!! $pirep->dpt_airport->name !!}
|
||||
{{ $pirep->dpt_airport->icao }} - {{ $pirep->dpt_airport->name }}
|
||||
</p></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -15,17 +15,17 @@
|
||||
<div class="box box-solid">
|
||||
<div class="box-header with-border">
|
||||
{{--<i class="fa fa-text-width"></i>--}}
|
||||
<h3 class="box-title">{!! Form::label('arr_airport_id', 'Arrival ICAO') !!}</h3>
|
||||
<h3 class="box-title">{{ Form::label('arr_airport_id', 'Arrival ICAO') }}</h3>
|
||||
</div>
|
||||
<div class="box-body"><p class="lead">
|
||||
{!! $pirep->arr_airport->icao !!} - {!! $pirep->arr_airport->name !!}
|
||||
{{ $pirep->arr_airport->icao }} - {{ $pirep->arr_airport->name }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group col-sm-3">
|
||||
<div id="pirep_{!! $pirep->id !!}_actionbar" class="pull-right">
|
||||
<div id="pirep_{{ $pirep->id }}_actionbar" class="pull-right">
|
||||
@include('admin.pireps.actions')
|
||||
</div>
|
||||
</div>
|
||||
@@ -35,49 +35,49 @@
|
||||
<table class="table table-hover">
|
||||
<tr>
|
||||
<td>Pilot</td>
|
||||
<td><a href="{!! route('admin.users.show', ['id' => $pirep->pilot->id]) !!}"
|
||||
target="_blank">{!! $pirep->user->name !!}</a>
|
||||
<td><a href="{{ route('admin.users.show', ['id' => $pirep->pilot->id]) }}"
|
||||
target="_blank">{{ $pirep->user->name }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Flight</td>
|
||||
<td>
|
||||
<a href="{!! route('admin.flights.show', [$pirep->flight_id]) !!}"
|
||||
<a href="{{ route('admin.flights.show', [$pirep->flight_id]) }}"
|
||||
target="_blank">
|
||||
{!! $pirep->ident !!}
|
||||
{{ $pirep->ident }}
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Aircraft</td>
|
||||
<td>{!! $pirep->aircraft->subfleet->name !!}, {!! $pirep->aircraft->name !!}
|
||||
({!! $pirep->aircraft->registration !!})
|
||||
<td>{{ $pirep->aircraft->subfleet->name }}, {{ $pirep->aircraft->name }}
|
||||
({{ $pirep->aircraft->registration }})
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Flight Time</td>
|
||||
<td>{!! Utils::minutesToTimeString($pirep->flight_time) !!}</td>
|
||||
<td>{{ Utils::minutesToTimeString($pirep->flight_time) }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Flight Level</td>
|
||||
<td>{!! $pirep->level !!}</td>
|
||||
<td>{{ $pirep->level }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Route</td>
|
||||
<td>{!! $pirep->route !!}</td>
|
||||
<td>{{ $pirep->route }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Notes</td>
|
||||
<td>{!! $pirep->notes !!}</td>
|
||||
<td>{{ $pirep->notes }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Filed On</td>
|
||||
<td>{!! show_datetime($pirep->created_at) !!}</td>
|
||||
<td>{{ show_datetime($pirep->created_at) }}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Updated On</td>
|
||||
<td>{!! show_datetime($pirep->updated_at) !!}</td>
|
||||
<td>{{ show_datetime($pirep->updated_at) }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
@@ -4,15 +4,15 @@
|
||||
<tbody>
|
||||
@foreach($journal['transactions'] as $entry)
|
||||
<tr>
|
||||
<td>{!! $entry->memo !!}</td>
|
||||
<td>{{ $entry->memo }}</td>
|
||||
<td>
|
||||
@if($entry->credit)
|
||||
{!! money($entry->credit, config('phpvms.currency')) !!}
|
||||
{{ money($entry->credit, config('phpvms.currency')) }}
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if($entry->debit)
|
||||
{!! money($entry->debit, config('phpvms.currency')) !!}
|
||||
{{ money($entry->debit, config('phpvms.currency')) }}
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
@@ -22,10 +22,10 @@
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>
|
||||
{!! $journal['credits'] !!}
|
||||
{{ $journal['credits'] }}
|
||||
</td>
|
||||
<td>
|
||||
<i>{!! $journal['debits'] !!}</i>
|
||||
<i>{{ $journal['debits'] }}</i>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
<b>Total</b>
|
||||
</td>
|
||||
<td>
|
||||
{!! $journal['credits']->subtract($journal['debits']) !!}
|
||||
{{ $journal['credits']->subtract($journal['debits']) }}
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
Reference in New Issue
Block a user