diff options
author | Philip Sargent <philip.sargent@gmail.com> | 2022-12-29 13:54:38 +0000 |
---|---|---|
committer | Philip Sargent <philip.sargent@gmail.com> | 2022-12-29 13:54:38 +0000 |
commit | 78740a1fc07d15b042299411b6a7f5ca2b3c45c1 (patch) | |
tree | 2b6f4015b2ee4c39e20786b33a36e8e807182dac /core/views/logbooks.py | |
parent | b131e567b5a6a42de43874ff7fe92c2daa1dfc74 (diff) | |
download | troggle-78740a1fc07d15b042299411b6a7f5ca2b3c45c1.tar.gz troggle-78740a1fc07d15b042299411b6a7f5ca2b3c45c1.tar.bz2 troggle-78740a1fc07d15b042299411b6a7f5ca2b3c45c1.zip |
remove logbooksearch, use site-wide search on server
Diffstat (limited to 'core/views/logbooks.py')
-rw-r--r-- | core/views/logbooks.py | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/core/views/logbooks.py b/core/views/logbooks.py index 375ec6e..40d664c 100644 --- a/core/views/logbooks.py +++ b/core/views/logbooks.py @@ -226,22 +226,6 @@ def logbookentry(request, date, slug): print(msg) return render(request, 'errors/generic.html',{'message':msg}) -def logbookSearch(request, extra): - '''This uses Django free text search of a text field to find the list of logbook entries. - We need to create a search box form to set up the ?q=searchterms URL GET - This has not been touched since we were running on Django 1.11 and probably earlier.. - A better idea is just to delete it and rely on he full text search that Wookey did. - ''' - query_string = '' - found_entries = None - if ('q' in request.GET) and request.GET['q'].strip(): - query_string = request.GET['q'] - entry_query = search.get_query(query_string, ['text','title',]) - found_entries = LogbookEntry.objects.filter(entry_query) - - return render(request,'logbooksearch.html', - { 'query_string': query_string, 'found_entries': found_entries, }) - def get_people(request, expeditionslug): exp = Expedition.objects.get(year = expeditionslug) return render(request,'options.html', {"items": [(pe.slug, pe.name) for pe in exp.personexpedition_set.all()]}) |