if not location add default location

This commit is contained in:
Godfrey M 2024-01-23 13:33:57 -08:00
parent f270672a3d
commit 49021d277c
2 changed files with 2 additions and 2 deletions

View file

@ -102,7 +102,7 @@ class CheckinAssetNotification extends Notification
->title("Asset Checked in")
->addStartGroupToSection('activityText')
->fact(htmlspecialchars_decode($item->present()->name), '', 'activityText')
->fact('Checked into ', $item->location->name ? $item->location->name : '')
->fact('Checked into ', $item->location->name ? $item->location->name : $item->defaultLoc()->name)
->fact(trans('mail.Asset_Checkin_Notification')." by ", $admin->present()->fullName())
->fact('Asset Status', $item->assetstatus->name)
->fact('Notes', $note ?: 'No notes');

View file

@ -138,7 +138,7 @@ class CheckoutAssetNotification extends Notification
->title("Asset Checked Out")
->addStartGroupToSection('activityText')
->fact(htmlspecialchars_decode($item->present()->name), '', 'activityText')
->fact('Checked out from ', $item->location ? $item->location->name : '')
->fact('Checked out from ', $item->location ? $item->location->name : $item->assetLoc()->name)
->fact(trans('mail.Asset_Checkout_Notification') . " by ", $admin->present()->fullName())
->fact('Asset Status', $item->assetstatus->name)
->fact('Notes', $note ?: 'No notes');