Account for fuel in the finance calculations #313
This commit is contained in:
@@ -21,6 +21,7 @@ return [
|
||||
'fieldsreadonly' => 'Once a PIREP has been submitted, certain fields go into read-only mode.',
|
||||
'flightinformations' => 'Flight Information',
|
||||
'flightident' => 'Flight Number/Code/Leg',
|
||||
'block_fuel' => 'Block Fuel',
|
||||
'fuel_used' => 'Fuel Used',
|
||||
'codeoptional' => 'Code (optional)',
|
||||
'legoptional' => 'Leg (optional)',
|
||||
|
||||
@@ -21,6 +21,7 @@ return [
|
||||
'fieldsreadonly' => 'Una vez que se ha enviado un PIREP, ciertos campos pasan al modo de solo lectura.',
|
||||
'flightinformations' => 'Información de vuelo',
|
||||
'flightident' => 'Vuelo Número/Código/Etapa',
|
||||
'block_fuel' => 'Bloque de Combustible',
|
||||
'fuel_used' => 'Combustible Usado',
|
||||
'codeoptional' => 'Código (opcional)',
|
||||
'legoptional' => 'Etapa (opcional)',
|
||||
|
||||
@@ -16,6 +16,7 @@ return [
|
||||
'fieldsreadonly' => 'Quando un PIREP viene sottoporre, alcuni cami entrano in modalità di sola lettura.',
|
||||
'flightinformations' => 'Informazioni di Volo',
|
||||
'flightident' => 'Numero di Volo/Codice/Leg',
|
||||
'block_fuel' => 'Bloccare il Carburante',
|
||||
'fuel_used' => 'Carburante Usato',
|
||||
'codeoptional' => 'Codice (facoltativo)',
|
||||
'legoptional' => 'Leg (facoltativa)',
|
||||
|
||||
@@ -72,7 +72,13 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group col-md-6">
|
||||
{{ Form::label('fuel_jeta_cost', 'Jet A Fuel Cost:') }}
|
||||
{{ Form::number('fuel_jeta_cost', null, ['class' => 'form-control']) }}
|
||||
<p class="text-danger">{{ $errors->first('fuel_jeta_cost') }}</p>
|
||||
|
||||
@component('admin.components.info')
|
||||
This is the cost per {{ config('phpvms.internal_units.fuel') }}
|
||||
@endcomponent
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -6,9 +6,9 @@
|
||||
<th>Location</th>
|
||||
<th>Hub</th>
|
||||
<th style="text-align: center;">GH Cost</th>
|
||||
<th style="text-align: center;">100LL</th>
|
||||
{{--<th style="text-align: center;">100LL</th>--}}
|
||||
<th style="text-align: center;">JetA</th>
|
||||
<th style="text-align: center;">MOGAS</th>
|
||||
{{--<th style="text-align: center;">MOGAS</th>--}}
|
||||
<th></th>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -25,15 +25,15 @@
|
||||
<td style="text-align: center;">
|
||||
{{ $airport->ground_handling_cost }}
|
||||
</td>
|
||||
<td style="text-align: center;">
|
||||
{{--<td style="text-align: center;">
|
||||
<a class="inline" href="#" data-pk="{{ $airport->id }}" data-name="fuel_100ll_cost">{{ $airport->fuel_100ll_cost }}</a>
|
||||
</td>
|
||||
</td>--}}
|
||||
<td style="text-align: center;">
|
||||
<a class="inline" href="#" data-pk="{{ $airport->id }}" data-name="fuel_jeta_cost">{{ $airport->fuel_jeta_cost }}</a>
|
||||
</td>
|
||||
<td style="text-align: center;">
|
||||
{{--<td style="text-align: center;">
|
||||
<a class="inline" href="#" data-pk="{{ $airport->id }}" data-name="fuel_mogas_cost">{{ $airport->fuel_mogas_cost }}</a>
|
||||
</td>
|
||||
</td>--}}
|
||||
<td style="text-align: right;">
|
||||
{{ Form::open(['route' => ['admin.airports.destroy', $airport->id], 'method' => 'delete']) }}
|
||||
<a href="{{ route('admin.airports.edit', [$airport->id]) }}" class='btn btn-sm btn-success btn-icon'><i class="fas fa-pencil-alt"></i></a>
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
@endif
|
||||
</td>
|
||||
<td> </td>
|
||||
@if ($on_edit_page === false)
|
||||
<td>
|
||||
<form action="{{ route('admin.pireps.edit', [$pirep->id]) }}">
|
||||
<button type="submit"
|
||||
@@ -35,5 +36,6 @@
|
||||
<i class="fas fa-pencil-alt"></i> Edit</button>
|
||||
</form>
|
||||
</td>
|
||||
@endif
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -135,7 +135,7 @@
|
||||
|
||||
<div class="row">
|
||||
<!-- Flight Time Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
<div class="form-group col-sm-3">
|
||||
{{ Form::label('flight_time', 'Flight Time (hours & minutes):') }}
|
||||
@if($pirep->read_only)
|
||||
<p>
|
||||
@@ -163,8 +163,30 @@
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<!-- Block Fuel Field -->
|
||||
<div class="form-group col-sm-2">
|
||||
{{ Form::label('block_fuel', 'Block Fuel:') }}
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
{{ Form::number('block_fuel', null, ['class' => 'form-control', 'min' => 0]) }}
|
||||
<p class="text-danger">{{ $errors->first('block_fuel') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Fuel Used Field -->
|
||||
<div class="form-group col-sm-2">
|
||||
{{ Form::label('fuel_used', 'Fuel Used:') }}
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
{{ Form::number('fuel_used', null, ['class' => 'form-control', 'min' => 0]) }}
|
||||
<p class="text-danger">{{ $errors->first('fuel_used') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Level Field -->
|
||||
<div class="form-group col-sm-6">
|
||||
<div class="form-group col-sm-5">
|
||||
{{ Form::label('level', 'Flight Level:') }}
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
|
||||
@@ -228,13 +228,27 @@ flight reports that have been filed. You've been warned!
|
||||
<p class="text-danger">{{ $errors->first('aircraft_id') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-4">
|
||||
{{ Form::label('block_fuel', __('pireps.block_fuel')) }} ({{config('phpvms.internal_units.fuel')}})
|
||||
@if(!empty($pirep) && $pirep->read_only)
|
||||
<p>{{ $pirep->block_fuel }}</p>
|
||||
@else
|
||||
<div class="input-group input-group-sm form-group">
|
||||
{{ Form::number('block_fuel', null, [
|
||||
'class' => 'form-control',
|
||||
'min' => '0',
|
||||
'readonly' => (!empty($pirep) && $pirep->read_only),
|
||||
]) }}
|
||||
</div>
|
||||
<p class="text-danger">{{ $errors->first('block_fuel') }}</p>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-4">
|
||||
{{ Form::label('fuel_used', __('pireps.fuel_used')) }} ({{config('phpvms.internal_units.fuel')}})
|
||||
@if(!empty($pirep) && $pirep->read_only)
|
||||
<p>{{ $pirep->fuel_used }}</p>
|
||||
@else
|
||||
<div class="input-group input-group-sm form-group">
|
||||
{{-- You probably don't want to change this ID if you want the fare select to work --}}
|
||||
{{ Form::number('fuel_used', null, [
|
||||
'class' => 'form-control',
|
||||
'min' => '0',
|
||||
|
||||
Reference in New Issue
Block a user