Upload beautify
This commit is contained in:
51
app/Models/Upload.php
Normal file
51
app/Models/Upload.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Upload extends Model
|
||||
{
|
||||
protected $table = 'uploads';
|
||||
|
||||
public $incrementing = false;
|
||||
|
||||
protected $keyType = 'string';
|
||||
|
||||
protected $fillable = [
|
||||
'id',
|
||||
'user_id',
|
||||
'type',
|
||||
'status',
|
||||
'processing_state',
|
||||
'title',
|
||||
'slug',
|
||||
'category_id',
|
||||
'description',
|
||||
'tags',
|
||||
'license',
|
||||
'nsfw',
|
||||
'is_scanned',
|
||||
'has_tags',
|
||||
'preview_path',
|
||||
'published_at',
|
||||
'final_path',
|
||||
'expires_at',
|
||||
'moderation_status',
|
||||
'moderated_at',
|
||||
'moderated_by',
|
||||
'moderation_note',
|
||||
];
|
||||
|
||||
protected $casts = [
|
||||
'tags' => 'array',
|
||||
'nsfw' => 'boolean',
|
||||
'is_scanned' => 'boolean',
|
||||
'has_tags' => 'boolean',
|
||||
'published_at' => 'datetime',
|
||||
'expires_at' => 'datetime',
|
||||
'moderated_at' => 'datetime',
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user