From 39cf99e33581f23e25f3bd29fc263b4ca4c42adb Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 3 Apr 2018 11:35:50 +0200 Subject: Types: charfield to textfield for name and slug --- ishtar_common/models.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ishtar_common/models.py') diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 8f8117b6c..8d0339b92 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -437,9 +437,9 @@ class GeneralType(Cached, models.Model): """ Abstract class for "types" """ - label = models.CharField(_(u"Label"), max_length=100) - txt_idx = models.CharField( - _(u"Textual ID"), validators=[validate_slug], max_length=100, + label = models.TextField(_(u"Label")) + txt_idx = models.TextField( + _(u"Textual ID"), validators=[validate_slug], unique=True, help_text=_( u"The slug is the standardized version of the name. It contains " @@ -825,7 +825,7 @@ class HierarchicalType(GeneralType): class ItemKey(models.Model): - key = models.CharField(_(u"Key"), max_length=100) + key = models.TextField(_(u"Key")) content_type = models.ForeignKey(ContentType) object_id = models.PositiveIntegerField() content_object = GenericForeignKey('content_type', 'object_id') -- cgit v1.2.3