Commit d896a144 authored by Romain Courteaud's avatar Romain Courteaud

Do not try to add a full text search if it was already provided by the listbox.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@42992 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 94c35bd2
......@@ -233,8 +233,11 @@ def getSearchDialog(self, REQUEST=None):
search_list = ListBoxListRenderer(
listbox.widget, listbox, request).getSearchColumnIdSet()
full_text_search_added = False
for column_id, column_title in column_list:
# is it a base category ?
if column_id == "SearchableText":
full_text_search_added = True
short_column_id = column_id
# strip the usuale default_ and _title that are on standard fields.
if short_column_id.endswith('_translated_title'):
......@@ -340,6 +343,7 @@ def getSearchDialog(self, REQUEST=None):
['title', 'items', 'default'])
if not full_text_search_added:
addFullTextStringField('SearchableText', 'Full Text Search')
# Order fields
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment