@extends('layouts/default') @section('title0') {{ trans('admin/hardware/general.requested') }} {{ trans('general.assets') }} @stop {{-- Page title --}} @section('title') @yield('title0') @parent @stop {{-- Page content --}} @section('content')
@if ($requestedItems->count() > 0)
@foreach ($requestedItems as $request) @if ($request->requestable) {{ csrf_field() }} @if ($request->location()) @else @endif @endif @endforeach
{{ trans('general.image') }} {{ trans('general.name') }} {{ trans('admin/hardware/table.location') }} {{ trans('admin/hardware/form.expected_checkin') }} {{ trans('admin/hardware/table.requesting_user') }} {{ trans('admin/hardware/table.requested_date') }} {{ trans('button.actions') }} {{ trans('general.checkout') }}
@if (($request->itemType() == "asset") && ($request->requestable)) {{ $request->requestable->name }} @elseif (($request->itemType() == "asset_model") && ($request->requestable)) {{ $request->requestable->name }} @endif @if ($request->itemType() == "asset") {{ $request->name() }} @elseif ($request->itemType() == "asset_model") {{ $request->name() }} @endif {{ $request->location()->name }} @if ($request->itemType() == "asset") {{ App\Helpers\Helper::getFormattedDateObject($request->requestable->expected_checkin, 'datetime', false) }} @endif @if ($request->requestingUser() && !$request->requestingUser()->trashed()) {{ $request->requestingUser()->present()->fullName() }} @else (deleted user) @endif {{ App\Helpers\Helper::getFormattedDateObject($request->created_at, 'datetime', false) }} {{ Form::open([ 'method' => 'POST', 'route' => [ 'account/request-item', $request->itemType(), $request->requestable->id, true, $request->requestingUser()->id ], ]) }} {{ Form::close() }} @if ($request->itemType() == "asset") @if ($request->requestable->assigned_to=='') {{ trans('general.checkout') }} @else {{ trans('general.checkin') }} @endif @endif
@else
{{ trans('general.no_results') }}
@endif
@stop @section('moar_scripts') @include ('partials.bootstrap-table', [ 'exportFile' => 'requested-export', 'search' => true, 'clientSearch' => true, ]) @stop