Fix search on country code
bzr revid: ced-d7ae01f6d391b5bf8899b177830894169b672621
This commit is contained in:
@@ -53,8 +53,8 @@ class Country(osv.osv):
|
||||
if not context:
|
||||
context={}
|
||||
ids = False
|
||||
if len(name) <= 2:
|
||||
ids = self.search(cr, user, [('code', '=', name)] + args,
|
||||
if len(name) == 2:
|
||||
ids = self.search(cr, user, [('code', '=', name.upper())] + args,
|
||||
limit=limit, context=context)
|
||||
if not ids:
|
||||
ids = self.search(cr, user, [('name', operator, name)] + args,
|
||||
|
||||
Reference in New Issue
Block a user