Coverage for app/models/eventParticipant.py: 92%
12 statements
« prev ^ index » next coverage.py v7.10.2, created at 2025-09-02 19:10 +0000
« prev ^ index » next coverage.py v7.10.2, created at 2025-09-02 19:10 +0000
1from app.models import*
2from app.models.user import User
3from app.models.event import Event
5class EventParticipant(baseModel):
6 user = ForeignKeyField(User)
7 event = ForeignKeyField(Event, backref="participants")
8 hoursEarned = FloatField(null = False, default = 0)
9 didWork = BooleanField(null = False, default = False)
10 isLabor = BooleanField(null = False, default = False) # This field is used to indicate if a user is a volunteer or a labor participant. False is volunteer, true is labor.
12 # Add this property so that we can combine these objects with EventRsvp objects in one array
13 @property
14 def rsvpWaitlist(self):
15 return False