blob: 2029cc56ea16d7f08e129b7d76bfec0c8823881a (
plain)
1
2
3
4
5
6
7
8
|
from django.db import models
class Tag(models.Model):
name = models.CharField(max_length=255, unique=True)
class Question(models.Model):
title = models.CharField(max_length=300)
tags = models.ManyToManyField(Tag, related_name='questions')
|