[FIX] allow to create menu executing ir.actions.server
[IMP] pyflackes bzr revid: chs@tinyerp.com-20100204172436-icchmn39spmew41g
This commit is contained in:
@@ -21,7 +21,6 @@
|
||||
##############################################################################
|
||||
|
||||
from osv import fields, osv
|
||||
from osv.orm import browse_null, browse_record
|
||||
import re
|
||||
import tools
|
||||
|
||||
@@ -106,7 +105,7 @@ class ir_ui_menu(osv.osv):
|
||||
if data:
|
||||
model_field = { 'ir.actions.act_window': 'res_model',
|
||||
'ir.actions.report.custom': 'model',
|
||||
'ir.actions.report.xml': 'model',
|
||||
'ir.actions.report.xml': 'model',
|
||||
'ir.actions.wizard': 'model',
|
||||
'ir.actions.server': 'model_id',
|
||||
}
|
||||
@@ -168,8 +167,8 @@ class ir_ui_menu(osv.osv):
|
||||
('res_id', '=', id),
|
||||
])
|
||||
for iv in ir_values_obj.browse(cr, uid, ids):
|
||||
new_id = ir_values_obj.copy(cr, uid, iv.id,
|
||||
default={'res_id': res}, context=context)
|
||||
ir_values_obj.copy(cr, uid, iv.id, default={'res_id': res},
|
||||
context=context)
|
||||
return res
|
||||
|
||||
def _action(self, cursor, user, ids, name, arg, context=None):
|
||||
@@ -242,6 +241,7 @@ class ir_ui_menu(osv.osv):
|
||||
('ir.actions.act_window', 'ir.actions.act_window'),
|
||||
('ir.actions.wizard', 'ir.actions.wizard'),
|
||||
('ir.actions.url', 'ir.actions.url'),
|
||||
('ir.actions.server', 'ir.actions.server'),
|
||||
]),
|
||||
}
|
||||
_defaults = {
|
||||
|
||||
Reference in New Issue
Block a user