import Models
from app import db
from Matching.PreferenceTyps import *


class MatchingPreferencesModel(Models.Base):
    __tablename__ = "matching_preferences"

    user_id = db.Column(db.ForeignKey('user.id'), primary_key=True)
    user = db.relationship(
        "UserModel",
        back_populates="matching_preferences"
    )
    project_pref = db.Column(db.Enum(ProjectPreference),
                             nullable=False,
                             default=ProjectPreference.DONT_CARE)
    age_group_pref = db.Column(db.Enum(AgeGroupPreference),
                               nullable=False,
                               default=AgeGroupPreference.DONT_CARE)
    interests_pref = db.Column(db.Enum(InterestsPreferences),
                               nullable=False,
                               default=InterestsPreferences.DONT_CARE)
