mirror of
https://github.com/task-17-lct/backend.git
synced 2024-11-27 21:43:46 +03:00
16 lines
773 B
Python
16 lines
773 B
Python
from django.db import models
|
|
from passfinder.users.models import User
|
|
from passfinder.events.models import Event
|
|
|
|
|
|
class UserPreferences(models.Model):
|
|
user = models.ForeignKey(User, on_delete=models.CASCADE)
|
|
|
|
preffered_plays = models.ManyToManyField(Event, related_name='preffered_user_play')
|
|
unpreffered_lays = models.ManyToManyField(Event, related_name='unpreffered_users_play')
|
|
|
|
preffered_movies = models.ManyToManyField(Event, related_name='preffered_user_movie')
|
|
unpreffered_movies = models.ManyToManyField(Event, related_name='unpreffered_user_movie')
|
|
|
|
preferred_concerts = models.ManyToManyField(Event, related_name='preffered_users_concert')
|
|
unpreferred_concerts = models.ManyToManyField(Event, related_name='unpreffered_users_concert') |