2020-07-03 06:55:25 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Pterodactyl\Models;
|
|
|
|
|
2022-10-14 18:59:20 +02:00
|
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
|
|
|
2020-07-03 06:55:25 +02:00
|
|
|
/**
|
2021-01-28 05:52:11 +01:00
|
|
|
* @property int $id
|
|
|
|
* @property int $user_id
|
|
|
|
* @property string $token
|
|
|
|
* @property \Carbon\CarbonImmutable $created_at
|
2020-07-03 06:55:25 +02:00
|
|
|
* @property \Pterodactyl\Models\User $user
|
|
|
|
*/
|
|
|
|
class RecoveryToken extends Model
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* There are no updates to this model, only inserts and deletes.
|
|
|
|
*/
|
2021-01-23 21:33:34 +01:00
|
|
|
public const UPDATED_AT = null;
|
2020-07-03 06:55:25 +02:00
|
|
|
|
2020-07-10 06:32:31 +02:00
|
|
|
public $timestamps = true;
|
|
|
|
|
2022-10-14 18:59:20 +02:00
|
|
|
protected bool $immutableDates = true;
|
2020-07-03 06:55:25 +02:00
|
|
|
|
2022-10-14 18:59:20 +02:00
|
|
|
public static array $validationRules = [
|
2020-07-03 06:55:25 +02:00
|
|
|
'token' => 'required|string',
|
|
|
|
];
|
|
|
|
|
2022-10-14 18:59:20 +02:00
|
|
|
public function user(): BelongsTo
|
2020-07-03 06:55:25 +02:00
|
|
|
{
|
|
|
|
return $this->belongsTo(User::class);
|
|
|
|
}
|
|
|
|
}
|