3
0
mirror of https://github.com/snipe/snipe-it.git synced 2026-03-01 13:59:07 +00:00
Files
snipe-it/app/Models/Traits/HasUploads.php
snipe 95f867b267 Code formatting fixes
Signed-off-by: snipe <snipe@snipe.net>
2025-07-09 21:48:53 +01:00

19 lines
326 B
PHP

<?php
namespace App\Models\Traits;
use App\Models\Actionlog;
trait HasUploads
{
public function uploads()
{
return $this->hasMany(Actionlog::class, 'item_id')
->where('item_type', self::class)
->where('action_type', '=', 'uploaded')
->whereNotNull('filename');
}
}