PHP Class Flarum\Core\EmailToken

Inheritance: extends Flarum\Database\AbstractModel
Afficher le fichier Open project: flarum/core Class Usage Examples

Méthodes publiques

Свойство Type Description
$incrementing boolean Use a custom primary key for this model.

Protected Properties

Свойство Type Description
$dates
$table

Méthodes publiques

Méthode Description
generate ( string $email, integer $userId ) : static Generate an email token for the specified user.
scopeValidOrFail ( Builder $query, string $id ) : static Find the token with the given ID, and assert that it has not expired.
user ( ) : BelongsTo Define the relationship with the owner of this email token.

Method Details

generate() public static méthode

Generate an email token for the specified user.
public static generate ( string $email, integer $userId ) : static
$email string
$userId integer
Résultat static

scopeValidOrFail() public méthode

Find the token with the given ID, and assert that it has not expired.
public scopeValidOrFail ( Builder $query, string $id ) : static
$query Illuminate\Database\Eloquent\Builder
$id string
Résultat static

user() public méthode

Define the relationship with the owner of this email token.
public user ( ) : BelongsTo
Résultat Illuminate\Database\Eloquent\Relations\BelongsTo

Property Details

$dates protected_oe property

protected $dates

$incrementing public_oe property

Use a custom primary key for this model.
public bool $incrementing
Résultat boolean

$table protected_oe property

protected $table