Files
core/app/Models/Content/ContentHistory.php
T

31 lines
630 B
PHP

<?php
namespace App\Models\Content;
use App\Models\User;
use Illuminate\Database\Eloquent\Model;
/**
* Class ContentHistory
*/
class ContentHistory extends Model
{
use ModelTraits\ContentHistory;
protected $table = 'content_history';
// this table does not have created_at and updated_at fields
public $timestamps = false;
protected $fillable = [
'user_id',
'content_id',
'edit_batch',
'column',
'new_value',
'old_value'
];
protected $guarded = [];
public function author()
{
return $this->belongsTo(User::class, 'user_id');
}
}