mirror of
https://github.com/OCA/intrastat-extrastat.git
synced 2025-02-16 17:13:41 +02:00
[13.0][FIX] 'number' for invoice does not exist anymore the account.move has attribute 'name'
This commit is contained in:
committed by
João Marques
parent
576c303023
commit
cdfbc6bfc7
@@ -7,7 +7,7 @@
|
||||
|
||||
{
|
||||
"name": "Intrastat Product",
|
||||
"version": "13.0.1.0.0",
|
||||
"version": "13.0.1.0.1",
|
||||
"category": "Intrastat",
|
||||
"license": "AGPL-3",
|
||||
"summary": "Base module for Intrastat Product",
|
||||
|
||||
@@ -1,15 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo noupdate="1">
|
||||
|
||||
<record id="intrastat_transport_1" model="intrastat.transport_mode">
|
||||
<field name="code">1</field>
|
||||
<field name="name">Sea</field>
|
||||
<field name="description">Sea Transport (including wagons, motor vehicles, trailers, semi-trailers and lighters on board of a ship)</field>
|
||||
<field
|
||||
name="description"
|
||||
>Sea Transport (including wagons, motor vehicles, trailers, semi-trailers and lighters on board of a ship)</field>
|
||||
</record>
|
||||
<record id="intrastat_transport_2" model="intrastat.transport_mode">
|
||||
<field name="code">2</field>
|
||||
<field name="name">Rail</field>
|
||||
<field name="description">Railway transport (including lorries on railway wagons)</field>
|
||||
<field
|
||||
name="description"
|
||||
>Railway transport (including lorries on railway wagons)</field>
|
||||
</record>
|
||||
<record id="intrastat_transport_3" model="intrastat.transport_mode">
|
||||
<field name="code">3</field>
|
||||
@@ -29,7 +32,9 @@
|
||||
<record id="intrastat_transport_7" model="intrastat.transport_mode">
|
||||
<field name="code">7</field>
|
||||
<field name="name">Fixed installations</field>
|
||||
<field name="description">Fixed transport installations (e.g. pipelines, high-tension cables)</field>
|
||||
<field
|
||||
name="description"
|
||||
>Fixed transport installations (e.g. pipelines, high-tension cables)</field>
|
||||
</record>
|
||||
<record id="intrastat_transport_8" model="intrastat.transport_mode">
|
||||
<field name="code">8</field>
|
||||
@@ -39,12 +44,12 @@
|
||||
<record id="intrastat_transport_9" model="intrastat.transport_mode">
|
||||
<field name="code">9</field>
|
||||
<field name="name">Own propulsion</field>
|
||||
<field name="description">Own propulsion (imported or exported means of transport crossing the border under their own power, e.g. aircraft, lorries, boats, etc.)</field>
|
||||
<field
|
||||
name="description"
|
||||
>Own propulsion (imported or exported means of transport crossing the border under their own power, e.g. aircraft, lorries, boats, etc.)</field>
|
||||
</record>
|
||||
|
||||
<!-- Set default value to Road trp on main company -->
|
||||
<record id="base.main_company" model="res.company">
|
||||
<field name="intrastat_transport_id" ref="intrastat_transport_3" />
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo noupdate="1">
|
||||
|
||||
<!-- Extracted from the Official Journal of the European Union -->
|
||||
|
||||
<record id="intrastat_unit_c_k" model="intrastat.unit">
|
||||
<field name="name">c/k</field>
|
||||
<field name="description">Carats - 1 metric carat = 2 × 10exp(–4) kg</field>
|
||||
@@ -34,7 +32,9 @@
|
||||
</record>
|
||||
<record id="intrastat_unit_kg_KOH" model="intrastat.unit">
|
||||
<field name="name">kg KOH</field>
|
||||
<field name="description">Kilogram of potassium hydroxide (caustic potash)</field>
|
||||
<field
|
||||
name="description"
|
||||
>Kilogram of potassium hydroxide (caustic potash)</field>
|
||||
</record>
|
||||
<record id="intrastat_unit_kg_ma" model="intrastat.unit">
|
||||
<field name="name">kg met.am.</field>
|
||||
@@ -119,5 +119,4 @@
|
||||
<field name="name">TJ</field>
|
||||
<field name="description">Terajoule (gross calorific value)</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -4,22 +4,17 @@
|
||||
@author Alexis de Lattre <alexis.delattre@akretion.com>
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
|
||||
<odoo noupdate="1">
|
||||
|
||||
<record id="product_harmonized_system.84715000" model="hs.code">
|
||||
<field name="intrastat_unit_id" ref="intrastat_unit_pce" />
|
||||
</record>
|
||||
|
||||
<record id="product_harmonized_system.84717050" model="hs.code">
|
||||
<field name="intrastat_unit_id" ref="intrastat_unit_pce" />
|
||||
</record>
|
||||
|
||||
<record id="base.main_company" model="res.company">
|
||||
<field name="intrastat_arrivals">extended</field>
|
||||
<field name="intrastat_dispatches">extended</field>
|
||||
<field name="incoterm_id" ref="account.incoterm_DDU" />
|
||||
<field name="intrastat_transport_id" ref="intrastat_transport_3" />
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -275,7 +275,7 @@ class IntrastatProductDeclaration(models.Model):
|
||||
note = "\n" + _(
|
||||
"Missing unit of measure on the line with %d "
|
||||
"product(s) '%s' on invoice '%s'."
|
||||
) % (line_qty, product.name_get()[0][1], invoice.number)
|
||||
) % (line_qty, product.name_get()[0][1], invoice.name)
|
||||
note += "\n" + _("Please adjust this line manually.")
|
||||
self._note += note
|
||||
return weight, suppl_unit_qty
|
||||
@@ -546,7 +546,7 @@ class IntrastatProductDeclaration(models.Model):
|
||||
_logger.info(
|
||||
"Skipping invoice line %s qty %s "
|
||||
"of invoice %s. Reason: qty = 0"
|
||||
% (inv_line.name, inv_line.quantity, invoice.number)
|
||||
% (inv_line.name, inv_line.quantity, invoice.name)
|
||||
)
|
||||
continue
|
||||
|
||||
@@ -555,7 +555,7 @@ class IntrastatProductDeclaration(models.Model):
|
||||
_logger.info(
|
||||
"Skipping invoice line %s qty %s "
|
||||
"of invoice %s. Reason: no partner_country"
|
||||
% (inv_line.name, inv_line.quantity, invoice.number)
|
||||
% (inv_line.name, inv_line.quantity, invoice.name)
|
||||
)
|
||||
continue
|
||||
|
||||
@@ -566,7 +566,7 @@ class IntrastatProductDeclaration(models.Model):
|
||||
"Skipping invoice line %s "
|
||||
"qty %s of invoice %s. Reason: "
|
||||
"tax.exclude_from_intrastat_if_present"
|
||||
% (inv_line.name, inv_line.quantity, invoice.number)
|
||||
% (inv_line.name, inv_line.quantity, invoice.name)
|
||||
)
|
||||
continue
|
||||
|
||||
@@ -588,7 +588,7 @@ class IntrastatProductDeclaration(models.Model):
|
||||
_logger.info(
|
||||
"Skipping invoice line %s qty %s "
|
||||
"of invoice %s. Reason: no product nor hs_code"
|
||||
% (inv_line.name, inv_line.quantity, invoice.number)
|
||||
% (inv_line.name, inv_line.quantity, invoice.name)
|
||||
)
|
||||
continue
|
||||
|
||||
|
||||
@@ -1,22 +1,24 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo noupdate="1">
|
||||
|
||||
<record id="intrastat_transaction_company_rule" model="ir.rule">
|
||||
<field name="name">Intrastat Transaction Company rule</field>
|
||||
<field name="model_id" ref="model_intrastat_transaction" />
|
||||
<field name="domain_force">['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_region_company_rule" model="ir.rule">
|
||||
<field name="name">Intrastat Region Company rule</field>
|
||||
<field name="model_id" ref="model_intrastat_region" />
|
||||
<field name="domain_force">['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_company_rule" model="ir.rule">
|
||||
<field name="name">Intrastat Product Declaration Company rule</field>
|
||||
<field name="model_id" ref="model_intrastat_product_declaration" />
|
||||
<field name="domain_force">['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,24 +1,30 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo>
|
||||
|
||||
<record id="view_move_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.invoice.form</field>
|
||||
<field name="model">account.move</field>
|
||||
<field name="inherit_id" ref="account.view_move_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//page[@name='other_info']//field[@name='invoice_incoterm_id']" position="after">
|
||||
<xpath
|
||||
expr="//page[@name='other_info']//field[@name='invoice_incoterm_id']"
|
||||
position="after"
|
||||
>
|
||||
<field name="intrastat_transaction_id" />
|
||||
<field name="intrastat" invisible="1" />
|
||||
<field name="intrastat_transport_id"
|
||||
<field
|
||||
name="intrastat_transport_id"
|
||||
attrs="{'invisible': [('intrastat', '!=', 'extended')]}"
|
||||
widget="selection"/>
|
||||
widget="selection"
|
||||
/>
|
||||
<field name="src_dest_country_id" string="Destination Country" />
|
||||
<field name="src_dest_region_id" string="Origin Region" invisible="1" />
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='invoice_line_ids']//field[@name='account_id']" position="after">
|
||||
<xpath
|
||||
expr="//field[@name='invoice_line_ids']//field[@name='account_id']"
|
||||
position="after"
|
||||
>
|
||||
<field name="hs_code_id" invisible="1" />
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -6,15 +6,14 @@
|
||||
@author Luc De Meyer <luc.demeyer@noviat.com>
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
|
||||
<odoo>
|
||||
|
||||
<!-- Add the H.S. code menu under the Intrastat Config menu -->
|
||||
<menuitem id="intrastat_code_menu"
|
||||
<menuitem
|
||||
id="intrastat_code_menu"
|
||||
action="product_harmonized_system.hs_code_action"
|
||||
parent="intrastat_base.menu_intrastat_config_root"
|
||||
sequence="10"/>
|
||||
|
||||
sequence="10"
|
||||
/>
|
||||
<!-- Inherit tree view of H.S. code -->
|
||||
<record id="hs_code_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.hs.code.tree</field>
|
||||
@@ -26,7 +25,6 @@
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Inherit form view for H.S. code -->
|
||||
<record id="hs_code_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.hs.code.form</field>
|
||||
@@ -38,5 +36,4 @@
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,26 +1,44 @@
|
||||
<?xml version="1.0" ?>
|
||||
<odoo>
|
||||
|
||||
<record id="intrastat_product_declaration_view_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.form</field>
|
||||
<field name="model">intrastat.product.declaration</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Intrastat Product Declaration">
|
||||
<header>
|
||||
<button name="action_gather" type="object"
|
||||
<button
|
||||
name="action_gather"
|
||||
type="object"
|
||||
attrs="{'invisible': ['|', ('state', '!=', 'draft'), ('action', '=', 'nihil')]}"
|
||||
string="Generate Lines from Invoices"
|
||||
class="oe_highlight"/>
|
||||
<button name="generate_declaration" type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
<button
|
||||
name="generate_declaration"
|
||||
type="object"
|
||||
attrs="{'invisible': ['|', ('state', '!=', 'draft'), ('action', '=', 'nihil')]}"
|
||||
string="Generate Declaration Lines"/>
|
||||
<button name="generate_xml"
|
||||
string="Generate Declaration Lines"
|
||||
/>
|
||||
<button
|
||||
name="generate_xml"
|
||||
string="Generate XML Declaration File"
|
||||
type="object"
|
||||
attrs="{'invisible': [('state', '!=', 'draft')]}"
|
||||
invisible="context.get('generic_intrastat_product_declaration')"/>
|
||||
<button name="done" string="Done" type="object" class="oe_highlight" states="draft"/>
|
||||
<button name="back2draft" string="Back to Draft" type="object" states="done"/>
|
||||
invisible="context.get('generic_intrastat_product_declaration')"
|
||||
/>
|
||||
<button
|
||||
name="done"
|
||||
string="Done"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
states="draft"
|
||||
/>
|
||||
<button
|
||||
name="back2draft"
|
||||
string="Back to Draft"
|
||||
type="object"
|
||||
states="done"
|
||||
/>
|
||||
<field name="state" widget="statusbar" />
|
||||
</header>
|
||||
<sheet string="Intrastat Product Declaration">
|
||||
@@ -40,9 +58,17 @@
|
||||
<group name="properties-2">
|
||||
<field name="action" />
|
||||
<field name="revision" />
|
||||
<field name="total_amount" widget="monetary" options="{'currency_field': 'currency_id'}"/>
|
||||
<field
|
||||
name="total_amount"
|
||||
widget="monetary"
|
||||
options="{'currency_field': 'currency_id'}"
|
||||
/>
|
||||
<field name="num_decl_lines" />
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
<field
|
||||
name="company_id"
|
||||
groups="base.group_multi_company"
|
||||
widget="selection"
|
||||
/>
|
||||
<field name="company_country_code" invisible="1" />
|
||||
<field name="currency_id" invisible="1" />
|
||||
</group>
|
||||
@@ -50,24 +76,36 @@
|
||||
<notebook>
|
||||
<page string="Transactions">
|
||||
<header>
|
||||
<button name="create_xls" type="object" string="Excel Export"
|
||||
context="{'computation_lines': 1}"/>
|
||||
<button
|
||||
name="create_xls"
|
||||
type="object"
|
||||
string="Excel Export"
|
||||
context="{'computation_lines': 1}"
|
||||
/>
|
||||
</header>
|
||||
<group name="computation_lines">
|
||||
<field name="computation_line_ids"
|
||||
<field
|
||||
name="computation_line_ids"
|
||||
context="{'type': type, 'reporting_level': reporting_level}"
|
||||
nolabel="1"/>
|
||||
nolabel="1"
|
||||
/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Declaration Lines">
|
||||
<header>
|
||||
<button name="create_xls" type="object" string="Excel Export"
|
||||
context="{'declaration_lines': 1}"/>
|
||||
<button
|
||||
name="create_xls"
|
||||
type="object"
|
||||
string="Excel Export"
|
||||
context="{'declaration_lines': 1}"
|
||||
/>
|
||||
</header>
|
||||
<group name="declaration_lines">
|
||||
<field name="declaration_line_ids"
|
||||
<field
|
||||
name="declaration_line_ids"
|
||||
context="{'type': type, 'reporting_level': reporting_level}"
|
||||
nolabel="1"/>
|
||||
nolabel="1"
|
||||
/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Notes">
|
||||
@@ -82,12 +120,14 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_view_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.tree</field>
|
||||
<field name="model">intrastat.product.declaration</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Intrastat Product Declarations" decoration-info="state=='draft'">
|
||||
<tree
|
||||
string="Intrastat Product Declarations"
|
||||
decoration-info="state=='draft'"
|
||||
>
|
||||
<field name="year_month" />
|
||||
<field name="revision" />
|
||||
<field name="type" />
|
||||
@@ -98,24 +138,42 @@
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_view_search" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.search</field>
|
||||
<field name="model">intrastat.product.declaration</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Intrastat Product Declarations">
|
||||
<filter name="arrivals" string="Arrivals" domain="[('type', '=', 'arrivals')]"/>
|
||||
<filter name="dispatches" string="Dispatches" domain="[('type', '=', 'dispatches')]"/>
|
||||
<filter name="draft" string="Draft" domain="[('state', '=', 'draft')]" />
|
||||
<filter
|
||||
name="arrivals"
|
||||
string="Arrivals"
|
||||
domain="[('type', '=', 'arrivals')]"
|
||||
/>
|
||||
<filter
|
||||
name="dispatches"
|
||||
string="Dispatches"
|
||||
domain="[('type', '=', 'dispatches')]"
|
||||
/>
|
||||
<filter
|
||||
name="draft"
|
||||
string="Draft"
|
||||
domain="[('state', '=', 'draft')]"
|
||||
/>
|
||||
<filter name="done" string="Done" domain="[('state', '=', 'done')]" />
|
||||
<group string="Group By" name="group_by">
|
||||
<filter name="date_group_by" string="Date" context="{'group_by': 'year_month'}" />
|
||||
<filter name="type_group_by" string="Type" context="{'group_by': 'type'}" />
|
||||
<filter
|
||||
name="date_group_by"
|
||||
string="Date"
|
||||
context="{'group_by': 'year_month'}"
|
||||
/>
|
||||
<filter
|
||||
name="type_group_by"
|
||||
string="Type"
|
||||
context="{'group_by': 'type'}"
|
||||
/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_view_graph" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.graph</field>
|
||||
<field name="model">intrastat.product.declaration</field>
|
||||
@@ -127,7 +185,6 @@
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_view_pivot" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.pivot</field>
|
||||
<field name="model">intrastat.product.declaration</field>
|
||||
@@ -139,27 +196,33 @@
|
||||
</pivot>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<!-- No menuitem nor action since these are provided by the localization modules -->
|
||||
|
||||
<record id="intrastat_product_computation_line_view_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.computation.line.form</field>
|
||||
<field name="model">intrastat.product.computation.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Intrastat Transaction">
|
||||
<group string="Transaction" name="transaction">
|
||||
<field name="parent_id"
|
||||
invisible="not context.get('intrastat_product_computation_line_main_view')"/>
|
||||
<field
|
||||
name="parent_id"
|
||||
invisible="not context.get('intrastat_product_computation_line_main_view')"
|
||||
/>
|
||||
<field name="product_id" />
|
||||
<field name="hs_code_id" />
|
||||
<field name="src_dest_country_id" domain="[('intrastat', '=', True)]"/>
|
||||
<field name="amount_company_currency"
|
||||
<field
|
||||
name="src_dest_country_id"
|
||||
domain="[('intrastat', '=', True)]"
|
||||
/>
|
||||
<field
|
||||
name="amount_company_currency"
|
||||
widget="monetary"
|
||||
options="{'currency_field': 'company_currency_id'}"/>
|
||||
<field name="amount_accessory_cost_company_currency"
|
||||
options="{'currency_field': 'company_currency_id'}"
|
||||
/>
|
||||
<field
|
||||
name="amount_accessory_cost_company_currency"
|
||||
widget="monetary"
|
||||
options="{'currency_field': 'company_currency_id'}"/>
|
||||
options="{'currency_field': 'company_currency_id'}"
|
||||
/>
|
||||
<field name="company_currency_id" invisible="1" />
|
||||
<field name="transaction_id" />
|
||||
<label for="weight" />
|
||||
@@ -170,8 +233,10 @@
|
||||
<field name="intrastat_unit_id" />
|
||||
<field name="type" invisible="1" />
|
||||
<field name="reporting_level" invisible="1" />
|
||||
<field name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"/>
|
||||
<field
|
||||
name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"
|
||||
/>
|
||||
<field name="incoterm_id" invisible="1" />
|
||||
<field name="region_id" invisible="1" />
|
||||
<field name="product_origin_country_id" invisible="1" />
|
||||
@@ -183,14 +248,15 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_computation_line_view_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.computation.line.tree</field>
|
||||
<field name="model">intrastat.product.computation.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Transactions">
|
||||
<field name="parent_id"
|
||||
invisible="not context.get('intrastat_product_computation_line_main_view')"/>
|
||||
<field
|
||||
name="parent_id"
|
||||
invisible="not context.get('intrastat_product_computation_line_main_view')"
|
||||
/>
|
||||
<field name="product_id" />
|
||||
<field name="hs_code_id" />
|
||||
<field name="src_dest_country_id" domain="[('intrastat', '=', True)]" />
|
||||
@@ -198,33 +264,47 @@
|
||||
<field name="amount_accessory_cost_company_currency" />
|
||||
<field name="transaction_id" />
|
||||
<field name="weight" />
|
||||
<field name="suppl_unit_qty"
|
||||
attrs="{'invisible': [('intrastat_unit_id', '=', False)], 'required': [('intrastat_unit_id', '!=', False)]}"/>
|
||||
<field
|
||||
name="suppl_unit_qty"
|
||||
attrs="{'invisible': [('intrastat_unit_id', '=', False)], 'required': [('intrastat_unit_id', '!=', False)]}"
|
||||
/>
|
||||
<field name="intrastat_unit_id" />
|
||||
<field name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"/>
|
||||
<field
|
||||
name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"
|
||||
/>
|
||||
<field name="region_id" invisible="1" />
|
||||
<field name="product_origin_country_id" invisible="1" string="Product C/O"/>
|
||||
<field
|
||||
name="product_origin_country_id"
|
||||
invisible="1"
|
||||
string="Product C/O"
|
||||
/>
|
||||
<field name="invoice_id" />
|
||||
<field name="type" invisible="1" />
|
||||
<field name="reporting_level" invisible="1" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_line_view_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.line.form</field>
|
||||
<field name="model">intrastat.product.declaration.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Intrastat Declaration Line">
|
||||
<group name="declaration">
|
||||
<field name="parent_id"
|
||||
invisible="not context.get('intrastat_product_declaration_line_main_view')"/>
|
||||
<field
|
||||
name="parent_id"
|
||||
invisible="not context.get('intrastat_product_declaration_line_main_view')"
|
||||
/>
|
||||
<field name="hs_code_id" />
|
||||
<field name="src_dest_country_id" domain="[('intrastat', '=', True)]"/>
|
||||
<field name="amount_company_currency"
|
||||
<field
|
||||
name="src_dest_country_id"
|
||||
domain="[('intrastat', '=', True)]"
|
||||
/>
|
||||
<field
|
||||
name="amount_company_currency"
|
||||
widget="monetary"
|
||||
options="{'currency_field': 'company_currency_id'}"/>
|
||||
options="{'currency_field': 'company_currency_id'}"
|
||||
/>
|
||||
<field name="company_currency_id" invisible="1" />
|
||||
<field name="transaction_id" />
|
||||
<label for="weight" />
|
||||
@@ -235,8 +315,10 @@
|
||||
<field name="intrastat_unit_id" />
|
||||
<field name="type" invisible="1" />
|
||||
<field name="reporting_level" invisible="1" />
|
||||
<field name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"/>
|
||||
<field
|
||||
name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"
|
||||
/>
|
||||
<field name="region_id" invisible="1" />
|
||||
<field name="incoterm_id" invisible="1" />
|
||||
<field name="product_origin_country_id" invisible="1" />
|
||||
@@ -247,14 +329,15 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_product_declaration_line_view_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.product.declaration.line.tree</field>
|
||||
<field name="model">intrastat.product.declaration.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Intrastat Declaration Lines">
|
||||
<field name="parent_id"
|
||||
invisible="not context.get('intrastat_product_declaration_line_main_view')"/>
|
||||
<field
|
||||
name="parent_id"
|
||||
invisible="not context.get('intrastat_product_declaration_line_main_view')"
|
||||
/>
|
||||
<field name="hs_code_id" />
|
||||
<field name="src_dest_country_id" domain="[('intrastat', '=', True)]" />
|
||||
<field name="amount_company_currency" />
|
||||
@@ -264,14 +347,18 @@
|
||||
<field name="intrastat_unit_id" />
|
||||
<field name="type" invisible="1" />
|
||||
<field name="reporting_level" invisible="1" />
|
||||
<field name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"/>
|
||||
<field
|
||||
name="transport_id"
|
||||
attrs="{'required': [('reporting_level', '=', 'extended')], 'invisible': [('reporting_level', '!=', 'extended')]}"
|
||||
/>
|
||||
<field name="region_id" invisible="1" />
|
||||
<field name="incoterm_id" invisible="1" />
|
||||
<field name="product_origin_country_id" invisible="1" string="Product C/O"/>
|
||||
<field
|
||||
name="product_origin_country_id"
|
||||
invisible="1"
|
||||
string="Product C/O"
|
||||
/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo>
|
||||
|
||||
<record id="intrastat_region_view_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.region.form</field>
|
||||
<field name="model">intrastat.region</field>
|
||||
@@ -16,7 +15,6 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_region_view_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.region.tree</field>
|
||||
<field name="model">intrastat.region</field>
|
||||
@@ -30,15 +28,14 @@
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_region_action" model="ir.actions.act_window">
|
||||
<field name="name">Intrastat Regions</field>
|
||||
<field name="res_model">intrastat.region</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="intrastat_region_menu"
|
||||
<menuitem
|
||||
id="intrastat_region_menu"
|
||||
action="intrastat_region_action"
|
||||
parent="intrastat_base.menu_intrastat_config_root"/>
|
||||
|
||||
parent="intrastat_base.menu_intrastat_config_root"
|
||||
/>
|
||||
</odoo>
|
||||
|
||||
@@ -6,9 +6,7 @@
|
||||
@author Luc De Meyer <luc.demeyer@noviat.com>
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
|
||||
<odoo>
|
||||
|
||||
<!-- Intrastat Transaction Type -->
|
||||
<record id="intrastat_transaction_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.transaction_form</field>
|
||||
@@ -23,7 +21,6 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transaction_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.transaction_tree</field>
|
||||
<field name="model">intrastat.transaction</field>
|
||||
@@ -35,31 +32,35 @@
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transaction_mode_search" model="ir.ui.view">
|
||||
<field name="name">intrastat.transaction.mode.search</field>
|
||||
<field name="model">intrastat.transaction</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Intrastat Transaction Types">
|
||||
<field name="description" string="Code or Description"
|
||||
filter_domain="['|', ('code', 'ilike', self), ('description', 'ilike', self)]"/>
|
||||
<field
|
||||
name="description"
|
||||
string="Code or Description"
|
||||
filter_domain="['|', ('code', 'ilike', self), ('description', 'ilike', self)]"
|
||||
/>
|
||||
<group string="Group By" name="groupby">
|
||||
<filter name="company_groupby" string="Company"
|
||||
context="{'group_by': 'company_id'}"/>
|
||||
<filter
|
||||
name="company_groupby"
|
||||
string="Company"
|
||||
context="{'group_by': 'company_id'}"
|
||||
/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transaction_action" model="ir.actions.act_window">
|
||||
<field name="name">Transaction Types</field>
|
||||
<field name="res_model">intrastat.transaction</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="intrastat_transaction_menu"
|
||||
<menuitem
|
||||
id="intrastat_transaction_menu"
|
||||
action="intrastat_transaction_action"
|
||||
parent="intrastat_base.menu_intrastat_config_root"
|
||||
sequence="20"/>
|
||||
|
||||
sequence="20"
|
||||
/>
|
||||
</odoo>
|
||||
|
||||
@@ -6,9 +6,7 @@
|
||||
@author Luc De Meyer <luc.demeyer@noviat.com>
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
|
||||
<odoo>
|
||||
|
||||
<!-- Intrastat Transport Mode -->
|
||||
<record id="intrastat_transport_mode_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.transport.mode.form</field>
|
||||
@@ -23,7 +21,6 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transport_mode_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.transport.mode.tree</field>
|
||||
<field name="model">intrastat.transport_mode</field>
|
||||
@@ -35,27 +32,28 @@
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transport_mode_search" model="ir.ui.view">
|
||||
<field name="name">intrastat.transport.mode.search</field>
|
||||
<field name="model">intrastat.transport_mode</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Intrastat Transport Modes">
|
||||
<field name="name" string="Name, Code or Description"
|
||||
filter_domain="['|', '|', ('name', 'ilike', self), ('description', 'ilike', self), ('code', 'ilike', self)]"/>
|
||||
<field
|
||||
name="name"
|
||||
string="Name, Code or Description"
|
||||
filter_domain="['|', '|', ('name', 'ilike', self), ('description', 'ilike', self), ('code', 'ilike', self)]"
|
||||
/>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_transport_action" model="ir.actions.act_window">
|
||||
<field name="name">Transport Modes</field>
|
||||
<field name="res_model">intrastat.transport_mode</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="intrastat_transport_menu"
|
||||
<menuitem
|
||||
id="intrastat_transport_menu"
|
||||
action="intrastat_transport_action"
|
||||
parent="intrastat_base.menu_intrastat_config_root"
|
||||
sequence="30"/>
|
||||
|
||||
sequence="30"
|
||||
/>
|
||||
</odoo>
|
||||
|
||||
@@ -6,9 +6,7 @@
|
||||
@author Luc De Meyer <luc.demeyer@noviat.com>
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
|
||||
<odoo>
|
||||
|
||||
<!-- Intrastat Supplementary Unit -->
|
||||
<record id="intrastat_unit_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.unit.form</field>
|
||||
@@ -16,9 +14,12 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Intrastat Supplementary Unit">
|
||||
<field name="active" invisible="1" />
|
||||
<widget name="web_ribbon" text="Archived"
|
||||
<widget
|
||||
name="web_ribbon"
|
||||
text="Archived"
|
||||
bg_color="bg-danger"
|
||||
attrs="{'invisible': [('active', '=', True)]}"/>
|
||||
attrs="{'invisible': [('active', '=', True)]}"
|
||||
/>
|
||||
<group name="main">
|
||||
<field name="name" />
|
||||
<field name="uom_id" required="1" />
|
||||
@@ -27,7 +28,6 @@
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_unit_tree" model="ir.ui.view">
|
||||
<field name="name">intrastat.unit.tree</field>
|
||||
<field name="model">intrastat.unit</field>
|
||||
@@ -39,33 +39,39 @@
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="intrastat_unit_search" model="ir.ui.view">
|
||||
<field name="name">intrastat.unit.search</field>
|
||||
<field name="model">intrastat.unit</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Intrastat Supplementary Units">
|
||||
<field name="name"
|
||||
filter_domain="['|', ('name', 'ilike', self), ('description', 'ilike', self)]"/>
|
||||
<filter string="Archived" name="inactive" domain="[('active', '=', False)]"/>
|
||||
<field
|
||||
name="name"
|
||||
filter_domain="['|', ('name', 'ilike', self), ('description', 'ilike', self)]"
|
||||
/>
|
||||
<filter
|
||||
string="Archived"
|
||||
name="inactive"
|
||||
domain="[('active', '=', False)]"
|
||||
/>
|
||||
<group string="Group By" name="groupby">
|
||||
<filter name="uom_groupby" string="Regular UoM"
|
||||
context="{'group_by': 'uom_id'}"/>
|
||||
<filter
|
||||
name="uom_groupby"
|
||||
string="Regular UoM"
|
||||
context="{'group_by': 'uom_id'}"
|
||||
/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="intrastat_unit_action" model="ir.actions.act_window">
|
||||
<field name="name">Supplementary Units</field>
|
||||
<field name="res_model">intrastat.unit</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="intrastat_unit_menu"
|
||||
<menuitem
|
||||
id="intrastat_unit_menu"
|
||||
action="intrastat_unit_action"
|
||||
parent="intrastat_base.menu_intrastat_config_root"
|
||||
sequence="40"/>
|
||||
|
||||
sequence="40"
|
||||
/>
|
||||
</odoo>
|
||||
|
||||
@@ -5,74 +5,108 @@
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
-->
|
||||
<odoo>
|
||||
|
||||
<record id="view_res_config_settings" model="ir.ui.view">
|
||||
<field name="name">intrastat.account.config.settings.form</field>
|
||||
<field name="model">res.config.settings</field>
|
||||
<field name="inherit_id" ref="intrastat_base.view_intrastat_res_config_settings"/>
|
||||
<field
|
||||
name="inherit_id"
|
||||
ref="intrastat_base.view_intrastat_res_config_settings"
|
||||
/>
|
||||
<field name="arch" type="xml">
|
||||
|
||||
<xpath expr="//div[@id='intrastat']" position="after">
|
||||
|
||||
<field name="country_id" invisible="1" />
|
||||
<field name="country_code" invisible="1" />
|
||||
|
||||
<div class="row mt16 o_settings_container" id="intrastat-product">
|
||||
|
||||
<div class="col-xs-12 col-md-12 o_setting_box">
|
||||
<div class="o_setting_left_pane" />
|
||||
<div class="o_setting_right_pane" id="intrastat-product-main-params">
|
||||
<div
|
||||
class="o_setting_right_pane"
|
||||
id="intrastat-product-main-params"
|
||||
>
|
||||
<div class="row">
|
||||
<label for="intrastat_arrivals" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_arrivals"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_arrivals" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<label for="intrastat_dispatches" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_dispatches"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_dispatches" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<label for="intrastat_transport_id" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_transport_id"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_transport_id" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<label for="intrastat_transaction_out_invoice" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_transaction_out_invoice"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_transaction_out_invoice" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<label for="intrastat_transaction_out_refund" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_transaction_out_refund"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_transaction_out_refund" />
|
||||
</div>
|
||||
<div class="row">
|
||||
<label for="intrastat_transaction_in_invoice" class="col-md-5 o_light_label"/>
|
||||
<label
|
||||
for="intrastat_transaction_in_invoice"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_transaction_in_invoice" />
|
||||
</div>
|
||||
<div class="row" attrs="{'invisible': [('country_code', 'in', ['FR'])]}">
|
||||
<label for="intrastat_transaction_in_refund" class="col-md-5 o_light_label"/>
|
||||
<div
|
||||
class="row"
|
||||
attrs="{'invisible': [('country_code', 'in', ['FR'])]}"
|
||||
>
|
||||
<label
|
||||
for="intrastat_transaction_in_refund"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field name="intrastat_transaction_in_refund" />
|
||||
</div>
|
||||
<div class="row" attrs="{'invisible': [('country_code', 'not in', ['BE'])]}">
|
||||
<label for="intrastat_region_id" class="col-md-5 o_light_label"/>
|
||||
<field name="intrastat_region_id" domain="[('country_id','=', country_id)]"/>
|
||||
<div
|
||||
class="row"
|
||||
attrs="{'invisible': [('country_code', 'not in', ['BE'])]}"
|
||||
>
|
||||
<label
|
||||
for="intrastat_region_id"
|
||||
class="col-md-5 o_light_label"
|
||||
/>
|
||||
<field
|
||||
name="intrastat_region_id"
|
||||
domain="[('country_id','=', country_id)]"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="o_setting_left_pane">
|
||||
<field name="intrastat_accessory_costs"
|
||||
attrs="{'invisible': [('country_code', 'in', ['BE'])]}"/>
|
||||
<field
|
||||
name="intrastat_accessory_costs"
|
||||
attrs="{'invisible': [('country_code', 'in', ['BE'])]}"
|
||||
/>
|
||||
</div>
|
||||
<div class="o_setting_right_pane">
|
||||
<div class="row">
|
||||
<label for="intrastat_accessory_costs" class="col-md-12 o_light_label"
|
||||
attrs="{'invisible': [('country_code', 'in', ['BE'])]}"/>
|
||||
<label
|
||||
for="intrastat_accessory_costs"
|
||||
class="col-md-12 o_light_label"
|
||||
attrs="{'invisible': [('country_code', 'in', ['BE'])]}"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</xpath>
|
||||
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,20 +1,18 @@
|
||||
<?xml version="1.0" ?>
|
||||
<odoo>
|
||||
|
||||
|
||||
<record id="sale_order_form" model="ir.ui.view">
|
||||
<field name="name">intrastat.sale.order.form</field>
|
||||
<field name="model">sale.order</field>
|
||||
<field name="inherit_id" ref="sale_stock.view_order_form_inherit_sale_stock" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="incoterm" position="after">
|
||||
<field name="intrastat_transport_id"
|
||||
<field
|
||||
name="intrastat_transport_id"
|
||||
attrs="{'invisible': [('intrastat', '!=', 'extended')]}"
|
||||
widget="selection"/>
|
||||
widget="selection"
|
||||
/>
|
||||
<field name="intrastat" invisible="1" />
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
<?xml version="1.0" ?>
|
||||
<odoo>
|
||||
|
||||
<record id="view_warehouse" model="ir.ui.view">
|
||||
<field name="name">intrastat.stock.warehouse.form</field>
|
||||
<field name="model">stock.warehouse</field>
|
||||
@@ -11,5 +10,4 @@
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user