mirror of
https://github.com/snipe/snipe-it.git
synced 2025-01-12 14:27:33 -08:00
Use divs instead of layout table on view
This commit is contained in:
parent
dfaa1c9578
commit
6aeb3c0a47
|
@ -30,15 +30,297 @@
|
|||
<div class="nav-tabs-custom">
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a href="#details" data-toggle="tab">Details</a></li>
|
||||
<li><a href="#seats" data-toggle="tab">{{ trans('admin/licenses/form.seats') }}</a></li>
|
||||
<li><a href="#uploads" data-toggle="tab">{{ trans('general.file_uploads') }}</a></li>
|
||||
<li><a href="#history" data-toggle="tab">{{ trans('admin/licenses/general.checkout_history') }}</a></li>
|
||||
<li class="pull-right"><a href="#" data-toggle="modal" data-target="#uploadFileModal"><i class="fa fa-paperclip"></i> {{ trans('button.upload') }}</a></li>
|
||||
<li class="pull-right"><a href="#" data-toggle="modal" data-target="#uploadFileModal"><i class="fa fa-paperclip" aria-hidden="true"></i> {{ trans('button.upload') }}</a></li>
|
||||
</ul>
|
||||
|
||||
<div class="tab-content">
|
||||
|
||||
<div class="tab-pane active" id="details">
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="col-md-12">
|
||||
<div class="container row-striped">
|
||||
|
||||
@if (!is_null($license->company))
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('general.company') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->company->name }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('admin/hardware/form.manufacturer') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
@can('view', \App\Models\Manufacturer::class)
|
||||
<a href="{{ route('manufacturers.show', $license->manufacturer->id) }}">
|
||||
{{ $license->manufacturer->name }}
|
||||
</a>
|
||||
@else
|
||||
{{ $license->manufacturer->name }}
|
||||
@endcan
|
||||
|
||||
@if ($license->manufacturer->url)
|
||||
<br><i class="fa fa-globe" aria-hidden="true"></i> <a href="{{ $license->manufacturer->url }}" rel="noopener">{{ $license->manufacturer->url }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_url)
|
||||
<br><i class="fa fa-life-ring" aria-hidden="true"></i>
|
||||
<a href="{{ $license->manufacturer->support_url }}" rel="noopener">{{ $license->manufacturer->support_url }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_phone)
|
||||
<br><i class="fa fa-phone" aria-hidden="true"></i>
|
||||
<a href="tel:{{ $license->manufacturer->support_phone }}">{{ $license->manufacturer->support_phone }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_email)
|
||||
<br><i class="fa fa-envelope" aria-hidden="true"></i> <a href="mailto:{{ $license->manufacturer->support_email }}">{{ $license->manufacturer->support_email }}</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if (!is_null($license->serial))
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('admin/licenses/form.license_key') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
@can('viewKeys', $license)
|
||||
{!! nl2br(e($license->serial)) !!}
|
||||
@else
|
||||
------------
|
||||
@endcan
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if ($license->category)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('general.category') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<a href="{{ route('categories.show', $license->category->id) }}">{{ $license->category->name }}</a>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if ($license->license_name!='')
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('admin/licenses/form.to_name') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->license_name }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if ($license->license_email!='')
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/licenses/form.to_email') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->license_email }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if ($license->supplier_id)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('general.supplier') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<a href="{{ route('suppliers.show', $license->supplier_id) }}">
|
||||
{{ $license->supplier->name }}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if (isset($license->expiration_date))
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/licenses/form.expiration') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->expiration_date }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if ($license->depreciation)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/hardware/form.depreciation') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->depreciation->name }}
|
||||
({{ $license->depreciation->months }}
|
||||
{{ trans('admin/hardware/form.months') }}
|
||||
)
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/hardware/form.depreciates_on') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->depreciated_date()->format("Y-m-d") }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/hardware/form.fully_depreciated') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
@if ($license->time_until_depreciated()->y > 0)
|
||||
{{ $license->time_until_depreciated()->y }}
|
||||
{{ trans('admin/hardware/form.years') }},
|
||||
@endif
|
||||
{{ $license->time_until_depreciated()->m }}
|
||||
{{ trans('admin/hardware/form.months') }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if ($license->purchase_order)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/licenses/form.purchase_order') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->purchase_order }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
@if (isset($license->purchase_date))
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>{{ trans('general.purchase_date') }}</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->purchase_date }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if ($license->purchase_cost > 0)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('general.purchase_cost') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $snipeSettings->default_currency }}
|
||||
{{ \App\Helpers\Helper::formatCurrencyOutput($license->purchase_cost) }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if ($license->order_number)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('general.order_number') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->order_number }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if (($license->seats) && ($license->seats) > 0)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/licenses/form.seats') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->seats }}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('admin/licenses/form.reassignable') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{{ $license->reassignable ? 'Yes' : 'No' }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@if ($license->notes)
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<strong>
|
||||
{{ trans('general.notes') }}
|
||||
</strong>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
{!! nl2br(e($license->notes)) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
</div> <!-- end row-striped -->
|
||||
</div>
|
||||
</div>
|
||||
</div> <!-- end tab-pane -->
|
||||
|
||||
|
||||
|
||||
<div class="tab-pane" id="seats">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="table-responsive">
|
||||
|
||||
|
@ -67,204 +349,6 @@
|
|||
|
||||
</div>
|
||||
|
||||
<div class="col-md-4">
|
||||
<div class="table">
|
||||
<table class="table">
|
||||
<tbody>
|
||||
@if (!is_null($license->company))
|
||||
<tr>
|
||||
<td>{{ trans('general.company') }}</td>
|
||||
<td>{{ $license->company->name }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer)
|
||||
<tr>
|
||||
<td>{{ trans('admin/hardware/form.manufacturer') }}:</td>
|
||||
<td><p style="line-height: 23px;">
|
||||
@can('view', \App\Models\Manufacturer::class)
|
||||
<a href="{{ route('manufacturers.show', $license->manufacturer->id) }}">
|
||||
{{ $license->manufacturer->name }}
|
||||
</a>
|
||||
@else
|
||||
{{ $license->manufacturer->name }}
|
||||
@endcan
|
||||
|
||||
@if ($license->manufacturer->url)
|
||||
<br><i class="fa fa-globe"></i> <a href="{{ $license->manufacturer->url }}" rel="noopener">{{ $license->manufacturer->url }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_url)
|
||||
<br><i class="fa fa-life-ring"></i>
|
||||
<a href="{{ $license->manufacturer->support_url }}" rel="noopener">{{ $license->manufacturer->support_url }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_phone)
|
||||
<br><i class="fa fa-phone"></i>
|
||||
<a href="tel:{{ $license->manufacturer->support_phone }}">{{ $license->manufacturer->support_phone }}</a>
|
||||
@endif
|
||||
|
||||
@if ($license->manufacturer->support_email)
|
||||
<br><i class="fa fa-envelope"></i> <a href="mailto:{{ $license->manufacturer->support_email }}">{{ $license->manufacturer->support_email }}</a>
|
||||
@endif
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
|
||||
@if (!is_null($license->serial))
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.license_key') }}: </td>
|
||||
<td style="word-wrap: break-word;overflow-wrap: break-word;word-break: break-word;">
|
||||
@can('viewKeys', $license)
|
||||
{!! nl2br(e($license->serial)) !!}
|
||||
@else
|
||||
------------
|
||||
@endcan
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->category)
|
||||
<tr>
|
||||
<td>{{ trans('general.category') }}: </td>
|
||||
<td style="word-wrap: break-word;overflow-wrap: break-word;word-break: break-word;">
|
||||
<a href="{{ route('categories.show', $license->category->id) }}">{{ $license->category->name }}</a>
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
|
||||
@if ($license->license_name!='')
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.to_name') }}: </td>
|
||||
<td>{{ $license->license_name }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->license_email!='')
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.to_email') }}:</td>
|
||||
<td>{{ $license->license_email }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->supplier_id)
|
||||
<tr>
|
||||
<td>{{ trans('general.supplier') }}:
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('suppliers.show', $license->supplier_id) }}">
|
||||
{{ $license->supplier->name }}
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if (isset($license->expiration_date))
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.expiration') }}:</td>
|
||||
<td>{{ $license->expiration_date }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->depreciation)
|
||||
<tr>
|
||||
<td>
|
||||
{{ trans('admin/hardware/form.depreciation') }}:
|
||||
</td>
|
||||
<td>
|
||||
{{ $license->depreciation->name }}
|
||||
({{ $license->depreciation->months }}
|
||||
{{ trans('admin/hardware/form.months') }}
|
||||
)
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{ trans('admin/hardware/form.depreciates_on') }}:
|
||||
</td>
|
||||
<td>
|
||||
{{ $license->depreciated_date()->format("Y-m-d") }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>
|
||||
{{ trans('admin/hardware/form.fully_depreciated') }}:
|
||||
</td>
|
||||
<td>
|
||||
@if ($license->time_until_depreciated()->y > 0)
|
||||
{{ $license->time_until_depreciated()->y }}
|
||||
{{ trans('admin/hardware/form.years') }},
|
||||
@endif
|
||||
{{ $license->time_until_depreciated()->m }}
|
||||
{{ trans('admin/hardware/form.months') }}
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->purchase_order)
|
||||
<tr>
|
||||
<td>
|
||||
{{ trans('admin/licenses/form.purchase_order') }}:
|
||||
</td>
|
||||
<td>
|
||||
{{ $license->purchase_order }}
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if (isset($license->purchase_date))
|
||||
<tr>
|
||||
<td>{{ trans('general.purchase_date') }}:</td>
|
||||
<td>{{ $license->purchase_date }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->purchase_cost > 0)
|
||||
<tr>
|
||||
<td>{{ trans('general.purchase_cost') }}:</td>
|
||||
<td>
|
||||
{{ $snipeSettings->default_currency }}
|
||||
{{ \App\Helpers\Helper::formatCurrencyOutput($license->purchase_cost) }}
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if ($license->order_number)
|
||||
<tr>
|
||||
<td>{{ trans('general.order_number') }}:</td>
|
||||
<td>{{ $license->order_number }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
@if (($license->seats) && ($license->seats) > 0)
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.seats') }}:</td>
|
||||
<td>{{ $license->seats }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
<tr>
|
||||
<td>{{ trans('admin/licenses/form.reassignable') }}:</td>
|
||||
<td>{{ $license->reassignable ? 'Yes' : 'No' }}</td>
|
||||
</tr>
|
||||
|
||||
@if ($license->notes)
|
||||
<tr>
|
||||
<td>{{ trans('general.notes') }}:</td>
|
||||
<td>
|
||||
{!! nl2br(e($license->notes)) !!}
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
</div> <!-- .table-->
|
||||
</div> <!--/.col-md-5-->
|
||||
</div> <!--/.row-->
|
||||
</div> <!-- /.tab-pane -->
|
||||
|
||||
|
|
Loading…
Reference in a new issue