Skip to content

A free open source IT asset/license management system

Reworks PR #15490 - adds location to inventory email

snipe913b9f0c40c1
diff --git a/resources/views/notifications/markdown/user-inventory.blade.php b/resources/views/notifications/markdown/user-inventory.blade.php
index 207bc4c789..ec476cf039 100644
--- a/resources/views/notifications/markdown/user-inventory.blade.php
+++ b/resources/views/notifications/markdown/user-inventory.blade.php
@@ -9,7 +9,7 @@
## {{ $assets->count() }} {{ trans('general.assets') }}
<table width="100%">
- <tr><th align="left">{{ trans('mail.name') }} </th><th align="left">{{ trans('mail.asset_tag') }}</th><th align="left">{{ trans('admin/hardware/table.serial') }}</th><th align="left">{{ trans('general.category') }}</th> <th></th> </tr>
+ <tr><th align="left">{{ trans('mail.name') }} </th><th align="left">{{ trans('mail.asset_tag') }}</th><th align="left">{{ trans('admin/hardware/table.serial') }}</th><th align="left">{{ trans('general.category') }}</th><th align="left">{{ trans('admin/hardware/table.location') }}</th> <th></th> </tr>
@foreach($assets as $asset)
@@ -18,6 +18,7 @@
<td> {{ $asset->asset_tag }} </td>
<td> {{ $asset->serial }} </td>
<td> {{ $asset->model->category->name }}</td>
+ <td> {{ ($asset->location) ? $asset->location->name : '' }} </td>
@if (($snipeSettings->show_images_in_email =='1') && $asset->getImageUrl())
<td>
<img src="{{ asset($asset->getImageUrl()) }}" alt="Asset" style="max-width: 64px;">