diff --git a/addons/account/migrations/12.0.1.1/openupgrade_analysis.txt b/addons/account/migrations/12.0.1.1/openupgrade_analysis.txt index 71fa5c41bf40..97dccf80bca1 100644 --- a/addons/account/migrations/12.0.1.1/openupgrade_analysis.txt +++ b/addons/account/migrations/12.0.1.1/openupgrade_analysis.txt @@ -20,7 +20,7 @@ obsolete model report.account.report_tax [abstract] obsolete model report.account.report_trialbalance [abstract] obsolete model wizard.multi.charts.accounts [transient] new model account.fiscal.year -new model account.incoterms (renamed from stock.incoterms) +new model account.incoterms (renamed from stock.incoterms in module stock) new model account.invoice.import.wizard [transient] new model account.invoice.send [transient] new model account.reconciliation.widget [abstract] diff --git a/addons/crm/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/crm/migrations/12.0.1.0/openupgrade_analysis.txt index d9664f2344d5..569588dd5930 100644 --- a/addons/crm/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/crm/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,4 +1,6 @@ ---Models in module 'crm'--- +model base.partner.merge.automatic.wizard (moved to base) [transient] +model base.partner.merge.line (moved to base) [transient] obsolete model crm.opportunity.report [sql_view] ---Fields in module 'crm'--- crm / crm.lead / activity_date_deadline (date) : not related anymore diff --git a/addons/mail/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/mail/migrations/12.0.1.0/openupgrade_analysis.txt index 2f7c96ac2a06..3a9d4b57db5b 100644 --- a/addons/mail/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/mail/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,4 +1,6 @@ ---Models in module 'mail'--- +model mail.test (moved to test_mail) +model mail.test.simple (moved to test_mail) new model mail.blacklist new model mail.blacklist.mixin [abstract] new model mail.moderation diff --git a/addons/product/migrations/12.0.1.2/openupgrade_analysis.txt b/addons/product/migrations/12.0.1.2/openupgrade_analysis.txt index 224fcafe85b2..277c1e8f7825 100644 --- a/addons/product/migrations/12.0.1.2/openupgrade_analysis.txt +++ b/addons/product/migrations/12.0.1.2/openupgrade_analysis.txt @@ -1,8 +1,8 @@ ---Models in module 'product'--- obsolete model product.attribute.line (renamed to product.template.attribute.line) obsolete model product.attribute.price (renamed to product.template.attribute.value) -obsolete model product.uom (renamed to uom.uom) -obsolete model product.uom.categ (renamed to uom.category) +obsolete model product.uom (renamed to uom.uom in module uom) +obsolete model product.uom.categ (renamed to uom.category in module uom) new model product.template.attribute.exclusion new model product.template.attribute.line (renamed from product.attribute.line) new model product.template.attribute.value (renamed from product.attribute.price) diff --git a/addons/sale_management/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/sale_management/migrations/12.0.1.0/openupgrade_analysis.txt index 8622df617ccb..08cc11f049f0 100644 --- a/addons/sale_management/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/sale_management/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,7 +1,8 @@ ---Models in module 'sale_management'--- -new model sale.order.template (renamed from sale.quote.template) -new model sale.order.template.line (renamed from sale.quote.line) -new model sale.order.template.option (renamed from sale.quote.option) +model sale.order.option (moved from website_quote) +new model sale.order.template (renamed from sale.quote.template in module website_quote) +new model sale.order.template.line (renamed from sale.quote.line in module website_quote) +new model sale.order.template.option (renamed from sale.quote.option in module website_quote) ---Fields in module 'sale_management'--- sale_management / digest.digest / kpi_all_sale_total (boolean) : NEW sale_management / sale.order / sale_order_option_ids (one2many): NEW relation: sale.order.option diff --git a/addons/sale_quotation_builder/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/sale_quotation_builder/migrations/12.0.1.0/openupgrade_analysis.txt index 1e1e7e7a2daa..5e2998e759e9 100644 --- a/addons/sale_quotation_builder/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/sale_quotation_builder/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,7 +1,8 @@ ---Models in module 'sale_quotation_builder'--- -obsolete model sale.quote.line (renamed to sale.order.template.line) -obsolete model sale.quote.option (renamed to sale.order.template.option) -obsolete model sale.quote.template (renamed to sale.order.template) +model sale.order.option (moved to sale_management) +obsolete model sale.quote.line (renamed to sale.order.template.line in module sale_management) +obsolete model sale.quote.option (renamed to sale.order.template.option in module sale_management) +obsolete model sale.quote.template (renamed to sale.order.template in module sale_management) ---Fields in module 'sale_quotation_builder'--- sale_quotation_builder / product.template / quotation_only_description (html): NEW website_quote / product.product / website_description (html) : module is now 'website_sale' ('website_quote') diff --git a/addons/stock/migrations/12.0.1.1/openupgrade_analysis.txt b/addons/stock/migrations/12.0.1.1/openupgrade_analysis.txt index 52766d185664..46ddccdcf228 100644 --- a/addons/stock/migrations/12.0.1.1/openupgrade_analysis.txt +++ b/addons/stock/migrations/12.0.1.1/openupgrade_analysis.txt @@ -1,6 +1,6 @@ ---Models in module 'stock'--- obsolete model procurement.rule (renamed to stock.rule) -obsolete model stock.incoterms (renamed to account.incoterms) +obsolete model stock.incoterms (renamed to account.incoterms in module account) obsolete model stock.location.path (renamed to stock.rule) new model product.replenish [transient] new model report.stock.report_stock_rule [abstract] diff --git a/addons/test_mail/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/test_mail/migrations/12.0.1.0/openupgrade_analysis.txt index ee5b31705dac..c123dcfbc05f 100644 --- a/addons/test_mail/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/test_mail/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,7 +1,10 @@ ---Models in module 'test_mail'--- +model mail.test (moved from mail) new model mail.test.activity new model mail.test.full +model mail.test.simple (moved from mail) new model mail.test.track +model test_performance.mail (moved from test_performance) ---Fields in module 'test_mail'--- test_mail / mail.test / __last_update (datetime) : previously in module mail test_mail / mail.test / _inherits (False) : previously in module mail diff --git a/addons/uom/migrations/12.0.1.0/openupgrade_analysis.txt b/addons/uom/migrations/12.0.1.0/openupgrade_analysis.txt index 7bf330eee647..a88c52239801 100644 --- a/addons/uom/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/addons/uom/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,6 +1,6 @@ ---Models in module 'uom'--- -new model uom.category (renamed from product.uom.categ) -new model uom.uom (renamed from product.uom) +new model uom.category (renamed from product.uom.categ in module product) +new model uom.uom (renamed from product.uom in module product) ---Fields in module 'uom'--- uom / product.uom / __last_update (datetime) : previously in module product uom / product.uom / active (boolean) : previously in module product diff --git a/odoo/addons/base/migrations/12.0.1.3/openupgrade_analysis.txt b/odoo/addons/base/migrations/12.0.1.3/openupgrade_analysis.txt index 678d32e3ef52..1f42ccd55b00 100644 --- a/odoo/addons/base/migrations/12.0.1.3/openupgrade_analysis.txt +++ b/odoo/addons/base/migrations/12.0.1.3/openupgrade_analysis.txt @@ -1,5 +1,7 @@ ---Models in module 'base'--- obsolete model res.request.link +model base.partner.merge.automatic.wizard (moved from crm) [transient] +model base.partner.merge.line (moved from crm) [transient] new model ir.demo [transient] new model ir.demo_failure [transient] new model ir.demo_failure.wizard [transient] diff --git a/odoo/addons/openupgrade_records/lib/compare.py b/odoo/addons/openupgrade_records/lib/compare.py index d23de25bd631..dbdbe4b92e03 100644 --- a/odoo/addons/openupgrade_records/lib/compare.py +++ b/odoo/addons/openupgrade_records/lib/compare.py @@ -365,8 +365,8 @@ def compare_model_sets(old_records, new_records): """ reprs = collections.defaultdict(list) - new_models = [column['model'] for column in new_records] - old_models = [column['model'] for column in old_records] + new_models = {column['model']: column['module'] for column in new_records} + old_models = {column['model']: column['module'] for column in old_records} obsolete_models = [] for column in copy.copy(old_records): @@ -382,8 +382,13 @@ def compare_model_sets(old_records, new_records): reprs['general'].append('obsolete model %s [module %s]' % ( model, module_map(column['module']))) else: - text = 'obsolete model %s (renamed to %s)' % ( - model, model_map(model)) + moved_module = '' + if module_map(column['module']) != new_models[model_map( + model)]: + moved_module = ' in module %s' % new_models[model_map( + model)] + text = 'obsolete model %s (renamed to %s%s)' % ( + model, model_map(model), moved_module) if column['model_type']: text += " [%s]" % column['model_type'] reprs[module_map(column['module'])].append(text) @@ -391,6 +396,17 @@ def compare_model_sets(old_records, new_records): 'obsolete model %s (renamed to %s) [module %s]' % ( model, model_map(model), module_map(column['module']))) + else: + if module_map(column['module']) != new_models[model]: + text = 'model %s (moved to %s)' % ( + model, new_models[model]) + if column['model_type']: + text += " [%s]" % column['model_type'] + reprs[module_map(column['module'])].append(text) + text = 'model %s (moved from %s)' % ( + model, old_models[model]) + if column['model_type']: + text += " [%s]" % column['model_type'] for column in copy.copy(new_records): model = column['model'] @@ -400,17 +416,28 @@ def compare_model_sets(old_records, new_records): text = 'new model %s' % model if column['model_type']: text += " [%s]" % column['model_type'] - reprs[module_map(column['module'])].append(text) + reprs[column['module']].append(text) reprs['general'].append('new model %s [module %s]' % ( - model, module_map(column['module']))) + model, column['module'])) else: - text = 'new model %s (renamed from %s)' % ( - model, inv_model_map(model)) + moved_module = '' + if column['module'] != module_map(old_models[inv_model_map( + model)]): + moved_module = ' in module %s' % old_models[ + inv_model_map(model)] + text = 'new model %s (renamed from %s%s)' % ( + model, inv_model_map(model), moved_module) if column['model_type']: text += " [%s]" % column['model_type'] - reprs[module_map(column['module'])].append(text) + reprs[column['module']].append(text) reprs['general'].append( 'new model %s (renamed from %s) [module %s]' % ( - model, inv_model_map(model), - module_map(column['module']))) + model, inv_model_map(model), column['module'])) + else: + if column['module'] != module_map(old_models[model]): + text = 'model %s (moved from %s)' % ( + model, old_models[model]) + if column['model_type']: + text += " [%s]" % column['model_type'] + reprs[column['module']].append(text) return reprs diff --git a/odoo/addons/test_performance/migrations/12.0.1.0/openupgrade_analysis.txt b/odoo/addons/test_performance/migrations/12.0.1.0/openupgrade_analysis.txt index a29edeb12fd0..47a45bffcd01 100644 --- a/odoo/addons/test_performance/migrations/12.0.1.0/openupgrade_analysis.txt +++ b/odoo/addons/test_performance/migrations/12.0.1.0/openupgrade_analysis.txt @@ -1,4 +1,5 @@ ---Models in module 'test_performance'--- +model test_performance.mail (moved to test_mail) ---Fields in module 'test_performance'--- test_performance / test_performance.mail / __last_update (datetime) : module is now 'test_mail' ('test_performance') test_performance / test_performance.mail / display_name (char) : module is now 'test_mail' ('test_performance')