Commit 5dc9b41d authored by Romain Courteaud's avatar Romain Courteaud

Add a simple string field for full text keys.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@21616 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent cefbb74b
...@@ -172,25 +172,8 @@ def getSearchDialog(self, REQUEST=None): ...@@ -172,25 +172,8 @@ def getSearchDialog(self, REQUEST=None):
def addFullTextStringField(field_id, field_title): def addFullTextStringField(field_id, field_title):
raise NotImplementedError
addStringField(field_id, field_title) addStringField(field_id, field_title)
request_key = field_id
field_id = 'your_%s_search_mode' % field_id
temp_form.manage_addField(field_id, field_title, 'ProxyField')
field = temp_form._getOb(field_id)
field.manage_edit_xmlrpc(dict(
form_id='Base_viewDialogFieldLibrary',
field_id='your_category'))
field._surcharged_edit(dict(title=N_('${key} ${usage}', mapping=dict(key=N_(title), usage=N_('Search Mode')))))
field._surcharged_tales(
dict(
default=TALESMethod(
'here/portal_selections/%s/%s_search_mode | nothing'
% (selection_name, request_key))),
['title', 'items', 'default'])
def addKeywordSearchStringField(column_id, column_title, def addKeywordSearchStringField(column_id, column_title,
default_search_key='ExactMatch'): default_search_key='ExactMatch'):
addStringField(column_id, column_title) addStringField(column_id, column_title)
......
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