1 # -*- coding: utf-8 -*-
2 ##############################################################################
4 # OpenERP, Open Source Management Solution
5 # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
7 # This program is free software: you can redistribute it and/or modify
8 # it under the terms of the GNU Affero General Public License as
9 # published by the Free Software Foundation, either version 3 of the
10 # License, or (at your option) any later version.
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU Affero General Public License for more details.
17 # You should have received a copy of the GNU Affero General Public License
18 # along with this program. If not, see <http://www.gnu.org/licenses/>.
20 ##############################################################################
23 from tools.translate import _
25 class base_module_configuration(osv.osv_memory):
27 _name = "base.module.configuration"
29 def start(self, cr, uid, ids, context=None):
30 todo_ids = self.pool.get('ir.actions.todo').search(cr, uid, ['|', ('state', '=', 'open'), ('restart', '=', 'always')])
32 # When there is no wizard todo it will display message
33 data_obj = self.pool.get('ir.model.data')
34 result = data_obj._get_id(cr, uid, 'base', 'view_base_module_configuration_form')
35 view_id = data_obj.browse(cr, uid, result).res_id
37 'name': _('System Configuration done'),
40 'res_model': 'base.module.configuration',
42 'type': 'ir.actions.act_window',
45 # Run the config wizards
46 config_pool = self.pool.get('res.config')
47 return config_pool.start(cr, uid, ids, context=context)
49 base_module_configuration()
51 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: