Skip to content

A free open source IT asset/license management system

Fixed #16618 - added notes to location sidebar

snipef12d17358163
diff --git a/resources/views/consumables/view.blade.php b/resources/views/consumables/view.blade.php
index bfc32b4cb6..8b313a7f66 100644
--- a/resources/views/consumables/view.blade.php
+++ b/resources/views/consumables/view.blade.php
@@ -333,6 +333,18 @@
</div>
@endif
+ @if ($consumable->created_by)
+ <!-- created at -->
+ <div class="row">
+ <div class="col-md-3">
+ {{ trans('general.created_by') }}
+ </div>
+ <div class="col-md-9">
+ {{ $consumable->adminuser->present()->fullName }}
+ </div>
+ </div>
+ @endif
+
@if ($consumable->created_at)
<!-- created at -->
<div class="row">
diff --git a/resources/views/locations/view.blade.php b/resources/views/locations/view.blade.php
index 770e004d00..6ee75d6bff 100644
--- a/resources/views/locations/view.blade.php
+++ b/resources/views/locations/view.blade.php
@@ -468,7 +468,16 @@
@endif
<div class="col-md-12">
- <ul class="list-unstyled" style="line-height: 20px; padding-bottom: 20px;">
+
+ <ul class="list-unstyled" style="line-height: 22px; padding-bottom: 20px;">
+
+ @if ($location->notes)
+ <li>
+ <strong>{{ trans('general.notes') }}</strong>:
+ {!! nl2br(Helper::parseEscapedMarkedownInline($location->notes)) !!}
+ </li>
+ @endif
+
@if ($location->address!='')
<li>{{ $location->address }}</li>
@endif
@@ -488,6 +497,7 @@
<li>{{ trans('admin/locations/table.ldap_ou') }}: {{ $location->ldap_ou }}</li>
@endif
+
@if ((($location->address!='') && ($location->city!='')) || ($location->state!='') || ($location->country!=''))
<li>
<a href="https://maps.google.com/?q={{ urlencode($location->address.','. $location->city.','.$location->state.','.$location->country.','.$location->zip) }}" target="_blank">
diff --git a/resources/views/models/view.blade.php b/resources/views/models/view.blade.php
index 8e99f55713..f5383f0af1 100755
--- a/resources/views/models/view.blade.php
+++ b/resources/views/models/view.blade.php
@@ -153,23 +153,11 @@
<ul class="list-unstyled" style="line-height: 25px;">
@if ($model->category)
- <li>{{ trans('general.category') }}:
+ <li>
+ <strong>{{ trans('general.category') }}</strong>:
<a href="{{ route('categories.show', $model->category->id) }}">{{ $model->category->name }}</a>
</li>
@endif
-
- @if ($model->created_at)
- <li>{{ trans('general.created_at') }}:
- {{ Helper::getFormattedDateObject($model->created_at, 'datetime', false) }}
- </li>
- @endif
-
- @if ($model->adminuser)
- <li>{{ trans('general.created_by') }}:
- {{ $model->adminuser->present()->name() }}
- </li>
- @endif
-
@if ($model->deleted_at)
<li>
<strong>
@@ -183,14 +171,15 @@
@endif
@if ($model->min_amt)
- <li>{{ trans('general.min_amt') }}:
+ <li>
+ <strong>{{ trans('general.min_amt') }}</strong>:
{{$model->min_amt }}
</li>
@endif
@if ($model->manufacturer)
<li>
- {{ trans('general.manufacturer') }}:
+ <strong>{{ trans('general.manufacturer') }}</strong>:
@can('view', \App\Models\Manufacturer::class)
<a href="{{ route('manufacturers.show', $model->manufacturer->id) }}">
{{ $model->manufacturer->name }}
@@ -228,46 +217,56 @@
@endif
@if ($model->model_number)
<li>
- {{ trans('general.model_no') }}:
+ <strong>{{ trans('general.model_no') }}</strong>:
{{ $model->model_number }}
</li>
@endif
@if ($model->depreciation)
<li>
- {{ trans('general.depreciation') }}:
+ <strong>{{ trans('general.depreciation') }}</strong>:
{{ $model->depreciation->name }} ({{ $model->depreciation->months.' '.trans('general.months')}})
</li>
@endif
@if ($model->eol)
- <li>{{ trans('general.eol') }}:
+ <li>
+ <strong>{{ trans('general.eol') }}</strong>:
{{ $model->eol .' '. trans('general.months') }}
</li>
@endif
@if ($model->fieldset)
- <li>{{ trans('admin/models/general.fieldset') }}:
+ <li>
+ <strong>{{ trans('admin/models/general.fieldset') }}</strong>:
<a href="{{ route('fieldsets.show', $model->fieldset->id) }}">{{ $model->fieldset->name }}</a>
</li>
@endif
@if ($model->notes)
<li>
- {{ trans('general.notes') }}:
+ <strong>{{ trans('general.notes') }}</strong>:
{!! nl2br(Helper::parseEscapedMarkedownInline($model->notes)) !!}
</li>
@endif
- </ul>
+ @if ($model->created_at)
+ <li>
+ <strong>{{ trans('general.created_at') }}</strong>:
+ {{ Helper::getFormattedDateObject($model->created_at, 'datetime', false) }}
+ </li>
+ @endif
- @if ($model->note)
- Notes:
- <p>
- {!! $model->present()->note() !!}
- </p>
- @endif
- </div>
+ @if ($model->adminuser)
+ <li>
+ <strong>{{ trans('general.created_by') }}</strong>:
+ {{ $model->adminuser->present()->name() }}
+ </li>
+ @endif
+
+
+ </ul>
+ </div>
</div>
</div>
@can('update', \App\Models\AssetModel::class)