From a634566637d52380f1289be46bdcfd9e636f31af Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Fri, 23 Feb 2024 17:07:51 +0100 Subject: ✨ document related search: search by document type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ishtar_common/forms.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'ishtar_common/forms.py') diff --git a/ishtar_common/forms.py b/ishtar_common/forms.py index b81b42bc6..3dffc77c4 100644 --- a/ishtar_common/forms.py +++ b/ishtar_common/forms.py @@ -1029,11 +1029,16 @@ class DocumentItemSelect(ImportSelect): documents__associated_url__isnull = forms.NullBooleanField( label=_("Has a web address?") ) + documents__source_type = forms.ChoiceField(label=_("Document - Type"), choices=[]) CURRENT_FIELDS = [ "documents__image__isnull", "documents__associated_file__isnull", "documents__associated_url__isnull", + "documents__source_type", ] + ImportSelect.CURRENT_FIELDS + TYPES = [ + FieldType("documents__source_type", models.SourceType), + ] + ImportSelect.TYPES _explicit_ordering = True -- cgit v1.2.3