mirror of
https://github.com/OCA/intrastat-extrastat.git
synced 2025-02-16 17:13:41 +02:00
Merge pull request #123 from akretion/13-brexit-without-xi-support
[13.0] intrastat_base: Brexit (simple, without special code for Northern Ireland)
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
{
|
||||
"name": "Intrastat Reporting Base",
|
||||
"version": "13.0.1.1.0",
|
||||
"version": "13.0.1.1.1",
|
||||
"category": "Intrastat",
|
||||
"license": "AGPL-3",
|
||||
"summary": "Base module for Intrastat reporting",
|
||||
|
||||
@@ -64,7 +64,8 @@
|
||||
<field name="intrastat" eval="True" />
|
||||
</record>
|
||||
<record id="base.uk" model="res.country">
|
||||
<field name="intrastat" eval="True" />
|
||||
<!-- Brexit means Brexit! -->
|
||||
<field name="intrastat" eval="False" />
|
||||
</record>
|
||||
<record id="base.si" model="res.country">
|
||||
<field name="intrastat" eval="True" />
|
||||
|
||||
17
intrastat_base/migrations/13.0.1.1.1/post-migration.py
Normal file
17
intrastat_base/migrations/13.0.1.1.1/post-migration.py
Normal file
@@ -0,0 +1,17 @@
|
||||
# Copyright 2021 Akretion France (http://www.akretion.com/)
|
||||
# @author: Alexis de Lattre <alexis.delattre@akretion.com>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from odoo import SUPERUSER_ID, api
|
||||
|
||||
|
||||
def migrate(cr, version):
|
||||
if not version:
|
||||
return
|
||||
|
||||
with api.Environment.manage():
|
||||
env = api.Environment(cr, SUPERUSER_ID, {})
|
||||
uk_country = env.ref("base.uk")
|
||||
# Brexit... bye bye, we'll miss you guys!
|
||||
if uk_country.intrastat:
|
||||
uk_country.write({"intrastat": False})
|
||||
Reference in New Issue
Block a user