Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion l10n_it_fiscalcode/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

{
"name": "ITA - Codice fiscale",
"version": "14.0.1.0.1",
"version": "14.0.1.0.2",
"development_status": "Production/Stable",
"category": "Localization/Italy",
"author": "Link IT s.r.l., "
Expand Down
17 changes: 17 additions & 0 deletions l10n_it_fiscalcode/migrations/10.0.1.0.1/post-migrate.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Copyright 2018 Alex Comba - Agile Business Group
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).


from openerp import SUPERUSER_ID, api


def migrate(cr, version):
""" Sync of fiscalcode field to descendants """
if not version:
return
with api.Environment.manage():
env = api.Environment(cr, SUPERUSER_ID, {})
partners = env["res.partner"].search([("is_company", "=", True)])
for partner in partners:
partner = env["res.partner"].browse(partner.id)
partner.with_prefetch()._commercial_sync_to_children()
9 changes: 9 additions & 0 deletions l10n_it_fiscalcode/migrations/11.0.1.1.0/pre-migrate.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Copyright © 2018 Matteo Bilotta (Link IT s.r.l.)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).


def migrate(cr, version):
if not version:
return

cr.execute("DROP VIEW IF EXISTS res_city_it_code_province;")