From da629df34bcd7f3847af9813cdf93c4351974fdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adri=C3=A0=20Gil=20Sorribes?= Date: Tue, 4 Dec 2018 12:59:44 +0100 Subject: [PATCH] [12.0][MIG] Migrate module account_move_line_purchase_info to v12 --- account_move_line_purchase_info/README.rst | 64 ++- .../__manifest__.py | 6 +- .../readme/CONTRIBUTORS.rst | 1 + .../readme/DESCRIPTION.rst | 4 + .../readme/USAGE.rst | 7 + .../security/account_security.xml | 2 +- .../static/description/index.html | 410 ++++++++++++++++++ .../test_account_move_line_purchase_info.py | 4 +- 8 files changed, 471 insertions(+), 27 deletions(-) create mode 100644 account_move_line_purchase_info/readme/CONTRIBUTORS.rst create mode 100644 account_move_line_purchase_info/readme/DESCRIPTION.rst create mode 100644 account_move_line_purchase_info/readme/USAGE.rst create mode 100644 account_move_line_purchase_info/static/description/index.html diff --git a/account_move_line_purchase_info/README.rst b/account_move_line_purchase_info/README.rst index bb7a0ba8..a6563c05 100644 --- a/account_move_line_purchase_info/README.rst +++ b/account_move_line_purchase_info/README.rst @@ -1,16 +1,39 @@ -.. image:: https://img.shields.io/badge/license-AGPLv3-blue.svg - :target: https://www.gnu.org/licenses/agpl.html - :alt: License: AGPL-3 - =============================== Account Move Line Purchase Info =============================== +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! 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%2Faccount--financial--tools-lightgray.png?logo=github + :target: https://github.com/OCA/account-financial-tools/tree/12.0/account_move_line_purchase_info + :alt: OCA/account-financial-tools +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/account-financial-tools-12-0/account-financial-tools-12-0-account_move_line_purchase_info + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/92/12.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + This module will add the purchase order line to journal items. The ultimate goal is to establish the purchase order line as one of the key fields to reconcile the Goods Received Not Invoiced accrual account. +**Table of contents** + +.. contents:: + :local: Usage ===== @@ -23,43 +46,42 @@ The purchase order line will be automatically copied to the journal items. * When a stock move is validated and generates a journal entry, the purchase order line is copied to the account move line. -.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas - :alt: Try me on Runbot - :target: https://runbot.odoo-community.org/runbot/92/11.0 - Bug Tracker =========== -Bugs are tracked on `GitHub 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. +Bugs are tracked on `GitHub 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 `_. +Do not contact contributors directly about support or help with technical issues. Credits ======= -Images ------- +Authors +~~~~~~~ -* Odoo Community Association: `Icon `_. +* Eficent Contributors ------------- +~~~~~~~~~~~~ * Jordi Ballester Alomar -Maintainer ----------- +Maintainers +~~~~~~~~~~~ + +This module is maintained by the OCA. .. image:: https://odoo-community.org/logo.png :alt: Odoo Community Association :target: https://odoo-community.org -This module is maintained by the OCA. - 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. -To contribute to this module, please visit https://odoo-community.org. +This module is part of the `OCA/account-financial-tools `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_move_line_purchase_info/__manifest__.py b/account_move_line_purchase_info/__manifest__.py index 65dc1c67..704238b4 100644 --- a/account_move_line_purchase_info/__manifest__.py +++ b/account_move_line_purchase_info/__manifest__.py @@ -5,12 +5,12 @@ { "name": "Account Move Line Purchase Info", "summary": "Introduces the purchase order line to the journal items", - "version": "11.0.1.0.0", + "version": "12.0.1.0.0", "author": "Eficent, " "Odoo Community Association (OCA)", - "website": "http://www.github.com/OCA/account-financial-tools", + "website": "https://www.github.com/OCA/account-financial-tools", "category": "Generic", - "depends": ["account", "purchase"], + "depends": ["purchase_stock"], "license": "AGPL-3", "data": [ "security/account_security.xml", diff --git a/account_move_line_purchase_info/readme/CONTRIBUTORS.rst b/account_move_line_purchase_info/readme/CONTRIBUTORS.rst new file mode 100644 index 00000000..6860affe --- /dev/null +++ b/account_move_line_purchase_info/readme/CONTRIBUTORS.rst @@ -0,0 +1 @@ +* Jordi Ballester Alomar diff --git a/account_move_line_purchase_info/readme/DESCRIPTION.rst b/account_move_line_purchase_info/readme/DESCRIPTION.rst new file mode 100644 index 00000000..feda547b --- /dev/null +++ b/account_move_line_purchase_info/readme/DESCRIPTION.rst @@ -0,0 +1,4 @@ +This module will add the purchase order line to journal items. + +The ultimate goal is to establish the purchase order line as one of the key +fields to reconcile the Goods Received Not Invoiced accrual account. diff --git a/account_move_line_purchase_info/readme/USAGE.rst b/account_move_line_purchase_info/readme/USAGE.rst new file mode 100644 index 00000000..366c4a6a --- /dev/null +++ b/account_move_line_purchase_info/readme/USAGE.rst @@ -0,0 +1,7 @@ +The purchase order line will be automatically copied to the journal items. + +* When a supplier invoice is created referencing purchase orders, the + purchase order line will be copied to the corresponding journal item. + +* When a stock move is validated and generates a journal entry, the purchase + order line is copied to the account move line. diff --git a/account_move_line_purchase_info/security/account_security.xml b/account_move_line_purchase_info/security/account_security.xml index 8e5894f8..91f09ab5 100644 --- a/account_move_line_purchase_info/security/account_security.xml +++ b/account_move_line_purchase_info/security/account_security.xml @@ -4,7 +4,7 @@ Purchase info in Journal Items - + diff --git a/account_move_line_purchase_info/static/description/index.html b/account_move_line_purchase_info/static/description/index.html new file mode 100644 index 00000000..155f9e0c --- /dev/null +++ b/account_move_line_purchase_info/static/description/index.html @@ -0,0 +1,410 @@ + + + + + + +Account Move Line Purchase Info + + + +
+

Account Move Line Purchase Info

+ + +

Beta License: AGPL-3 OCA/account-financial-tools Translate me on Weblate Try me on Runbot

+

This module will add the purchase order line to journal items.

+

The ultimate goal is to establish the purchase order line as one of the key +fields to reconcile the Goods Received Not Invoiced accrual account.

+

Table of contents

+ +
+

Usage

+

The purchase order line will be automatically copied to the journal items.

+
    +
  • When a supplier invoice is created referencing purchase orders, the +purchase order line will be copied to the corresponding journal item.
  • +
  • When a stock move is validated and generates a journal entry, the purchase +order line is copied to the account move line.
  • +
+
+
+

Bug Tracker

+

Bugs are tracked on GitHub 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.

+

Do not contact contributors directly about support or help with technical issues.

+
+
+

Credits

+
+

Authors

+
    +
  • Eficent
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

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/account-financial-tools project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/account_move_line_purchase_info/tests/test_account_move_line_purchase_info.py b/account_move_line_purchase_info/tests/test_account_move_line_purchase_info.py index 7cb5e83b..18b65f14 100644 --- a/account_move_line_purchase_info/tests/test_account_move_line_purchase_info.py +++ b/account_move_line_purchase_info/tests/test_account_move_line_purchase_info.py @@ -136,7 +136,7 @@ class TestAccountMoveLinePurchaseInfo(common.TransactionCase): ) return self.purchase_model.create({ 'partner_id': self.partner1.id, - 'order_line': lines + 'order_line': lines, }) def _get_balance(self, domain): @@ -177,7 +177,7 @@ class TestAccountMoveLinePurchaseInfo(common.TransactionCase): break purchase.button_confirm() picking = purchase.picking_ids[0] - picking.force_assign() + picking.action_confirm() picking.move_lines.write({'quantity_done': 1.0}) picking.button_validate()