summaryrefslogtreecommitdiff
path: root/archaeological_context_records
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2018-09-18 11:18:11 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2018-10-24 12:06:08 +0200
commitd33cf24f1bdf116cb81aeb45804593058d9ebbdb (patch)
treed0bd953ebe547522206cb9a01ebe1b33dcaa89c4 /archaeological_context_records
parent985dfb92cbadf5f8fce43dfcd08fb44c3b2165f3 (diff)
downloadIshtar-d33cf24f1bdf116cb81aeb45804593058d9ebbdb.tar.bz2
Ishtar-d33cf24f1bdf116cb81aeb45804593058d9ebbdb.zip
Display pined search on search input
Diffstat (limited to 'archaeological_context_records')
-rw-r--r--archaeological_context_records/models.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/archaeological_context_records/models.py b/archaeological_context_records/models.py
index 60f8fce1b..b0e2256a2 100644
--- a/archaeological_context_records/models.py
+++ b/archaeological_context_records/models.py
@@ -282,6 +282,10 @@ class ContextRecord(BulkUpdatedItem, BaseHistorizedItem,
pgettext_lazy("key for text search", u"operation-code"),
'operation__operation_code'
),
+ 'operation__cached_label': (
+ pgettext_lazy("key for text search", u"operation"),
+ 'operation__cached_label'
+ ),
'archaeological_site': (
pgettext_lazy("key for text search", u"site"),
'archaeological_site__cached_label__icontains'
@@ -319,6 +323,10 @@ class ContextRecord(BulkUpdatedItem, BaseHistorizedItem,
"identification__label", "activity__label",
"excavation_technic__label"]
M2M_SEARCH_VECTORS = ["datings__period__label"]
+ UP_MODEL_QUERY = {
+ "OPE": (pgettext_lazy("key for text search", u"operation"),
+ 'cached_label'),
+ }
history = HistoricalRecords()
# fields