[FIX] database_cleanup: ignore to_buy modules
Since 12.0, some virtual modules are created as an incentive to buy enterprise Hide installation warningpull/2684/head
parent
13c2a780b5
commit
0daeb7a268
|
@ -63,8 +63,9 @@ class CleanupPurgeWizardModule(models.TransientModel):
|
||||||
@api.model
|
@api.model
|
||||||
def find(self):
|
def find(self):
|
||||||
res = []
|
res = []
|
||||||
for module in self.env['ir.module.module'].search([]):
|
IrModule = self.env['ir.module.module']
|
||||||
if get_module_path(module.name):
|
for module in IrModule.search([('to_buy', '=', False)]):
|
||||||
|
if get_module_path(module.name, display_warning=False):
|
||||||
continue
|
continue
|
||||||
if module.state == 'uninstalled':
|
if module.state == 'uninstalled':
|
||||||
self.env['cleanup.purge.line.module'].create({
|
self.env['cleanup.purge.line.module'].create({
|
||||||
|
|
Loading…
Reference in New Issue