Merge lp:~therp-nl/ocb-server/7.0-lp1179839-many2many_attributes_in_client into lp:ocb-server

Proposed by Stefan Rijnhart (Opener)
Status: Work in progress
Proposed branch: lp:~therp-nl/ocb-server/7.0-lp1179839-many2many_attributes_in_client
Merge into: lp:ocb-server
Diff against target: 13 lines (+3/-0)
1 file modified
openerp/osv/orm.py (+3/-0)
To merge this branch: bzr merge lp:~therp-nl/ocb-server/7.0-lp1179839-many2many_attributes_in_client
Reviewer Review Type Date Requested Status
Stefan Rijnhart (Opener) Approve
Review via email: mp+198360@code.launchpad.net

Description of the change

Requirement to support edit/create/delete attributes on the many2many tree widget. Client side here: https://code.launchpad.net/~hbrunn/ocb-web/lp1179839/+merge/163661

To post a comment you must log in.
Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) wrote :

Approving as I was not the author.

review: Approve

Unmerged revisions

5190. By Holger Brunn (Therp)

[FIX] Server side support for honoring edit/delete/create attributes on m2m in web

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'openerp/osv/orm.py'
2--- openerp/osv/orm.py 2013-12-09 18:47:18 +0000
3+++ openerp/osv/orm.py 2013-12-10 09:58:39 +0000
4@@ -1785,6 +1785,9 @@
5 node.remove(f)
6 ctx = context.copy()
7 ctx['base_model_name'] = self._name
8+ if column._type == 'many2many':
9+ for action in ['create', 'edit', 'delete']:
10+ f.set(action, f.get(action, 'true'))
11 xarch, xfields = relation.__view_look_dom_arch(cr, user, f, view_id, ctx)
12 views[str(f.tag)] = {
13 'arch': xarch,

Subscribers

People subscribed via source and target branches

to status/vote changes: