mirror of
https://github.com/snipe/snipe-it.git
synced 2026-02-05 22:55:30 +00:00
Added expected_checkin to user’s View Assigned page
This commit is contained in:
@ -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 relationship
|
||||
|
||||
@ -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) !!}
|
||||
|
||||
Reference in New Issue
Block a user