diff options
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 |
commit | e4886af839af1194d0153c99234751d7cd4fde27 (patch) | |
tree | d0bd953ebe547522206cb9a01ebe1b33dcaa89c4 /archaeological_context_records/models.py | |
parent | 1ca13841328bf1aa661b0d6bbb69c4e84950d9df (diff) | |
download | Ishtar-e4886af839af1194d0153c99234751d7cd4fde27.tar.bz2 Ishtar-e4886af839af1194d0153c99234751d7cd4fde27.zip |
Display pined search on search input
Diffstat (limited to 'archaeological_context_records/models.py')
-rw-r--r-- | archaeological_context_records/models.py | 8 |
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 |