AKPreference.models module

class AKPreference.models.EventParticipant(*args, **kwargs)[source]

Bases: Model

Database table: AKPreference_eventparticipant

A participant describes a person taking part in an event.

Parameters:
  • id (AutoField) – Primary key: ID

  • name (CharField) – Nickname. Name to identify a participant by (in case of questions from the organizers)

  • institution (CharField) – Institution. Uni etc.

Relationship fields:

Parameters:
  • event (ForeignKey to Event) – Event. Associated event (related name: eventparticipant)

  • requirements (ManyToManyField to AKRequirement) – Requirements. Participant’s Requirements (related name: eventparticipant)

Reverse relationships:

Parameters:
  • availabilities (Reverse ForeignKey from Availability) – All availabilities of this Participant (related name of participant)

  • akpreference (Reverse ForeignKey from AKPreference) – All AK Preferences of this Participant (related name of participant)

get_time_constraints() list[str][source]

Construct list of required time constraint labels.

get_room_constraints() list[str][source]

Construct list of required room constraint labels.

property export_preferences

Preferences of this participant with positive score.

class AKPreference.models.AKPreference(*args, **kwargs)[source]

Bases: Model

Database table: AKPreference_akpreference

Model representing the preference of a participant to an AK.

Parameters:

Relationship fields:

Parameters:
  • event (ForeignKey to Event) – Event. Associated event (related name: akpreference)

  • participant (ForeignKey to EventParticipant) – Participant. Participant this preference belongs to (related name: akpreference)

  • ak (ForeignKey to AK) – AK. AK this preference belongs to (related name: akpreference)

class PreferenceLevel(value)[source]

Bases: IntegerChoices

Possible preference values

property required: bool

Whether this preference is a ‘REQUIRED’

property preference_score: int

Score of this preference for the solver