forked from OCA/intrastat-extrastat
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[13.0] [MIG] product harmonized system (OCA#80)
* Large code re-engineering following the Akretion-Noviat code sprint on intrastat This code has been written both by Luc de Meyer and myself. * hs_code display_name fix * major update intrastat V3 modules * Add product_origin_country_id on declaration/computation lines Copy incoterms and destination country from SO to invoice when invoicing from SO We need weight even when supplementary units is used Small cleanups and enhancements * Add support for accessory costs Add default values for intrastat transaction on company Code cleanup * this week's ci errors * Update README.rst Rename variables * Port intrastat_base to v10 Set 2 other modules to uninstallable Update README.rst: switch to new intrastat project * Port product_harmonized_system to v10 * Fix warning on display_name Special thanks to Pedro and Holger for finding the solution for display_name Fix demo data * [MIG] product_harmonized_system: Migration to 11.0 * [FIX] product_harmonized_system: fix get_hs_code_recurively * [IMP] *: removed utf-8 headers, changed icon and site * company model test, country model test as in v8 * png logo instead of svg, removed Python 2 utf-8 headers * [UPD] Update product_harmonized_system.pot * Add new module product_harmonized_system_delivery (hide native hs_code field) Finalize port to v11 * [FIX+IMP] intrastat_*: Several things: * Add readonly on some fields when state of declaration is done * Division by zero in computation of accessory costs * Add FR translation * Fix strings * Minor code updates * [MIG] intrastat_product: Migration to 11.0 * Small fixes in intrastat_base * account_tax_template * [ADD] icon.png * [UPD] Update product_harmonized_system.pot * Prepare v12 branch * [MIG] Migrate all modules from v11 to v12 * flake8 * [UPD] Update product_harmonized_system.pot * Update translation files Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: intrastat-extrastat-12.0/intrastat-extrastat-12.0-product_harmonized_system Translate-URL: https://translation.odoo-community.org/projects/intrastat-extrastat-12-0/intrastat-extrastat-12-0-product_harmonized_system/ * [FIX] product_harmized_system DESCRIPTION.rst * [UPD] README.rst * [UPD] README.rst * Added translation using Weblate (Spanish) * Translated using Weblate (Spanish) Currently translated at 50.0% (18 of 36 strings) Translation: intrastat-extrastat-12.0/intrastat-extrastat-12.0-product_harmonized_system Translate-URL: https://translation.odoo-community.org/projects/intrastat-extrastat-12-0/intrastat-extrastat-12-0-product_harmonized_system/es/ * [MIG] product_harmonized_system : Migration to 13.0 * [IMP] product_harmonized_system: black, isort
- Loading branch information
1 parent
03d0118
commit bc4c8b1
Showing
22 changed files
with
1,653 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
=============================== | ||
Product Harmonized System Codes | ||
=============================== | ||
|
||
.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! This file is generated by oca-gen-addon-readme !! | ||
!! changes will be overwritten. !! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png | ||
:target: https://odoo-community.org/page/development-status | ||
:alt: Beta | ||
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png | ||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html | ||
:alt: License: AGPL-3 | ||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fintrastat--extrastat-lightgray.png?logo=github | ||
:target: https://github.com/OCA/intrastat-extrastat/tree/12.0/product_harmonized_system | ||
:alt: OCA/intrastat-extrastat | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/intrastat-extrastat-12-0/intrastat-extrastat-12-0-product_harmonized_system | ||
:alt: Translate me on Weblate | ||
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png | ||
:target: https://runbot.odoo-community.org/runbot/227/12.0 | ||
:alt: Try me on Runbot | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
This module contains the objects for Harmonised System Codes (H.S. codes). The full nomenclature is available from the `World Customs Organisation <http://www.wcoomd.org/>`. These code are usually required on the Proforma invoices that are attached to the packages that are shipped abroad. | ||
|
||
This module also handle the local/national extensions to the H.S. codes. The import of the full nomenclature is not provided by this module ; it should be provided by localization modules. | ||
|
||
You will also be able to configure the country of origin of a product, which is often required on the proforma invoice for the customs. | ||
|
||
This module should be usefull for all companies that export physical goods abroad. This module is also used by the Intrastat modules for the European Union, cf the *intrastat_product* module. | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Installation | ||
============ | ||
|
||
This module is NOT compatible with the *account_intrastat* module from Odoo Enterprise. | ||
|
||
Usage | ||
===== | ||
|
||
As this module only depends on the *product* module and that module doesn't provide any menu entry, this module lacks a menu entry for H.S. Codes. A menu entry for H.S. codes is provided by the module *product_harmonized_system_stock*. | ||
|
||
Once the H.S. codes are created, you will be able to set the H.S. code on an product (under the *Information* tab) or on a product category. On the product form, you will also be able to set the *Country of Origin* of a product (for example, if the product is *made in China*, select *China* as *Country of Origin*). | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/intrastat-extrastat/issues>`_. | ||
In case of trouble, please check there if your issue has already been reported. | ||
If you spotted it first, help us smashing it by providing a detailed and welcomed | ||
`feedback <https://github.com/OCA/intrastat-extrastat/issues/new?body=module:%20product_harmonized_system%0Aversion:%2012.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
Credits | ||
======= | ||
|
||
Authors | ||
~~~~~~~ | ||
|
||
* brain-tec AG | ||
* Akretion | ||
* Noviat | ||
|
||
Contributors | ||
~~~~~~~~~~~~ | ||
|
||
* Alexis de Lattre, Akretion <alexis.delattre@akretion.com> | ||
* Luc De Meyer, Noviat <info@noviat.com> | ||
* Kumar Aberer, brain-tec AG <kumar.aberer@braintec-group.com> | ||
|
||
Maintainers | ||
~~~~~~~~~~~ | ||
|
||
This module is maintained by the OCA. | ||
|
||
.. image:: https://odoo-community.org/logo.png | ||
:alt: Odoo Community Association | ||
:target: https://odoo-community.org | ||
|
||
OCA, or the Odoo Community Association, is a nonprofit organization whose | ||
mission is to support the collaborative development of Odoo features and | ||
promote its widespread use. | ||
|
||
This module is part of the `OCA/intrastat-extrastat <https://github.com/OCA/intrastat-extrastat/tree/12.0/product_harmonized_system>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Copyright 2018 brain-tec AG (http://www.braintec-group.com) | ||
# Copyright 2011-2016 Akretion (http://www.akretion.com) | ||
# Copyright 2009-2019 Noviat (http://www.noviat.com) | ||
# @author Benjamin Henquet <info@noviat.com> | ||
# @author Kumar Aberer <kumar.aberer@braintec-group.com> | ||
# @author Alexis de Lattre <alexis.delattre@akretion.com> | ||
# @author Luc de Meyer <info@noviat.com> | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
{ | ||
"name": "Product Harmonized System Codes", | ||
"version": "13.0.1.0.0", | ||
"category": "Reporting", | ||
"license": "AGPL-3", | ||
"summary": "Base module for Product Import/Export reports", | ||
"author": "brain-tec AG, Akretion, Noviat, " "Odoo Community Association (OCA)", | ||
"depends": ["product"], | ||
"excludes": ["account_intrastat"], | ||
"data": [ | ||
"security/product_hs_security.xml", | ||
"security/ir.model.access.csv", | ||
"views/hs_code.xml", | ||
"views/product_category.xml", | ||
"views/product_template.xml", | ||
], | ||
"demo": ["demo/product_demo.xml"], | ||
"installable": True, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<!-- | ||
Copyright 2011-2019 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). | ||
--> | ||
|
||
<odoo noupdate="1"> | ||
|
||
|
||
<record id="84715000" model="hs.code"> | ||
<field name="local_code">84715000</field> | ||
<field name="description">Automatic data-processing machines (computers)</field> | ||
</record> | ||
|
||
<record id="84717050" model="hs.code"> | ||
<field name="local_code">84717050</field> | ||
<field name="description">Storage units</field> | ||
</record> | ||
|
||
<record id="85340090" model="hs.code"> | ||
<field name="local_code">85340090</field> | ||
<field name="description">Printed circuits</field> | ||
</record> | ||
|
||
<record id="product.product_product_3" model="product.product"> | ||
<field name="hs_code_id" ref="84715000" /> | ||
<field name="origin_country_id" ref="base.tw" /> | ||
<field name="weight">8.7</field> | ||
</record> | ||
|
||
<record id="product.product_product_4" model="product.product"> | ||
<field name="hs_code_id" ref="84715000" /> | ||
<field name="origin_country_id" ref="base.cn" /> | ||
<field name="weight">1.1</field> | ||
</record> | ||
|
||
<record id="product.product_product_5" model="product.product"> | ||
<field name="hs_code_id" ref="84715000" /> | ||
<field name="origin_country_id" ref="base.cn" /> | ||
<field name="weight">8.2</field> | ||
</record> | ||
|
||
<record id="product.product_product_13" model="product.product"> | ||
<field name="hs_code_id" ref="84717050" /> | ||
<field name="origin_country_id" ref="base.sg" /> | ||
<field name="weight">0.01</field> | ||
</record> | ||
|
||
<record id="product.product_product_16" model="product.product"> | ||
<field name="hs_code_id" ref="84717050" /> | ||
<field name="origin_country_id" ref="base.sg" /> | ||
<field name="weight">0.67</field> | ||
</record> | ||
|
||
<record id="product.product_product_20" model="product.product"> | ||
<field name="hs_code_id" ref="85340090" /> | ||
<field name="origin_country_id" ref="base.tw" /> | ||
<field name="weight">1.05</field> | ||
</record> | ||
|
||
<record id="product.product_product_22" model="product.product"> | ||
<field name="hs_code_id" ref="85340090" /> | ||
<field name="origin_country_id" ref="base.tw" /> | ||
<field name="weight">0.3</field> | ||
</record> | ||
|
||
<record id="product.product_product_25" model="product.product"> | ||
<field name="hs_code_id" ref="84715000" /> | ||
<field name="origin_country_id" ref="base.be" /> | ||
<field name="weight">3.3</field> | ||
</record> | ||
|
||
|
||
</odoo> |
Oops, something went wrong.