* @license MIT */ namespace Pterodactyl\Addons\AdvancedAdmin\Models; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\BelongsTo; /** * @property int $id * @property int $server_id * @property string $file_path * @property string $path_hash * @property string $content_hash * @property int $revision_number * @property string $storage_key * @property string $storage_type * @property int $size_bytes * @property int $compressed_size * @property int $author_id * @property string $change_summary */ class FileRevision extends Model { protected $table = 'addon_file_revisions'; public $timestamps = false; protected $fillable = [ 'server_id', 'file_path', 'path_hash', 'content_hash', 'revision_number', 'storage_key', 'storage_type', 'size_bytes', 'compressed_size', 'author_id', 'change_summary', ]; protected $casts = [ 'created_at' => 'datetime', ]; public function server(): BelongsTo { return $this->belongsTo(\Pterodactyl\Models\Server::class, 'server_id'); } public function author(): BelongsTo { return $this->belongsTo(\Pterodactyl\Models\User::class, 'author_id'); } }