UserGoals table
The UserGoals table in the FitStack - V2 schema has 20 columns, keyed by Id, with 1 foreign key to Users.
v1 coaching added `AssignedByCoachId uuid` + `AssignedAt` here with no FK. v2 REMOVES both — coach-assigned goals are rows in `CoachAssignments` (63) with `TargetType = Goal`.
Columns (20)
| Column | Type | Constraints | Description |
|---|---|---|---|
| Id | uuid | primary key, not null | |
| UserId | text | not null, references Users.Id | No navigation property on the C# side. |
| GoalType | integer | not null | |
| Status | integer | not null | `GoalStatus`. |
| MetricType | integer | not null | |
| Unit | integer | not null | |
| Direction | integer | not null | `TrackingDirection`. |
| Title | text | ||
| Notes | text | ||
| StartValue | numeric | not null | |
| CurrentValue | numeric | not null | |
| TargetValue | numeric | not null | |
| StartDate | timestamp with time zone | not null | |
| TargetDate | timestamp with time zone | not null | |
| LastProgressUpdate | timestamp with time zone | ||
| CompletedAt | timestamp with time zone | ||
| CreatedAt | timestamp with time zone | not null | |
| ModifiedAt | timestamp with time zone | ||
| IsDeleted | boolean | not null | |
| DeletedAt | timestamp with time zone |
Relationships
UserGoals.UserIdreferencesUsers.Id