Change range operator of search widget to be included

issue3997
review11311003
This commit is contained in:
Cédric Krier committed 2014-07-09 00:43:21 +02:00
1 parent fedf9468f9
commit d71f83bf47
4 files changed
+5 -5

No files matched your search

+1
View File
@@ -1,3 +1,4 @@
* Change range operator of search widget to be included
* Explicitly set value of parent field
Version 3.2.0 - 2014-04-21
+1 -2
View File
@@ -794,8 +794,7 @@ A range of number values can be set using `..`.
For example: ``Amount: 100..500``
It will find all records with `Amount` between `100` and `500` (left
included and right excluded)
It will find all records with `Amount` between `100` and `500` included.
There are two wildcards:
+2 -2
View File
@@ -1082,7 +1082,7 @@ class DomainParser(object):
rvalue = convert_value(field, rvalue)
yield iter([
(field_name, '>=', lvalue),
(field_name, '<', rvalue),
(field_name, '<=', rvalue),
])
continue
if isinstance(value, list):
@@ -1355,7 +1355,7 @@ def test_parse_clause():
]
assert rlist(dom.parse_clause([('Integer', None, '3..5')])) == [[
('integer', '>=', 3),
('integer', '<', 5),
('integer', '<=', 5),
]]
assert rlist(dom.parse_clause([('Reference', None, 'foo')])) == [
('reference', 'ilike', '%foo%'),
@@ -36,7 +36,7 @@ class Dates(gtk.HBox):
elif from_:
return '>=%s' % quote(from_)
elif to:
return '<%s' % quote(to)
return '<=%s' % quote(to)
class Selection(gtk.ScrolledWindow):