summaryrefslogtreecommitdiff
path: root/archaeological_operations/models.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2017-08-28 19:20:33 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2017-08-28 19:20:33 +0200
commit93052a1caeeea3ca08362e7152b4f5c8c3fb0280 (patch)
treea00e1e40596cd89bf1a488c8332a55af3a593d96 /archaeological_operations/models.py
parent446eab605172aa778569914e7c43232c013d0d1a (diff)
downloadIshtar-93052a1caeeea3ca08362e7152b4f5c8c3fb0280.tar.bz2
Ishtar-93052a1caeeea3ca08362e7152b4f5c8c3fb0280.zip
Change all upload directories
Diffstat (limited to 'archaeological_operations/models.py')
-rw-r--r--archaeological_operations/models.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/archaeological_operations/models.py b/archaeological_operations/models.py
index 5a90ccac5..1f4108c28 100644
--- a/archaeological_operations/models.py
+++ b/archaeological_operations/models.py
@@ -179,7 +179,6 @@ class Operation(ClosedItem, BaseHistorizedItem, ImageModel, OwnPerms,
SHOW_URL = 'show-operation'
TABLE_COLS = ['year', 'towns', 'common_name', 'operation_type',
'start_date', 'excavation_end_date', 'remains']
- IMAGE_PREFIX = 'operations/'
SLUG = 'operation'
# search parameters
@@ -479,6 +478,10 @@ class Operation(ClosedItem, BaseHistorizedItem, ImageModel, OwnPerms,
self.context_record.model.cached_label_bulk_update(operation_id=self.pk)
return True
+ def _get_base_image_path(self):
+ return u"operation/{}/{}".format(
+ self.year, self.reference)
+
def get_town_label(self):
lbl = unicode(_('Intercommunal'))
if self.towns.count() == 1: