diff --git a/sync/__manifest__.py b/sync/__manifest__.py index 289a59c7..68d2c25f 100644 --- a/sync/__manifest__.py +++ b/sync/__manifest__.py @@ -8,7 +8,7 @@ "summary": """Synchronize something with anything: SystemX↔Odoo, Odoo1↔Odoo2, SystemX↔SystemY. ETL/ESB tool similar to OCA/connector, but more flexible""", "category": "Extra Tools", "images": ["images/sync-studio.jpg"], - "version": "15.0.6.2.0", + "version": "16.0.6.2.0", "application": True, "author": "IT Projects Labs, Ivan Yelizariev", "support": "help@itpp.dev", diff --git a/sync/migrations/15.0.6.0.0/post-migrate.py b/sync/migrations/15.0.6.0.0/post-migrate.py deleted file mode 100644 index 04b809ff..00000000 --- a/sync/migrations/15.0.6.0.0/post-migrate.py +++ /dev/null @@ -1,30 +0,0 @@ -import logging - -from odoo import SUPERUSER_ID, api - -_logger = logging.getLogger(__name__) - - -def migrate(cr, version): - # Convert eval_context selection values into sync.project.context records - # Copy eval_context values into eval_contexts - with api.Environment.manage(): - env = api.Environment(cr, SUPERUSER_ID, {}) - _logger.info( - "Copying eval_context selection values into sync.project.context records" - ) - env["ir.model.fields.selection"]._update_sync_project_context() - sync_projects = env["sync.project"].with_context(active_test=False).search([]) - for sync_project in sync_projects: - if not sync_project.eval_context: - continue - sync_project_context = env["sync.project.context"].search( - [("name", "=", sync_project.eval_context)], limit=1 - ) - if not sync_project_context: - continue - sync_project.write( - { - "eval_contexts": [(6, 0, sync_project_context.ids)], - } - )