You've already forked Epicnabbo-Catalogus-Updated-Daily
33 lines
594 B
PHP
33 lines
594 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
|
|
class CommandLog extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $table = 'commandlogs';
|
|
|
|
protected $primaryKey = 'timestamp';
|
|
|
|
protected $guarded = [];
|
|
|
|
public $timestamps = false;
|
|
|
|
public function user(): BelongsTo
|
|
{
|
|
return $this->belongsTo(User::class);
|
|
}
|
|
|
|
protected function casts(): array
|
|
{
|
|
return [
|
|
'timestamp' => 'datetime',
|
|
];
|
|
}
|
|
}
|