X-Git-Url: https://git.mdrn.pl/prawokultury.git/blobdiff_plain/3033e6b9f88d1729c3adc32ae8e45c6c4cffe4e0..8cff0ee70ee28ebb597f9bffd05aab147c2a1cd7:/questions/models.py diff --git a/questions/models.py b/questions/models.py index 33d2a43..746ad84 100644 --- a/questions/models.py +++ b/questions/models.py @@ -18,7 +18,7 @@ class TagCategory(models.Model): class Meta: verbose_name = _("Tag Category") - verbose_name_plural = _("Tag Categries") + verbose_name_plural = _("Tag Categories") def __unicode__(self): return self.name @@ -31,8 +31,9 @@ class Tag(TagBase): slug += "_%d" % i return slug - category = models.ForeignKey(TagCategory, blank = True, null = True, on_delete = models.SET_NULL) - + category = models.ForeignKey(TagCategory, blank = True, null = True, on_delete = models.SET_NULL, related_name = 'tags') + click_count = models.IntegerField(null = False, default = 0) + class Meta: verbose_name = _("Tag") verbose_name_plural = _("Tags")