summaryrefslogtreecommitdiff
path: root/archaeological_finds/models.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2016-09-05 18:30:24 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2016-09-05 18:31:52 +0200
commit7fb1ff25e2491e94c3446a401e644de9793006f5 (patch)
tree54a97773eef1b633895480a8b8caeb768bf7b43a /archaeological_finds/models.py
parentd3d84ed7cc5ff3cb9c164838c78cfcee73fbc44e (diff)
downloadIshtar-7fb1ff25e2491e94c3446a401e644de9793006f5.tar.bz2
Ishtar-7fb1ff25e2491e94c3446a401e644de9793006f5.zip
Add images for operation, context records and sources (refs #2927, refs #351)
Diffstat (limited to 'archaeological_finds/models.py')
-rw-r--r--archaeological_finds/models.py8
1 files changed, 1 insertions, 7 deletions
diff --git a/archaeological_finds/models.py b/archaeological_finds/models.py
index 70e0156fc..e5d63b751 100644
--- a/archaeological_finds/models.py
+++ b/archaeological_finds/models.py
@@ -372,13 +372,7 @@ class Find(BaseHistorizedItem, ImageModel, OwnPerms, ShortMenuItem):
null=True)
history = HistoricalRecords()
BASKET_MODEL = FindBasket
-
- def __init__(self, *args, **kwargs):
- super(Find, self).__init__(*args, **kwargs)
- image = self._meta.get_field_by_name("image")[0]
- image.upload_to = "finds/"
- thumbnail = self._meta.get_field_by_name("thumbnail")[0]
- thumbnail.upload_to = "finds/thumbs/"
+ IMAGE_PREFIX = 'finds/'
class Meta:
verbose_name = _(u"Find")