[FIX] consider typeless action as ir.actions.act_window_close
authorAntony Lesuisse <al@openerp.com>
Wed, 28 Sep 2011 22:47:05 +0000 (00:47 +0200)
committerAntony Lesuisse <al@openerp.com>
Wed, 28 Sep 2011 22:47:05 +0000 (00:47 +0200)
bzr revid: al@openerp.com-20110928224705-cf4dwwrz85oqv8y8

addons/web/controllers/main.py

index ead27b2..02371bc 100644 (file)
@@ -494,6 +494,9 @@ def clean_action(req, action):
     if isinstance(action.get('domain'), basestring):
         action['domain'] = eval( action['domain'], eval_ctx ) or []
 
+    if 'type' not in action:
+       action['type'] = 'ir.actions.act_window_close'
+
     if action['type'] == 'ir.actions.act_window':
         return fix_view_modes(action)
     return action