diff --git a/rma_sale_mrp/README.rst b/rma_sale_mrp/README.rst index 0ee1b502..a06e04ec 100644 --- a/rma_sale_mrp/README.rst +++ b/rma_sale_mrp/README.rst @@ -14,13 +14,13 @@ Return Merchandise Authorization Management - Link with MRP Kits :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Frma-lightgray.png?logo=github - :target: https://github.com/OCA/rma/tree/14.0/rma_sale_mrp + :target: https://github.com/OCA/rma/tree/15.0/rma_sale_mrp :alt: OCA/rma .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/rma-14-0/rma-14-0-rma_sale_mrp + :target: https://translation.odoo-community.org/projects/rma-15-0/rma-15-0-rma_sale_mrp :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/145/14.0 + :target: https://runbot.odoo-community.org/runbot/145/15.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -74,7 +74,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. @@ -114,6 +114,6 @@ Current `maintainer `__: |maintainer-chienandalu| -This module is part of the `OCA/rma `_ project on GitHub. +This module is part of the `OCA/rma `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/rma_sale_mrp/__manifest__.py b/rma_sale_mrp/__manifest__.py index 9d22d5ff..bab7f708 100644 --- a/rma_sale_mrp/__manifest__.py +++ b/rma_sale_mrp/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Return Merchandise Authorization Management - Link with MRP Kits", "summary": "Allow doing RMAs from MRP kits", - "version": "14.0.1.0.0", + "version": "15.0.1.0.0", "development_status": "Beta", "category": "RMA", "website": "https://github.com/OCA/rma", diff --git a/rma_sale_mrp/models/rma.py b/rma_sale_mrp/models/rma.py index 870c3fbb..741af052 100644 --- a/rma_sale_mrp/models/rma.py +++ b/rma_sale_mrp/models/rma.py @@ -48,7 +48,7 @@ class Rma(models.Model): _("You can't refund a kit in wich some RMAs aren't received") ) self |= rmas_by_register[0] - super().action_refund() + res = super().action_refund() # We can just link the line to an RMA but we can link several RMAs # to one invoice line. for rma_kit_register in set(phantom_rmas.mapped("rma_kit_register")): @@ -64,3 +64,4 @@ class Rma(models.Model): "state": "refunded", } ) + return res diff --git a/rma_sale_mrp/models/sale_order.py b/rma_sale_mrp/models/sale_order.py index 418ac096..5a19459c 100644 --- a/rma_sale_mrp/models/sale_order.py +++ b/rma_sale_mrp/models/sale_order.py @@ -124,9 +124,9 @@ class SaleOrderLine(models.Model): self.env["mrp.bom"] .sudo() ._bom_find( - product=self.product_id, + products=self.product_id, company_id=self.company_id.id, bom_type="phantom", ) ) - return bom and bom.type == "phantom" + return bom and bom.get(self.product_id).type == "phantom" diff --git a/rma_sale_mrp/static/description/index.html b/rma_sale_mrp/static/description/index.html index f49f3644..18a865dd 100644 --- a/rma_sale_mrp/static/description/index.html +++ b/rma_sale_mrp/static/description/index.html @@ -3,7 +3,7 @@ - + Return Merchandise Authorization Management - Link with MRP Kits