Merge lp:~openerp-dev/openobject-addons/6.1-bug-1033505-vba into lp:openobject-addons/6.1

Proposed by Vijaykumar Baladaniya (OpenERP)
Status: Approved
Approved by: Anto
Approved revision: 6976
Proposed branch: lp:~openerp-dev/openobject-addons/6.1-bug-1033505-vba
Merge into: lp:openobject-addons/6.1
Diff against target: 14 lines (+2/-2)
1 file modified
analytic/ (+2/-2)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/6.1-bug-1033505-vba
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email:

Description of the change

Hello Sir,

    I have improve the code to account_analytic_account for select a parent project when create project. Kindly review the code.

Vijay Baladaniya

To post a comment you must log in.
Revision history for this message
Anto (abourguignon) wrote :

With this fix, we only fetch the analytic accounts that the current user has the right to read, avoiding an access error when calling name_get(). Seems ok !

Unmerged revisions

6976. By Vijaykumar Baladaniya (OpenERP)

[FIX] Create project while select parent project display its list proper.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'analytic/'
2--- analytic/ 2012-02-16 18:01:11 +0000
3+++ analytic/ 2012-09-13 11:32:19 +0000
4@@ -257,8 +257,8 @@
5 if context is None:
6 context={}
7 if context.get('current_model') == 'project.project':
8- cr.execute("select analytic_account_id from project_project")
9- project_ids = [x[0] for x in cr.fetchall()]
10+ project_obj = self.pool.get("account.analytic.account")
11+ project_ids =, uid, args)
12 return self.name_get(cr, uid, project_ids, context=context)
13 if name:
14 account =, uid, [('code', '=', name)] + args, limit=limit, context=context)