A free open source IT asset/license management system
Added expected_checkin to user’s View Assigned page
snipe78da89340c36
diff --git a/app/Models/Asset.php b/app/Models/Asset.phpindex cba63987b5..e11c46197b 100644--- a/app/Models/Asset.php+++ b/app/Models/Asset.php@@ -399,6 +399,12 @@ class Asset extends Depreciable}+ protected function expectedCheckinFormattedDate(): Attribute+ {+ return Attribute:: make(+ get: fn(mixed $value, array $attributes) => array_key_exists('expected_checkin', $attributes) ? Helper::getFormattedDateObject($attributes['expected_checkin'], 'date', false) : null,+ );+ }/*** Establishes the asset -> company relationshipdiff --git a/resources/views/account/view-assets.blade.php b/resources/views/account/view-assets.blade.phpindex 7125bd0665..8e2336d4d8 100755--- a/resources/views/account/view-assets.blade.php+++ b/resources/views/account/view-assets.blade.php@@ -464,6 +464,9 @@<th class="col-md-2" data-switchable="true" data-visible="false">{{ trans('general.location') }}</th>+ <th class="col-md-2" data-switchable="true" data-visible="true">+ {{ trans('admin/hardware/form.expected_checkin') }}+ </th>@can('self.view_purchase_cost')<th class="col-md-6" data-footer-formatter="sumFormatter" data-fieldname="purchase_cost">{{ trans('general.purchase_cost') }}@@ -530,6 +533,9 @@<td>{{ ($asset->location) ? $asset->location->name : '' }}</td>+ <td>+ {{ ($asset->expected_checkin) ? $asset->expected_checkin_formatted_date : '' }}+ </td>@can('self.view_purchase_cost')<td>{!! Helper::formatCurrencyOutput($asset->purchase_cost) !!}