Add goals feature for personal goals with filters

This commit is contained in:
Gregor Vostrak
2026-10-02 12:59:44 +02:00
parent 349623d537
commit f9519d0d5a
83 changed files with 7702 additions and 105 deletions

View File

@@ -28,6 +28,7 @@ use OwenIt\Auditing\Contracts\Auditable as AuditableContract;
* @property-read User $user
* @property-read Collection<int, ProjectMember> $projectMembers
* @property-read Collection<int, TimeEntry> $timeEntries
* @property-read Collection<int, Goal> $goals
*
* @method static MemberFactory factory()
*/
@@ -78,4 +79,14 @@ class Member extends Pivot implements AuditableContract
{
return $this->hasMany(ProjectMember::class, 'member_id');
}
/**
* Goals whose progress counts the time entries of this member.
*
* @return HasMany<Goal, $this>
*/
public function goals(): HasMany
{
return $this->hasMany(Goal::class, 'member_id');
}
}