Commit 8acfb199 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

full_text: revert the change of _renderValueAsSearchText().

parent 2c9b6c5c
...@@ -50,7 +50,7 @@ class FullTextKey(DefaultKey): ...@@ -50,7 +50,7 @@ class FullTextKey(DefaultKey):
return False return False
def _renderValueAsSearchText(self, value, operator): def _renderValueAsSearchText(self, value, operator):
return '"%s"' % value.replace('"', '\\"') return '(%s)' % (value, )
def _processSearchValue(self, search_value, logical_operator, def _processSearchValue(self, search_value, logical_operator,
comparison_operator): comparison_operator):
...@@ -60,8 +60,8 @@ class FullTextKey(DefaultKey): ...@@ -60,8 +60,8 @@ class FullTextKey(DefaultKey):
mode, make the operator for that value be 'match_boolean'. mode, make the operator for that value be 'match_boolean'.
""" """
operator_value_dict, logical_operator, parsed = \ operator_value_dict, logical_operator, parsed = \
SearchKey._processSearchValue(self, search_value, logical_operator, super(FullTextKey, self)._processSearchValue(
comparison_operator) search_value, logical_operator, comparison_operator)
new_value_list = [] new_value_list = []
append = new_value_list.append append = new_value_list.append
for value in operator_value_dict.pop('match', []): for value in operator_value_dict.pop('match', []):
......
...@@ -39,7 +39,7 @@ class MroongaFullTextKey(DefaultKey): ...@@ -39,7 +39,7 @@ class MroongaFullTextKey(DefaultKey):
return False return False
def _renderValueAsSearchText(self, value, operator): def _renderValueAsSearchText(self, value, operator):
return '"%s"' % value.replace('"', '\\"') return '(%s)' % (value, )
def _processSearchValue(self, search_value, logical_operator, def _processSearchValue(self, search_value, logical_operator,
comparison_operator): comparison_operator):
......
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