diff --git a/mrp_sale_info/README.rst b/mrp_sale_info/README.rst index 8d928c6ea..f1550fb52 100644 --- a/mrp_sale_info/README.rst +++ b/mrp_sale_info/README.rst @@ -14,13 +14,13 @@ MRP Sale Info :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fmanufacture-lightgray.png?logo=github - :target: https://github.com/OCA/manufacture/tree/14.0/mrp_sale_info + :target: https://github.com/OCA/manufacture/tree/15.0/mrp_sale_info :alt: OCA/manufacture .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/manufacture-14-0/manufacture-14-0-mrp_sale_info + :target: https://translation.odoo-community.org/projects/manufacture-15-0/manufacture-15-0-mrp_sale_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/129/14.0 + :target: https://runbot.odoo-community.org/runbot/129/15.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -49,7 +49,7 @@ 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -74,6 +74,8 @@ Contributors * Antonio Espinosa * Rafael Blasco * Pedro M. Baeza +* `Glo Systems `_: + * Edwin Blommaerts * Rubén Bravo * Kevin Khao * Alex Comba @@ -91,6 +93,6 @@ 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/manufacture `_ project on GitHub. +This module is part of the `OCA/manufacture `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/mrp_sale_info/__manifest__.py b/mrp_sale_info/__manifest__.py index 5457a8cdb..8ae12156d 100644 --- a/mrp_sale_info/__manifest__.py +++ b/mrp_sale_info/__manifest__.py @@ -5,10 +5,10 @@ { "name": "MRP Sale Info", "summary": "Adds sale information to Manufacturing models", - "version": "14.0.1.1.0", + "version": "15.0.1.0.0", "category": "Manufacturing", "website": "https://github.com/OCA/manufacture", - "author": "AvanzOSC, " "Tecnativa, " "Odoo Community Association (OCA)", + "author": "AvanzOSC, Tecnativa, Odoo Community Association (OCA)", "license": "AGPL-3", "application": False, "installable": True, diff --git a/mrp_sale_info/readme/CONTRIBUTORS.rst b/mrp_sale_info/readme/CONTRIBUTORS.rst index b929a58e2..18d2420e1 100644 --- a/mrp_sale_info/readme/CONTRIBUTORS.rst +++ b/mrp_sale_info/readme/CONTRIBUTORS.rst @@ -10,3 +10,4 @@ * Rubén Bravo * Kevin Khao * Alex Comba +* Mantas Šniukas diff --git a/mrp_sale_info/tests/test_mrp_sale_info.py b/mrp_sale_info/tests/test_mrp_sale_info.py index 132111422..aa6491df0 100644 --- a/mrp_sale_info/tests/test_mrp_sale_info.py +++ b/mrp_sale_info/tests/test_mrp_sale_info.py @@ -4,7 +4,7 @@ from odoo.tests import common -class TestMrpSaleInfo(common.SavepointCase): +class TestMrpSaleInfo(common.TransactionCase): @classmethod def setUpClass(cls): super().setUpClass() @@ -24,6 +24,16 @@ class TestMrpSaleInfo(common.SavepointCase): cls.bom = cls.env["mrp.bom"].create( { "product_tmpl_id": cls.product.product_tmpl_id.id, + "operation_ids": [ + ( + 0, + 0, + { + "name": "Test operation", + "workcenter_id": cls.env.ref("mrp.mrp_workcenter_3").id, + }, + ) + ], } ) cls.partner = cls.env["res.partner"].create({"name": "Test client"}) @@ -52,3 +62,11 @@ class TestMrpSaleInfo(common.SavepointCase): self.assertEqual(production.sale_id, self.sale_order) self.assertEqual(production.partner_id, self.partner) self.assertEqual(production.client_order_ref, self.sale_order.client_order_ref) + + def test_mrp_workorder(self): + prev_workorders = self.env["mrp.workorder"].search([]) + self.sale_order.action_confirm() + workorder = self.env["mrp.workorder"].search([]) - prev_workorders + self.assertEqual(workorder.sale_id, self.sale_order) + self.assertEqual(workorder.partner_id, self.partner) + self.assertEqual(workorder.client_order_ref, self.sale_order.client_order_ref)