You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
391 B

<?php
namespace App\Models;
class Blacklist extends SoftDeletesModel
{
protected $guarded = ['id'];
protected $appends = ['file_detail'];
protected $casts = [
'file'=>'array'
];
public function getFileDetailAttribute()
{
if (empty($this->file)) {
return [];
}
return Upload::whereIn('id', $this->file)->get();
}
}