summaryrefslogtreecommitdiff
path: root/archaeological_finds/models.py
diff options
context:
space:
mode:
authorroot <root@viserion.(none)>2013-04-04 22:43:13 +0000
committerroot <root@viserion.(none)>2013-04-04 22:43:13 +0000
commit0b9a486b5e79d36c7eb7fa9592e1ebb4ec9ae668 (patch)
treea2c624b1ce76c6d57a8a156766e4863710d8ae19 /archaeological_finds/models.py
parent199f535e39880d6ddbbe6a068378fec7ff9fc084 (diff)
parentb2a879890cef5721accff66904be478de488b120 (diff)
downloadIshtar-0b9a486b5e79d36c7eb7fa9592e1ebb4ec9ae668.tar.bz2
Ishtar-0b9a486b5e79d36c7eb7fa9592e1ebb4ec9ae668.zip
Merge branch 'master' of lysithea.proxience.net:/home/proxience/git/ishtar
Diffstat (limited to 'archaeological_finds/models.py')
-rw-r--r--archaeological_finds/models.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/archaeological_finds/models.py b/archaeological_finds/models.py
index a02cb4402..ce0df10cf 100644
--- a/archaeological_finds/models.py
+++ b/archaeological_finds/models.py
@@ -82,7 +82,9 @@ class BaseFind(BaseHistorizedItem, OwnPerms):
return settings.JOINT.join(finds)
def _real_label(self):
- if not self.context_record.parcel.operation.code_patriarche:
+ if not self.context_record.parcel \
+ or not self.context_record.parcel.operation \
+ or not self.context_record.parcel.operation.code_patriarche:
return
find = self.get_last_find()
lbl = find.label or self.label
@@ -92,7 +94,9 @@ class BaseFind(BaseHistorizedItem, OwnPerms):
lbl) if it])
def _temp_label(self):
- if self.context_record.parcel.operation.code_patriarche:
+ if not self.context_record.parcel \
+ or not self.context_record.parcel.operation \
+ or not self.context_record.parcel.operation.code_patriarche:
return
find = self.get_last_find()
lbl = find.label or self.label