expenses

@component('admin.components.info') These expenses are only applied to this aircraft. @endcomponent
@if(count($aircraft->expenses) === 0) @include('admin.common.none_added', ['type' => 'expenses']) @endif @if(count($aircraft->expenses) > 0) @endif @foreach($aircraft->expenses as $expense) @endforeach
Name Cost {{ currency(config('phpvms.currency')) }} Type

{{ $expense->name }}

{{ $expense->amount }}

{{ \App\Models\Enums\ExpenseType::label($expense->type) }}

{{ Form::open(['url' => url('/admin/aircraft/'.$aircraft->id.'/expenses'), 'method' => 'delete', 'class' => 'modify_expense form-inline']) }} {{ Form::hidden('expense_id', $expense->id) }} {{ Form::button('', ['type' => 'submit', 'class' => 'btn btn-sm btn-danger btn-icon', 'onclick' => "return confirm('Are you sure?')", ]) }} {{ Form::close() }}

{{ Form::open(['url' => url('/admin/aircraft/'.$aircraft->id.'/expenses'), 'method' => 'post', 'class' => 'modify_expense form-inline']) }} {{ Form::input('text', 'name', null, ['class' => 'form-control input-sm', 'placeholder' => 'Name']) }} {{ Form::number('amount', null, ['class' => 'form-control input-sm', 'placeholder' => 'Amount']) }} {{ Form::select('type', \App\Models\Enums\ExpenseType::select(), null, ['class' => 'select2']) }} {{ Form::button(' Add', ['type' => 'submit', 'class' => 'btn btn-success btn-small']) }} {{ Form::close() }}

{{ $errors->first('name') }}

{{ $errors->first('amount') }}