[FIX] cleanup of toolbar actions during fields_view_get

bzr revid: xmo@openerp.com-20110908070309-bbwmqxmwmmj06srj
This commit is contained in:
Xavier Morel 2011-09-08 09:03:09 +02:00
parent e8e6a91431
commit a0a1ea0cfa
1 changed files with 8 additions and 3 deletions

View File

@ -802,9 +802,14 @@ class View(openerpweb.Controller):
We need to clean all those actions in order to ensure correct
round-tripping
"""
for section in toolbar.keys():
toolbar[section] = [clean_action(req, action)
for action in toolbar[section]]
for actions in toolbar.itervalues():
for action in actions:
if 'context' in action:
action['context'] = self.parse_context(
action['context'], req.session)
if 'domain' in action:
action['domain'] = self.parse_domain(
action['domain'], req.session)
@openerpweb.jsonrequest
def add_custom(self, req, view_id, arch):