@extends('layouts/default') {{-- Page title --}} @section('title') View Assets for {{ $user->fullName() }} @parent @stop {{-- Account page content --}} @section('content')
@if ($user->id)

{{ trans('admin/users/general.assets_user', array('name' => $user->first_name)) }}

@endif
@if (count($user->assets) > 0)
@foreach ($user->assets as $asset) @endforeach
{{ trans('admin/hardware/table.asset_model') }} {{ trans('admin/hardware/table.asset_tag') }} {{ trans('general.name') }}
@if ($asset->physical=='1') {{ $asset->model->name }} @endif {{ $asset->asset_tag }} {{ $asset->name }} @if (($asset->image) && ($asset->image!='')) @elseif (($asset->model) && ($asset->model->image!='')) @endif
@else
{{ trans('general.no_results') }}
@endif
@if ($user->id)

{{ trans('admin/users/general.software_user', array('name' => $user->first_name)) }}

@endif
@if (count($user->licenses) > 0)
@foreach ($user->licenses as $license) @endforeach
{{ trans('general.name') }} {{ trans('admin/hardware/form.serial') }}
{{ $license->name }} @if (($user->hasAccess('admin')) || ($user->hasAccess('license_keys'))) {{ mb_strimwidth($license->serial, 0, 50, "...") }} @else --- @endif
@else
{{ trans('general.no_results') }}
@endif
@if ($user->id)

{{ trans('general.consumables') }}

@endif
@if (count($user->consumables) > 0)
@foreach ($user->consumables as $consumable) @endforeach
{{ trans('general.name') }}
{{ $consumable->name }}
@else
{{ trans('general.no_results') }}
@endif
@if ($user->id)

{{ trans('general.accessories') }}

@endif
@if (count($user->accessories) > 0)
@foreach ($user->accessories as $accessory) @endforeach
Name
{{ $accessory->name }}
@else
{{ trans('general.no_results') }}
@endif
@if ($user->id)

History

@endif
@if (count($user->userlog) > 0)
@foreach ($user->userlog as $log) @endforeach
{{ trans('table.action') }} {{ trans('general.asset') }} {{ trans('table.by') }} {{ trans('general.date') }}
@if (($log->assetlog) && ($log->asset_type=="hardware")) @elseif (($log->accessorylog) && ($log->asset_type=="accessory")) @elseif (($log->consumablelog) && ($log->asset_type=="consumable")) @elseif (($log->licenselog) && ($log->asset_type=="software")) @else @endif {{ $log->action_type }} @if (($log->assetlog) && ($log->asset_type=="hardware")) @if ($log->assetlog->deleted_at=='') {{ $log->assetlog->showAssetName() }} @else {{ $log->assetlog->showAssetName() }} (deleted) @endif @elseif (($log->licenselog) && ($log->asset_type=="software")) @if ($log->licenselog->deleted_at=='') {{ $log->licenselog->name }} @else {{ $log->licenselog->name }} (deleted) @endif @elseif (($log->consumablelog) && ($log->asset_type=="consumable")) @if ($log->consumablelog->deleted_at=='') {{ $log->consumablelog->name }} @else {{ $log->consumablelog->name }} (deleted) @endif @elseif (($log->accessorylog) && ($log->asset_type=="accessory")) @if ($log->accessorylog->deleted_at=='') {{ $log->accessorylog->name }} @else {{ $log->accessorylog->name }} (deleted) @endif @else {{ trans('general.bad_data') }} @endif {{ $log->adminlog->fullName() }} {{ $log->created_at }}
@else
{{ trans('general.no_results') }}
@endif
@stop