$userSubjects * @property-read Collection $insights * @property-read Collection $insightSchedules * @property-read Collection $telegramUsers * @property-read Collection $tokenUsages * @property-read Collection $subjects */ class User extends Authenticatable { /** @use HasFactory<\Database\Factories\UserFactory> */ use HasFactory, Notifiable, HasRoles; /** @var array */ protected $fillable = [ 'name', 'email', 'password', 'phone', 'locale', 'timezone', 'is_active', 'is_approved', 'token_limit', ]; /** @var array */ protected $casts = [ 'email_verified_at' => 'datetime', 'password' => 'hashed', 'is_active' => 'boolean', 'is_approved' => 'boolean', 'token_limit' => 'integer', ]; /** @var array */ protected $hidden = [ 'password', 'remember_token', ]; /** * Get the user subjects for the user. */ public function userSubjects(): HasMany { return $this->hasMany(UserSubject::class); } /** * Get the user interests for the user. */ public function userInterests(): HasMany { return $this->hasMany(UserInterest::class); } /** * Get the insights for the user. */ public function insights(): HasMany { return $this->hasMany(Insight::class); } /** * Get the insight schedules for the user. */ public function insightSchedules(): HasMany { return $this->hasMany(InsightSchedule::class); } /** * Get the telegram users for the user. */ public function telegramUsers(): HasMany { return $this->hasMany(TelegramUser::class); } /** * Get the token usages for the user. */ public function tokenUsages(): HasMany { return $this->hasMany(TokenUsage::class); } /** * Get the subjects created by the user. */ public function subjects(): HasMany { return $this->hasMany(Subject::class); } /** * Get the user consents. */ public function consents(): HasMany { return $this->hasMany(UserConsent::class); } /** * Get the user subscriptions. */ public function subscriptions(): HasMany { return $this->hasMany(\App\Models\UserSubscription::class); } /** * Get the user notifications. */ public function notifications(): HasMany { return $this->hasMany(\App\Models\UserNotification::class); } }