dishplanner/app/Models/Planner.php

39 lines
874 B
PHP
Raw Permalink Normal View History

2025-10-13 14:57:11 +02:00
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
use Laravel\Cashier\Billable;
2025-10-13 14:57:11 +02:00
use Laravel\Sanctum\HasApiTokens;
/**
* @property int $id
* @property static PlannerFactory factory($count = null, $state = [])
2026-01-04 03:58:47 +01:00
* @method static first()
2026-01-08 00:37:33 +01:00
* @method static create(array $array)
2025-10-13 14:57:11 +02:00
*/
class Planner extends Authenticatable
{
use Billable, HasApiTokens, HasFactory, Notifiable;
2025-10-13 14:57:11 +02:00
protected $fillable = [
'name', 'email', 'password',
];
protected $hidden = [
'password', 'remember_token',
];
2025-12-28 20:18:27 +01:00
protected $casts = [
'password' => 'hashed',
];
2025-10-13 14:57:11 +02:00
public function schedules(): HasMany
{
return $this->hasMany(Schedule::class);
}
}