Commit c00685e9 authored by Vincent Pelletier's avatar Vincent Pelletier

Add a new method to Operator interface.

  This allows setting different renderings for SQL and SearchText.

git-svn-id: 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent eccba80d
......@@ -66,6 +66,11 @@ class IOperator(Interface):
def getOperator():
Accessor for operator's text representation.
Accessor for operator's SQL representation.
def getSearchTextOperator():
Accessor for operator's SearchText representation.
......@@ -100,12 +100,18 @@ class OperatorBase(object):
__implements__ = IOperator
def __init__(self, operator):
def __init__(self, operator, operator_search_text=None):
self.operator = operator
if operator_search_text is None:
operator_search_text = operator
self.operator_search_text = operator_search_text
def getOperator(self):
return self.operator
def getOperatorSearchText(self):
return self.operator_search_text
def _render(self, column, value):
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