mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-13 00:54:07 -08:00
2d8269ddcd
* Create a new action_log table to replace asset_log. Use Polymorphism to generalize class and targets. Port everything I can find to use it. Add a migration to port the asset_logs table to action_logs. * Initial work on requestable asset models * Backend work for polymorphic requests table to store checkout requests. * Add missing files * Add a record to the db when requesting items. Build up a testing route for interfacing with this. * Users can now toggle requests of items on the request page. Reformat page to use the same tab layout we use elsewhere * Polymorphic request function. Implement requesting of asset models. Need to port mail/slack to notifications still. * Implement requesting of asset models. Build up emails and notifications to support it. Allow specifying a quantity of model to request. * Add view to show currently requested assets. Needs some work and cleanup, but it isn't accessible from anywhere yet.
85 lines
2.7 KiB
PHP
85 lines
2.7 KiB
PHP
@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')
|
|
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
|
|
@if ($requestedItems->count() > 0)
|
|
|
|
<div class="table-responsive">
|
|
<table class="table table-striped">
|
|
<thead>
|
|
<tr role="row">
|
|
<th class="col-md-1">Item Type</th>
|
|
<th class="col-md-1">Item Name</th>
|
|
<th class="col-md-1" bSortable="true">{{ trans('admin/hardware/table.location') }}</th>
|
|
<th class="col-md-1" bSortable="true">{{ trans('admin/hardware/form.expected_checkin') }}</th>
|
|
<th class="col-md-1" bSortable="true">Requesting User</th>
|
|
<th class="col-md-1">Requested Date</th>
|
|
<th class="col-md-1 actions" bSortable="false">{{ trans('table.actions') }}</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach ($requestedItems as $request)
|
|
|
|
<tr>
|
|
|
|
<form action="#" method="POST" accept-charset="utf-8">
|
|
{{ csrf_field() }}
|
|
<td>{{ $request->itemType() }}</td>
|
|
<td>{{ $request->name() }}</td>
|
|
@if ($request->location())
|
|
<td>{{ $request->location()->name }}</td>
|
|
@else
|
|
<td></td>
|
|
@endif
|
|
|
|
<td>
|
|
@if ($request->itemType() == "asset")
|
|
{{ $request->itemRequested()->expected_checkin }}
|
|
@else
|
|
"N/A"
|
|
@endif
|
|
</td>
|
|
<td>{{ $request->requestingUser()->fullName() }}</td>
|
|
<td>{{$request->created_at}}</td>
|
|
<td>
|
|
</td>
|
|
</form>
|
|
</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') }}
|
|
</div>
|
|
</div>
|
|
|
|
|
|
@endif
|
|
</div>
|
|
</div> <!-- .col-md-12> -->
|
|
</div> <!-- .row -->
|
|
|
|
|
|
|
|
@stop
|