$timeEntries * * @method static TaskFactory factory() */ class Task extends Model { use HasFactory; use HasUuids; /** * The attributes that should be cast. * * @var array */ protected $casts = [ 'name' => 'string', ]; /** * @return BelongsTo */ public function project(): BelongsTo { return $this->belongsTo(Project::class); } /** * @return BelongsTo */ public function organization(): BelongsTo { return $this->belongsTo(Organization::class, 'organization_id'); } /** * @return HasMany */ public function timeEntries(): HasMany { return $this->hasMany(TimeEntry::class, 'task_id'); } }