You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

27 lines
609 B

from django.db import models
from django.contrib.auth.models import Group
class Category(models.Model):
"""Une catégorie de contenu."""
name = models.CharField(
max_length=255,
name="Nom de la catégorie"
)
class Content(models.Model):
"""Un contenu du site (vidéo)."""
name = models.CharField(
max_length=255,
name="Nom du contenu"
)
group_owner = models.ForeignKey(
Group,
on_delete=models.CASCADE,
editable=False,
)
content_url = models.URLField(
name='URL du contenu',
editable=False,
)