diff options
| author | Christophe Simonis <chs@odoo.com> | 2018-03-01 17:26:43 +0100 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2018-03-01 17:26:43 +0100 |
| commit | b04c8eae6bf8a0da4df734ac8db36cb04aec9802 (patch) | |
| tree | 5f75f4c32e6f2a770cb0de62271d521880dfacca /addons/stock | |
| parent | 9a1d71ce95fd3c0476aee358b37e29fd7cd8edc7 (diff) | |
| parent | 153ae5e8b834345673a1fa23e0724e4c67a66df2 (diff) | |
[MERGE] forward port branch saas-14 up to 153ae5e8b83
Diffstat (limited to 'addons/stock')
| -rw-r--r-- | addons/stock/__init__.py | 14 | ||||
| -rw-r--r-- | addons/stock/__manifest__.py | 1 |
2 files changed, 14 insertions, 1 deletions
diff --git a/addons/stock/__init__.py b/addons/stock/__init__.py index ddac13e1a0e..bb5953c4834 100644 --- a/addons/stock/__init__.py +++ b/addons/stock/__init__.py @@ -4,4 +4,16 @@ import controllers import models import report -import wizard
\ No newline at end of file +import wizard + + +from odoo import api, SUPERUSER_ID + + +# TODO: Apply proper fix & remove in master +def pre_init_hook(cr): + env = api.Environment(cr, SUPERUSER_ID, {}) + env['ir.model.data'].search([ + ('model', 'like', '%stock%'), + ('module', '=', 'stock') + ]).unlink() diff --git a/addons/stock/__manifest__.py b/addons/stock/__manifest__.py index 9729e82be32..8f9a088fbf9 100644 --- a/addons/stock/__manifest__.py +++ b/addons/stock/__manifest__.py @@ -101,4 +101,5 @@ Dashboard / Reports for Inventory Management will include: 'installable': True, 'application': True, 'auto_install': False, + 'pre_init_hook': 'pre_init_hook', } |
