def _search_view(self, cr, uid, ids, name, arg, context=None):
res = {}
for act in self.browse(cr, uid, ids, context=context):
- field_get = self.pool.get(act.res_model).fields_view_get(cr, uid,
+ field_get = self.pool[act.res_model].fields_view_get(cr, uid,
act.search_view_id and act.search_view_id.id or False,
'search', context=context)
res[act.id] = str(field_get)
act_type = self.pool.get('ir.actions.actions').read(cr, uid, wizard.action_id.id, ['type'], context=context)
res = self.pool.get(act_type['type']).read(cr, uid, wizard.action_id.id, [], context=context)
- if act_type<>'ir.actions.act_window':
+ if act_type['type'] != 'ir.actions.act_window':
return res
res.setdefault('context','{}')
res['nodestroy'] = True
'params': {'modules': to_install_missing_names},
}
- config = self.pool.get('res.config').next(cr, uid, [], context=context) or {}
+ # After the uninstall/install calls, the self.pool is no longer valid.
+ # So we reach into the RegistryManager directly.
+ res_config = openerp.modules.registry.RegistryManager.get(cr.dbname)['res.config']
+ config = res_config.next(cr, uid, [], context=context) or {}
if config.get('type') not in ('ir.actions.act_window_close',):
return config