Commit 4b2b777d authored by Romain Courteaud's avatar Romain Courteaud

[erp5_web_renderjs_ui] Trim search query

This will drop any query containing only some space characters
parent 8f64705a
......@@ -169,9 +169,14 @@
.declareMethod(\'getContent\', function () {\n
var input = this.props.element.querySelector(\'input\'),\n
value = input.value,\n
result = {};\n
result[input.getAttribute(\'name\')] = input.value;\n
if (value) {\n
value = value.trim();\n
result[input.getAttribute(\'name\')] = value;\n
return result;\n
......@@ -296,7 +301,7 @@
<key> <string>actor</string> </key>
<value> <string>romain</string> </value>
<value> <string>zope</string> </value>
<key> <string>comment</string> </key>
......@@ -310,7 +315,7 @@
<key> <string>serial</string> </key>
<value> <string>945.61050.10650.48093</string> </value>
<value> <string>946.44927.40202.16725</string> </value>
<key> <string>state</string> </key>
......@@ -328,8 +333,8 @@
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