mirror of
https://github.com/kristoferssolo/FOSSDB.git
synced 2025-10-21 17:50:35 +00:00
Make Tag.name unique
This commit is contained in:
parent
c6f1092361
commit
90debba248
@ -1,9 +1,8 @@
|
|||||||
|
|
||||||
from django.db import models
|
from django.db import models
|
||||||
|
|
||||||
|
|
||||||
class Tag(models.Model):
|
class Tag(models.Model):
|
||||||
name = models.CharField(max_length=100)
|
name = models.CharField(max_length=100, unique=True, db_index=True)
|
||||||
description = models.TextField(blank=True, default="")
|
description = models.TextField(blank=True, default="")
|
||||||
icon = models.ImageField(upload_to="types/icons/", null=True, blank=True)
|
icon = models.ImageField(upload_to="types/icons/", null=True, blank=True)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user