summaryrefslogtreecommitdiff
path: root/archaeological_finds/models_finds.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2021-02-12 17:53:44 +0100
committerÉtienne Loks <etienne.loks@iggdrasil.net>2021-02-28 12:15:24 +0100
commit785e35555993fd1c7251b6d50e1fb4b27cbeb7f1 (patch)
tree9bf31ced127fc7389d9ba6f9d55279fd21debcfb /archaeological_finds/models_finds.py
parent3bbe9b6b0ed29709500d82c3b8122f8adb11d9ee (diff)
downloadIshtar-785e35555993fd1c7251b6d50e1fb4b27cbeb7f1.tar.bz2
Ishtar-785e35555993fd1c7251b6d50e1fb4b27cbeb7f1.zip
Refactoring - typo
Diffstat (limited to 'archaeological_finds/models_finds.py')
-rw-r--r--archaeological_finds/models_finds.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/archaeological_finds/models_finds.py b/archaeological_finds/models_finds.py
index 1bfe56708..c7065166e 100644
--- a/archaeological_finds/models_finds.py
+++ b/archaeological_finds/models_finds.py
@@ -502,11 +502,11 @@ class BaseFind(BulkUpdatedItem, BaseHistorizedItem, GeoItem,
for mat in find.material_types.all():
if mat.code:
materials.add(mat.code)
- c_id.append(u'-'.join(sorted(list(materials))))
+ c_id.append('-'.join(sorted(list(materials))))
c_id.append(self.context_record.label)
- c_id.append((u'{:0' + str(settings.ISHTAR_FINDS_INDEX_ZERO_LEN) + 'd}'
+ c_id.append(('{:0' + str(settings.ISHTAR_FINDS_INDEX_ZERO_LEN) + 'd}'
).format(self.index))
return settings.JOINT.join(c_id)
@@ -519,7 +519,7 @@ class BaseFind(BulkUpdatedItem, BaseHistorizedItem, GeoItem,
return ALTERNATE_CONFIGS[profile.config].basefind_short_id(self)
# OPE|FIND_index
c_id = [self._ope_code()]
- c_id.append((u'{:0' + str(settings.ISHTAR_FINDS_INDEX_ZERO_LEN) + 'd}'
+ c_id.append(('{:0' + str(settings.ISHTAR_FINDS_INDEX_ZERO_LEN) + 'd}'
).format(self.index))
return settings.JOINT.join(c_id)
@@ -2616,7 +2616,7 @@ class Find(BulkUpdatedItem, ValueGetter, DocumentItem, BaseHistorizedItem,
"""
bfs = self.base_finds
profile = get_current_profile()
- if profile.find_index == u'O':
+ if profile.find_index == 'O':
bfs = bfs.filter(
context_record__operation__pk__isnull=False).order_by(
'-context_record__operation__start_date')
@@ -2625,7 +2625,7 @@ class Find(BulkUpdatedItem, ValueGetter, DocumentItem, BaseHistorizedItem,
operation = bfs.all()[0].context_record.operation
q = Find.objects \
.filter(base_finds__context_record__operation=operation)
- elif profile.find_index == u'CR':
+ elif profile.find_index == 'CR':
bfs = bfs.filter(
context_record__pk__isnull=False).order_by(
'context_record__pk')