GymEquipmentReports table

The GymEquipmentReports table in the FitStack - V2 schema has 13 columns, keyed by Id, with 5 foreign keys to Gyms, GymEquipmentUnits, Equipment, Users and 1 more.

Members report a broken machine from the FitStack app; staff resolve it. Extends the live GymEquipmentReport (UserId, GymId, EquipmentId) with the Unit, text and a status.

Columns (13)

Columns of the GymEquipmentReports table
ColumnTypeConstraintsDescription
Iduuidprimary key, not null
GymIduuidnot null, references Gyms.Id
UnitIduuidreferences GymEquipmentUnits.IdNull when the Member could not say which Unit.
EquipmentIduuidnot null, references Equipment.Id
UserIdtextnot null, references Users.IdThe reporting Member's User.
Descriptioncharacter varying(2000)
Statustextnot null`EquipmentReportStatus`.
ResolvedByEmployeeIduuidreferences Employees.Id
ResolvedAttimestamp with time zone
CreatedAttimestamp with time zonenot null
ModifiedAttimestamp with time zone
IsDeletedbooleannot null
DeletedAttimestamp with time zone

Indexes (1)

  • (GymId, Status, CreatedAt) (IX_GymEquipmentReports_GymId_Status_CreatedAt)

Relationships