From d28483bd5d4c7de7f4c8cb367fe5a4ef697934de Mon Sep 17 00:00:00 2001 From: Ben Silverman Date: Fri, 3 Nov 2023 12:34:00 -0400 Subject: [PATCH] Add scope option to search (#944) --- apps/readux/forms.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/apps/readux/forms.py b/apps/readux/forms.py index b093a186c..3c2e810e0 100644 --- a/apps/readux/forms.py +++ b/apps/readux/forms.py @@ -57,6 +57,21 @@ class ManifestSearchForm(forms.Form): }, ), ) + scope = forms.ChoiceField( + label="Limit search to", + required=False, + initial="all", + choices=( + ("all", "All"), + ("metadata", "Metadata only"), + ("text", "Textual contents only"), + ), + widget=forms.Select( + attrs={ + "class": "uk-select", + }, + ), + ) language = FacetedMultipleChoiceField( label="Language", required=False,