Browse Source

Merge PR #1770 into 12.0

Signed-off-by LoisRForgeFlow
12.0-mig-module_prototyper_last
OCA-git-bot 5 years ago
parent
commit
d17b8b829a
  1. 5
      base_conditional_image/models/abstract_image.py
  2. 1
      base_conditional_image/models/image.py
  3. 1
      database_cleanup/tests/test_database_cleanup.py

5
base_conditional_image/models/abstract_image.py

@ -7,17 +7,18 @@ from odoo.tools.safe_eval import safe_eval
class AbstractConditionalImage(models.AbstractModel):
_name = 'abstract.conditional.image'
_description = 'Abstract image'
image = fields.Binary(
compute='_compute_image', string="Image",
store=False, readonly=True
)
image_medium = fields.Binary(
compute='_compute_image', string="Image",
compute='_compute_image', string="Medium-sized image",
store=False, readonly=True
)
image_small = fields.Binary(
compute='_compute_image', string="Image",
compute='_compute_image', string="Small-sized image",
store=False, readonly=True
)

1
base_conditional_image/models/image.py

@ -7,6 +7,7 @@ from odoo.exceptions import ValidationError
class Image(models.Model):
_name = 'image'
_description = 'Image'
name = fields.Char('Name', required=True)
model_name = fields.Char('Model Name', required=True)

1
database_cleanup/tests/test_database_cleanup.py

@ -95,6 +95,7 @@ class TestDatabaseCleanup(TransactionCase):
# reference to it
original_registry = Registry.registries[self.env.cr.dbname]
config.options['test_enable'] = False
with mute_logger('odoo.modules.graph', 'odoo.modules.loading'):
purge_modules.purge_all()
config.options['test_enable'] = True
# must be removed by the wizard

Loading…
Cancel
Save