2017-11-30 08:01:07 +08:00
|
|
|
<div class="row">
|
2017-12-07 06:07:25 +08:00
|
|
|
<div class="form-group col-sm-4">
|
2017-11-30 08:01:07 +08:00
|
|
|
{!! Form::label('name', 'Name:') !!}
|
|
|
|
{!! Form::text('name', null, ['class' => 'form-control']) !!}
|
|
|
|
</div>
|
|
|
|
|
2017-12-07 06:07:25 +08:00
|
|
|
<div class="form-group col-sm-4">
|
2017-11-30 08:01:07 +08:00
|
|
|
{!! Form::label('email', 'Email:') !!}
|
|
|
|
{!! Form::text('email', null, ['class' => 'form-control']) !!}
|
|
|
|
</div>
|
2017-12-07 06:07:25 +08:00
|
|
|
|
|
|
|
<div class="form-group col-sm-4">
|
|
|
|
{!! Form::label('timezone', 'Timezone:') !!}
|
|
|
|
{!! Form::select('timezone', $timezones, null, ['id' => 'timezone', 'class' => 'select2' ]); !!}
|
|
|
|
</div>
|
2017-11-30 08:01:07 +08:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="form-group col-sm-6">
|
|
|
|
{!! Form::label('password', 'Password:') !!}
|
|
|
|
{!! Form::password('password', ['class' => 'form-control']) !!}
|
|
|
|
</div>
|
|
|
|
<div class="form-group col-sm-6">
|
|
|
|
{!! Form::label('home_airport_id', 'Home Airport:') !!}
|
|
|
|
{!! Form::select('home_airport_id', $airports, null , ['class' => 'form-control select2']) !!}
|
|
|
|
<br /><br />
|
|
|
|
{!! Form::label('curr_airport_id', 'Current Airport:') !!}
|
|
|
|
{!! Form::select('curr_airport_id', $airports, null , ['class' => 'form-control select2']) !!}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="form-group col-sm-4">
|
|
|
|
{!! Form::label('airline_id', 'Airline:') !!}
|
|
|
|
{!! Form::select('airline_id', $airlines, null, ['class' => 'form-control select2', 'placeholder' => 'Select Airline']) !!}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group col-sm-4">
|
|
|
|
{!! Form::label('rank_id', 'Rank:') !!}
|
|
|
|
{!! Form::select('rank_id', $ranks, null, ['class' => 'form-control select2', 'placeholder' => 'Select Rank']) !!}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group col-sm-4">
|
|
|
|
{!! Form::label('roles', 'Roles:') !!}
|
|
|
|
{!! Form::select('roles[]', $roles, $user->roles->pluck('id'),
|
|
|
|
['class' => 'form-control select2', 'placeholder' => 'Select Roles', 'multiple']) !!}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="form-group col-sm-6">
|
2017-12-23 06:32:21 +08:00
|
|
|
{!! Form::label('state', 'State:') !!}
|
2017-11-30 08:01:07 +08:00
|
|
|
<label class="checkbox-inline">
|
2017-12-31 10:40:32 +08:00
|
|
|
{!! Form::select('state', UserState::labels(), null, ['class' => 'form-control select2']) !!}
|
2017-11-30 08:01:07 +08:00
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Submit Field -->
|
2018-01-08 05:09:22 +08:00
|
|
|
<div class="form-group col-sm-6 text-right">
|
|
|
|
<a href="{!! route('admin.users.regen_apikey', ['id' => $user->id]) !!}" class="btn btn-warning"
|
|
|
|
onclick="return confirm('Are you sure? This will reset this user\'s API key.')">new api key</a>
|
|
|
|
|
|
|
|
{!! Form::button('Save', ['type' => 'submit', 'class' => 'btn btn-success']) !!}
|
|
|
|
<a href="{!! route('admin.users.index') !!}" class="btn btn-default">Cancel</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
<div class="form-group col-sm-12">
|
|
|
|
<table class="table table-hover">
|
|
|
|
<tr>
|
|
|
|
<td>API Key</td>
|
|
|
|
<td>{!! $user->api_key !!}</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td>Total Flights</td>
|
|
|
|
<td>{!! $user->flights !!}</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td>Flight Time</td>
|
|
|
|
<td>{!! Utils::minutesToTimeString($user->flight_time) !!}</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td>IP Address</td>
|
|
|
|
<td>{!! $user->last_ip !!}</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td>Registered On</td>
|
|
|
|
<td>{!! show_datetime($user->created_at) !!}</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td>Last Login</td>
|
|
|
|
<td>{!! show_datetime($user->updated_at) !!}</td>
|
|
|
|
</tr>
|
|
|
|
</table>
|
2017-11-30 08:01:07 +08:00
|
|
|
</div>
|
|
|
|
</div>
|