GR tweaks anticipating exact search

This commit is contained in:
GRiker 2010-02-12 11:11:23 -07:00
parent 6060faa574
commit d9e5ac9a05

View File

@ -900,9 +900,7 @@ class EPUB_MOBI(CatalogPlugin):
self.opts.sort_by = 'title' self.opts.sort_by = 'title'
# Merge opts.exclude_tag with opts.search_text # Merge opts.exclude_tags with opts.search_text
# What if no exclude tags?
empty_exclude_tags = False if len(self.opts.exclude_tags) else True empty_exclude_tags = False if len(self.opts.exclude_tags) else True
search_phrase = '' search_phrase = ''
if not empty_exclude_tags: if not empty_exclude_tags:
@ -910,6 +908,7 @@ class EPUB_MOBI(CatalogPlugin):
search_terms = [] search_terms = []
for tag in exclude_tags: for tag in exclude_tags:
search_terms.append("tag:%s" % tag) search_terms.append("tag:%s" % tag)
#search_terms.append("tag:=%s" % tag)
search_phrase = "not (%s)" % " or ".join(search_terms) search_phrase = "not (%s)" % " or ".join(search_terms)
# If a list of ids are provided, don't use search_text # If a list of ids are provided, don't use search_text