~openerp-dev/openobject-server/trunk-improve-configuration-warnings-tpa

« back to all changes in this revision

Viewing changes to openerp/addons/base/module/module.py

  • Committer: Sunil Sharma
  • Date: 2014-05-09 11:18:54 UTC
  • mfrom: (5214.1.2 trunk)
  • Revision ID: ssh@tinyerp.com-20140509111854-rz9rujk3g0oqien6
[mrg]:lp:openobject-server

Show diffs side-by-side

added added

removed removed

Lines of Context:
144
144
    _rec_name = "shortdesc"
145
145
    _description = "Module"
146
146
 
 
147
    def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
 
148
         res = super(module, self).fields_view_get(cr, uid, view_id=view_id, view_type=view_type, context=context, toolbar=toolbar, submenu=False)
 
149
         result = self.pool.get('ir.model.data').get_object_reference(cr, uid, 'base', 'action_server_module_immediate_install')[1]
 
150
         if view_type == 'form':
 
151
             if res.get('toolbar',False):
 
152
                 list = [rec for rec in res['toolbar']['action'] if rec.get('id', False) != result]
 
153
                 res['toolbar'] = {'action': list}
 
154
         return res
 
155
 
147
156
    @classmethod
148
157
    def get_module_info(cls, name):
149
158
        info = {}