Skip to content

A free open source IT asset/license management system

Added notes field to view blades

snipe5266b2c71fd4
diff --git a/resources/views/accessories/edit.blade.php b/resources/views/accessories/edit.blade.php
index 443a0b17cf..d6233d4e5a 100755
--- a/resources/views/accessories/edit.blade.php
+++ b/resources/views/accessories/edit.blade.php
@@ -35,6 +35,8 @@
</div>
@endif
+@include ('partials.forms.edit.notes')
+
@include ('partials.forms.edit.image-upload')
@stop
diff --git a/resources/views/accessories/view.blade.php b/resources/views/accessories/view.blade.php
index 7241807cf3..4d8f582f4b 100644
--- a/resources/views/accessories/view.blade.php
+++ b/resources/views/accessories/view.blade.php
@@ -102,6 +102,20 @@
<a href="{{ route('checkout/accessory', $accessory->id) }}" style="margin-right:5px;" class="btn btn-primary btn-sm" {{ (($accessory->numRemaining() > 0 ) ? '' : ' disabled') }}>{{ trans('general.checkout') }}</a>
@endcan
</div>
+
+ @if ($accessory->notes)
+
+ <div class="col-md-12">
+ <strong>
+ {{ trans('general.notes') }}
+ </strong>
+ </div>
+ <div class="col-md-12">
+ {!! nl2br(e($accessory->notes)) !!}
+ </div>
+ </div>
+ @endif
+
</div>
</div>
@stop
diff --git a/resources/views/components/edit.blade.php b/resources/views/components/edit.blade.php
index 725a69e79e..77cdb17c3c 100644
--- a/resources/views/components/edit.blade.php
+++ b/resources/views/components/edit.blade.php
@@ -33,6 +33,8 @@
</div>
@endif
+@include ('partials.forms.edit.notes')
+
@include ('partials.forms.edit.image-upload')
@stop
diff --git a/resources/views/components/view.blade.php b/resources/views/components/view.blade.php
index 0348377166..6fdb507e44 100644
--- a/resources/views/components/view.blade.php
+++ b/resources/views/components/view.blade.php
@@ -135,6 +135,20 @@
<div class="col-md-12" style="padding-bottom: 5px;"><strong>{{ trans('general.order_number') }}:</strong>
{{ $component->order_number }} </div>
@endif
+
+ @if ($component->notes)
+
+ <div class="col-md-12">
+ <strong>
+ {{ trans('general.notes') }}
+ </strong>
+ </div>
+ <div class="col-md-12">
+ {!! nl2br(e($component->notes)) !!}
+ </div>
+ </div>
+ @endif
+
</div>
</div> <!-- .row-->
diff --git a/resources/views/consumables/edit.blade.php b/resources/views/consumables/edit.blade.php
index 4555048a54..a270cc33db 100644
--- a/resources/views/consumables/edit.blade.php
+++ b/resources/views/consumables/edit.blade.php
@@ -33,5 +33,7 @@
</div>
@endif
+@include ('partials.forms.edit.notes')
+
@include ('partials.forms.edit.image-upload')
@stop
diff --git a/resources/views/consumables/view.blade.php b/resources/views/consumables/view.blade.php
index 3cf71117b9..dfa8c82d48 100644
--- a/resources/views/consumables/view.blade.php
+++ b/resources/views/consumables/view.blade.php
@@ -117,11 +117,26 @@
</div>
@endif
- @can('checkout', \App\Models\Accessory::class)
+ @can('checkout', \App\Models\Consumable::class)
<div class="col-md-12">
<a href="{{ route('checkout/consumable', $consumable->id) }}" style="padding-bottom:5px;" class="btn btn-primary btn-sm" {{ (($consumable->numRemaining() > 0 ) ? '' : ' disabled') }}>{{ trans('general.checkout') }}</a>
</div>
@endcan
+
+ @if ($consumable->notes)
+
+ <div class="col-md-12">
+ <strong>
+ {{ trans('general.notes') }}
+ </strong>
+ </div>
+ <div class="col-md-12">
+ {!! nl2br(e($consumable->notes)) !!}
+ </div>
+ </div>
+ @endif
+
+
</div> <!-- /.col-md-3-->
</div> <!-- /.row-->