diff options
| author | Étienne Loks <etienne.loks@peacefrogs.net> | 2013-08-25 12:56:23 +0200 | 
|---|---|---|
| committer | Étienne Loks <etienne.loks@peacefrogs.net> | 2013-08-25 12:56:23 +0200 | 
| commit | a3f562c6050819aeee23bd10e3efa38126e7f0d7 (patch) | |
| tree | 13240b03be05b0ce63c261f80274d21dcda65111 /archaeological_operations/models.py | |
| parent | 7be596f41305b4be26796625bd800d58a04bb0a7 (diff) | |
| download | Ishtar-a3f562c6050819aeee23bd10e3efa38126e7f0d7.tar.bz2 Ishtar-a3f562c6050819aeee23bd10e3efa38126e7f0d7.zip | |
Improve cached_label display
Diffstat (limited to 'archaeological_operations/models.py')
| -rw-r--r-- | archaeological_operations/models.py | 8 | 
1 files changed, 4 insertions, 4 deletions
| diff --git a/archaeological_operations/models.py b/archaeological_operations/models.py index d51e7a518..9e2fc9b4c 100644 --- a/archaeological_operations/models.py +++ b/archaeological_operations/models.py @@ -26,7 +26,7 @@ from django.db.models import Q, Count, Sum, Max, Avg  from django.db.models.signals import post_save, m2m_changed  from django.utils.translation import ugettext_lazy as _, ugettext -from ishtar_common.utils import cached_label_changed, shortify +from ishtar_common.utils import cached_label_changed  from ishtar_common.models import GeneralType, BaseHistorizedItem, \       HistoricalRecords, LightHistorizedItem, OwnPerms, Department, Source,\ @@ -127,8 +127,8 @@ class Operation(BaseHistorizedItem, OwnPerms):      common_name = models.CharField(_(u"Generic name"), max_length=120,                                     null=True, blank=True)      comment = models.TextField(_(u"Comment"), null=True, blank=True) -    cached_label = models.CharField(_(u"Cached name"), max_length=100, -                                   null=True, blank=True) +    cached_label = models.CharField(_(u"Cached name"), max_length=500, +                                    null=True, blank=True)      history = HistoricalRecords()      class Meta: @@ -156,7 +156,7 @@ class Operation(BaseHistorizedItem, OwnPerms):              items.append("-".join((unicode(self.year),                                 unicode(self.operation_code))))          if self.common_name: -            items.append(shortify(self.common_name)) +            items.append(self.common_name)          cached_label = settings.JOINT.join(items)          return cached_label | 
