2016-03-25 01:18:05 -07:00
|
|
|
@extends('layouts/default')
|
|
|
|
|
|
|
|
{{-- Page title --}}
|
|
|
|
@section('title')
|
2016-12-23 17:52:00 -08:00
|
|
|
View Assets for {{ $user->present()->fullName() }}
|
2016-03-25 01:18:05 -07:00
|
|
|
@parent
|
|
|
|
@stop
|
|
|
|
|
|
|
|
{{-- Account page content --}}
|
|
|
|
@section('content')
|
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="box box-default">
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
@if ($user->id)
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<div class="box-heading">
|
|
|
|
<h3 class="box-title"> {{ trans('admin/users/general.assets_user', array('name' => $user->first_name)) }}</h3>
|
2016-03-25 01:18:05 -07:00
|
|
|
</div>
|
2016-12-27 12:03:47 -08:00
|
|
|
</div><!-- /.box-header -->
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="box-body">
|
|
|
|
<!-- checked out assets table -->
|
2017-02-03 22:20:11 -08:00
|
|
|
@if (count($user->assets) > 0)
|
2016-03-25 01:18:05 -07:00
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table table-striped">
|
|
|
|
<thead>
|
2016-12-27 12:03:47 -08:00
|
|
|
<tr>
|
2018-02-05 15:36:35 -08:00
|
|
|
<th class="col-md-3">{{ trans('general.category') }}</th>
|
2016-12-27 12:03:47 -08:00
|
|
|
<th class="col-md-2">{{ trans('admin/hardware/table.asset_tag') }}</th>
|
|
|
|
<th class="col-md-3">{{ trans('general.name') }}</th>
|
2018-02-05 15:36:35 -08:00
|
|
|
<th class="col-md-4">{{ trans('admin/hardware/table.asset_model') }}</th>
|
|
|
|
<th class="col-md-3">{{ trans('admin/hardware/table.serial') }}</th>
|
2016-12-27 12:03:47 -08:00
|
|
|
<th></th>
|
|
|
|
</tr>
|
2016-03-25 01:18:05 -07:00
|
|
|
</thead>
|
|
|
|
<tbody>
|
2017-02-03 22:20:11 -08:00
|
|
|
@foreach ($user->assets as $asset)
|
2016-12-27 12:03:47 -08:00
|
|
|
<tr>
|
2018-02-05 15:36:35 -08:00
|
|
|
<td>{{ $asset->model->category->name }}</td>
|
|
|
|
<td>{{ $asset->asset_tag }}</td>
|
|
|
|
<td>{{ $asset->name }}</td>
|
2016-12-27 12:03:47 -08:00
|
|
|
<td>
|
|
|
|
@if ($asset->physical=='1')
|
2018-02-05 15:36:35 -08:00
|
|
|
{{ $asset->model->name }}
|
2016-12-27 12:03:47 -08:00
|
|
|
@endif
|
|
|
|
</td>
|
2017-10-20 18:51:14 -07:00
|
|
|
<td>{{ $asset->serial }}</td>
|
2016-12-27 12:03:47 -08:00
|
|
|
<td>
|
|
|
|
@if (($asset->image) && ($asset->image!=''))
|
|
|
|
<img src="{{ url('/') }}/uploads/assets/{{ $asset->image }}" height="50" width="50">
|
|
|
|
|
|
|
|
@elseif (($asset->model) && ($asset->model->image!=''))
|
|
|
|
<img src="{{ url('/') }}/uploads/models/{{ $asset->model->image }}" height="50" width="50">
|
|
|
|
@endif
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
@endforeach
|
2016-03-25 01:18:05 -07:00
|
|
|
</tbody>
|
2016-12-27 12:03:47 -08:00
|
|
|
</table>
|
|
|
|
</div> <!-- .table-responsive-->
|
|
|
|
@else
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="alert alert-info alert-block">
|
|
|
|
<i class="fa fa-info-circle"></i>
|
|
|
|
{{ trans('general.no_results') }}
|
2016-03-25 01:18:05 -07:00
|
|
|
</div>
|
|
|
|
</div>
|
2016-12-27 12:03:47 -08:00
|
|
|
@endif
|
|
|
|
</div> <!-- .box-body-->
|
|
|
|
</div><!--.box.box-default-->
|
|
|
|
</div> <!-- .col-md-12-->
|
|
|
|
</div> <!-- .row-->
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="box box-default">
|
|
|
|
@if ($user->id)
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<div class="box-heading">
|
|
|
|
<h3 class="box-title"> {{ trans('admin/users/general.software_user', array('name' => $user->first_name)) }}</h3>
|
|
|
|
</div>
|
|
|
|
</div><!-- /.box-header -->
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="box-body">
|
|
|
|
<!-- checked out licenses table -->
|
|
|
|
@if (count($user->licenses) > 0)
|
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th class="col-md-5">{{ trans('general.name') }}</th>
|
|
|
|
<th class="col-md-4">{{ trans('admin/hardware/form.serial') }}</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach ($user->licenses as $license)
|
|
|
|
<tr>
|
|
|
|
<td>{{ $license->name }}</td>
|
|
|
|
<td>
|
|
|
|
@can('viewKeys', $license)
|
2017-12-05 16:26:39 -08:00
|
|
|
{{ mb_strimwidth($license->serial, 0, 50, "...") }}
|
2016-12-27 12:03:47 -08:00
|
|
|
@else
|
2017-12-05 16:26:39 -08:00
|
|
|
------------
|
2016-12-27 12:03:47 -08:00
|
|
|
@endcan
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
2016-03-25 01:18:05 -07:00
|
|
|
</table>
|
2016-12-27 12:03:47 -08:00
|
|
|
</div> <!-- .table-responsive-->
|
|
|
|
@else
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="alert alert-info alert-block">
|
|
|
|
<i class="fa fa-info-circle"></i>
|
|
|
|
{{ trans('general.no_results') }}
|
2016-03-25 01:18:05 -07:00
|
|
|
</div>
|
2016-12-27 12:03:47 -08:00
|
|
|
</div>
|
|
|
|
@endif
|
|
|
|
</div> <!-- .box-body-->
|
|
|
|
</div><!--.box.box-default-->
|
|
|
|
</div> <!-- .col-md-12-->
|
|
|
|
</div> <!-- .row-->
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="box box-default">
|
|
|
|
@if ($user->id)
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<div class="box-heading">
|
|
|
|
<h3 class="box-title"> {{ trans('general.consumables') }} </h3>
|
|
|
|
</div>
|
|
|
|
</div><!-- /.box-header -->
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="box-body">
|
|
|
|
<!-- checked out consumables table -->
|
|
|
|
@if (count($user->consumables) > 0)
|
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th class="col-md-12">{{ trans('general.name') }}</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach ($user->consumables as $consumable)
|
|
|
|
<tr>
|
|
|
|
<td>{{ $consumable->name }}</td>
|
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2016-03-25 01:18:05 -07:00
|
|
|
</div>
|
2016-12-27 12:03:47 -08:00
|
|
|
@else
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="alert alert-info alert-block">
|
|
|
|
<i class="fa fa-info-circle"></i>
|
|
|
|
{{ trans('general.no_results') }}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
</div> <!-- .box-body-->
|
|
|
|
</div><!--.box.box-default-->
|
|
|
|
</div> <!-- .col-md-12-->
|
|
|
|
</div> <!-- .row-->
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="box box-default">
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
@if ($user->id)
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<div class="box-heading">
|
|
|
|
<h3 class="box-title"> {{ trans('general.accessories') }}</h3>
|
|
|
|
</div>
|
|
|
|
</div><!-- /.box-header -->
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
<div class="box-body">
|
|
|
|
<!-- checked out licenses table -->
|
|
|
|
@if (count($user->accessories) > 0)
|
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th class="col-md-12">Name</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach ($user->accessories as $accessory)
|
|
|
|
<tr>
|
|
|
|
<td>{{ $accessory->name }}</td>
|
|
|
|
</tr>
|
|
|
|
@endforeach
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
@else
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="alert alert-info alert-block">
|
|
|
|
<i class="fa fa-info-circle"></i>
|
|
|
|
{{ trans('general.no_results') }}
|
2016-03-25 01:18:05 -07:00
|
|
|
</div>
|
|
|
|
</div>
|
2016-12-27 12:03:47 -08:00
|
|
|
@endif
|
|
|
|
</div> <!-- .box-body-->
|
|
|
|
</div><!--.box.box-default-->
|
|
|
|
</div> <!-- .col-md-12-->
|
|
|
|
</div> <!-- .row-->
|
|
|
|
|
2016-03-25 01:18:05 -07:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="box box-default">
|
2016-12-27 12:03:47 -08:00
|
|
|
@if ($user->id)
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<div class="box-heading">
|
|
|
|
<h3 class="box-title"> History</h3>
|
|
|
|
</div>
|
|
|
|
</div><!-- /.box-header -->
|
|
|
|
@endif
|
2016-03-25 01:18:05 -07:00
|
|
|
|
|
|
|
<div class="box-body">
|
2016-09-15 19:58:27 -07:00
|
|
|
@if (count($userlog) > 0)
|
2016-03-25 01:18:05 -07:00
|
|
|
<div class="table-responsive">
|
2017-05-23 14:32:21 -07:00
|
|
|
<table
|
|
|
|
class="table table-striped snipe-table"
|
|
|
|
name="userActivityReport"
|
|
|
|
id="table"
|
|
|
|
data-cookie="false"
|
|
|
|
data-cookie-id-table="userHistoryTable-{{ config('version.hash_version') }}"
|
2017-10-17 20:39:49 -07:00
|
|
|
data-url="{{route('api.activity.index', ['target_id' => $user->id, 'target_type' => 'User', 'order' => 'desc']) }}">
|
2016-03-25 01:18:05 -07:00
|
|
|
<thead>
|
2017-05-23 14:32:21 -07:00
|
|
|
<tr>
|
|
|
|
<th data-field="icon" style="width: 40px;" class="hidden-xs" data-formatter="iconFormatter"></th>
|
|
|
|
<th class="col-sm-3" data-field="created_at" data-formatter="dateDisplayFormatter">{{ trans('general.date') }}</th>
|
|
|
|
<th class="col-sm-3" data-field="admin" data-formatter="usersLinkObjFormatter">{{ trans('general.admin') }}</th>
|
|
|
|
<th class="col-sm-3" data-field="action_type">{{ trans('general.action') }}</th>
|
|
|
|
<th class="col-sm-3" data-field="item" data-formatter="polymorphicItemFormatter">{{ trans('general.item') }}</th>
|
|
|
|
</tr>
|
2016-03-25 01:18:05 -07:00
|
|
|
</thead>
|
|
|
|
<tbody>
|
2017-05-23 14:32:21 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
</table>
|
|
|
|
</div> <!--.table-responsive-->
|
2016-03-25 01:18:05 -07:00
|
|
|
|
2016-12-27 12:03:47 -08:00
|
|
|
@else
|
2016-03-25 01:18:05 -07:00
|
|
|
<div class="col-md-12">
|
|
|
|
<div class="alert alert-info alert-block">
|
|
|
|
<i class="fa fa-info-circle"></i>
|
|
|
|
{{ trans('general.no_results') }}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endif
|
2016-12-27 12:03:47 -08:00
|
|
|
</div> <!-- .box-body-->
|
|
|
|
</div><!--.box.box-default-->
|
|
|
|
</div> <!-- .col-md-12-->
|
|
|
|
</div> <!-- .row-->
|
2016-03-25 01:18:05 -07:00
|
|
|
|
|
|
|
@stop
|
2017-05-23 14:32:21 -07:00
|
|
|
|
|
|
|
@section('moar_scripts')
|
|
|
|
@include ('partials.bootstrap-table')
|
|
|
|
@stop
|