Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
2 Відповіді
16484 Переглядів

We are trying to develop a new type of navigation page. But here we need to be able to detect as to which modules are installed in OpenERP.

How can we detect them?

Аватар
Відмінити
Найкраща відповідь

In your custom code you can just write down the following code to find out the installed modules.

    installed_module_ids = self.pool.get('ir.module.module').search(cr,uid,[('state','=','installed')])

It will give you ids of installed modules. Then after you can use read or browse to get another details of those modules. 

Аватар
Відмінити

We can restrict the search: is_crm_installed = self.pool.get('ir.module.module').search(cr,uid,[('state','=','installed'), ('name','=','crm'])

Найкраща відповідь
Check from Controller

is_gift_card_installed = request.env['ir.module.module'].search([('state', '=', 'installed'), ('name', '=', 'website_sale_gift_card')])


Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
0
серп. 19
10430
3
лип. 25
1995
3
трав. 25
3480
2
черв. 25
4037
0
черв. 21
2346