Merge lp:~openerp-dev/openobject-addons/trunk-bug-1029316-amp into lp:openobject-addons

Proposed by Amit Parik
Status: Merged
Merged at revision: 7632
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-bug-1029316-amp
Merge into: lp:openobject-addons
Diff against target: 20 lines (+2/-1)
1 file modified
account/account.py (+2/-1)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-bug-1029316-amp
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+117229@code.launchpad.net

Description of the change

Hello,

This branch Fixed the unicode decode error on search of account.account object.
When search the account form invoice line and passed the name like "prestación prestación" it will raised the error as reported in bug.This fix will solved it.

Thank you!

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'account/account.py'
2--- account/account.py 2012-07-25 19:26:32 +0000
3+++ account/account.py 2012-07-30 09:42:27 +0000
4@@ -30,6 +30,7 @@
5 import decimal_precision as dp
6 from tools.translate import _
7 from tools.float_utils import float_round
8+import tools
9
10 _logger = logging.getLogger(__name__)
11
12@@ -225,7 +226,7 @@
13 while pos < len(args):
14
15 if args[pos][0] == 'code' and args[pos][1] in ('like', 'ilike') and args[pos][2]:
16- args[pos] = ('code', '=like', str(args[pos][2].replace('%', ''))+'%')
17+ args[pos] = ('code', '=like', tools.ustr(args[pos][2].replace('%', ''))+'%')
18 if args[pos][0] == 'journal_id':
19 if not args[pos][2]:
20 del args[pos]

Subscribers

People subscribed via source and target branches

to all changes: