diff --git a/automatic_invoice_and_post/README.rst b/automatic_invoice_and_post/README.rst index 55cfc08d9..9b8858dfe 100755 --- a/automatic_invoice_and_post/README.rst +++ b/automatic_invoice_and_post/README.rst @@ -1,11 +1,11 @@ .. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 + Automatic Invoice And Post ============================== This module generates and post invoice while validating the delivery. - Configuration ============= * No additional configurations needed @@ -22,7 +22,6 @@ Credits ------- * Developers: Version 16: Akhil @cybrosys - Contacts -------- * Mail Contact : odoo@cybrosys.com diff --git a/automatic_invoice_and_post/__manifest__.py b/automatic_invoice_and_post/__manifest__.py index fccb7117a..4047d45d3 100644 --- a/automatic_invoice_and_post/__manifest__.py +++ b/automatic_invoice_and_post/__manifest__.py @@ -21,7 +21,7 @@ ############################################################################# { 'name': 'Automatic Invoice And Post', - 'version': "16.0.1.0.0", + 'version': "16.0.1.0.1", 'depends': ['base', 'sale_management', 'stock', 'account'], 'category': 'Sales,Warehouse,Accounting', 'summary': """ Auto Invoice from Delivery validate.""", diff --git a/automatic_invoice_and_post/doc/RELEASE_NOTES.md b/automatic_invoice_and_post/doc/RELEASE_NOTES.md index c12808e81..d9c67257b 100644 --- a/automatic_invoice_and_post/doc/RELEASE_NOTES.md +++ b/automatic_invoice_and_post/doc/RELEASE_NOTES.md @@ -5,4 +5,9 @@ ##### ADD - Initial commit for Automatic Invoice And Post +#### 19.02.2024 +#### Version 16.0.1.0.1 +##### UPDT +- Bug Fix-Resolved the error while generating back order. + diff --git a/automatic_invoice_and_post/models/stock_picking.py b/automatic_invoice_and_post/models/stock_picking.py index 86db50b8a..c32d3d361 100644 --- a/automatic_invoice_and_post/models/stock_picking.py +++ b/automatic_invoice_and_post/models/stock_picking.py @@ -48,12 +48,13 @@ class StockPicking(models.Model): 'automatic_invoice_and_post.is_create_invoice_delivery_validate') auto_send_invoice = self.env['ir.config_parameter'].sudo().get_param( 'automatic_invoice_and_post.is_auto_send_invoice') - if auto_validate_invoice: + if auto_validate_invoice and res is True: if any(rec.product_id.invoice_policy == 'delivery' for rec in self.move_ids) or not self.sale_id.invoice_ids: # Call the _create_invoices function on the associated sale # to create the invoice - invoice_created = self.sale_id._create_invoices( + invoice_created = self.sale_id.with_context( + raise_if_nothing_to_invoice=False)._create_invoices( self.sale_id) if self.sale_id else False # Post the created invoice if invoice_created: