*/ protected $casts = [ 'name' => 'string', ]; /** * @return BelongsTo */ public function organization(): BelongsTo { return $this->belongsTo(Organization::class, 'organization_id'); } /** * @return HasMany */ public function projects(): HasMany { return $this->hasMany(Project::class, 'client_id'); } /** * @return Attribute */ protected function isArchived(): Attribute { return Attribute::make( get: fn (mixed $value, array $attributes) => isset($attributes['archived_at']), ); } }