Browse Source

Mar 15 [UPDT] : Updated 'automatic_invoice_and_post'

pull/278/merge
AjmalCybro 1 year ago
parent
commit
a33bfe5639
  1. 3
      automatic_invoice_and_post/README.rst
  2. 2
      automatic_invoice_and_post/__manifest__.py
  3. 5
      automatic_invoice_and_post/doc/RELEASE_NOTES.md
  4. 5
      automatic_invoice_and_post/models/stock_picking.py

3
automatic_invoice_and_post/README.rst

@ -1,11 +1,11 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg .. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3 :alt: License: AGPL-3
Automatic Invoice And Post Automatic Invoice And Post
============================== ==============================
This module generates and post invoice while validating the delivery. This module generates and post invoice while validating the delivery.
Configuration Configuration
============= =============
* No additional configurations needed * No additional configurations needed
@ -22,7 +22,6 @@ Credits
------- -------
* Developers: Version 16: Akhil @cybrosys * Developers: Version 16: Akhil @cybrosys
Contacts Contacts
-------- --------
* Mail Contact : odoo@cybrosys.com * Mail Contact : odoo@cybrosys.com

2
automatic_invoice_and_post/__manifest__.py

@ -21,7 +21,7 @@
############################################################################# #############################################################################
{ {
'name': 'Automatic Invoice And Post', 'name': 'Automatic Invoice And Post',
'version': "16.0.1.0.0", 'version': "16.0.1.0.1",
'depends': ['base', 'sale_management', 'stock', 'account'], 'depends': ['base', 'sale_management', 'stock', 'account'],
'category': 'Sales,Warehouse,Accounting', 'category': 'Sales,Warehouse,Accounting',
'summary': """ Auto Invoice from Delivery validate.""", 'summary': """ Auto Invoice from Delivery validate.""",

5
automatic_invoice_and_post/doc/RELEASE_NOTES.md

@ -5,4 +5,9 @@
##### ADD ##### ADD
- Initial commit for Automatic Invoice And Post - 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.

5
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') 'automatic_invoice_and_post.is_create_invoice_delivery_validate')
auto_send_invoice = self.env['ir.config_parameter'].sudo().get_param( auto_send_invoice = self.env['ir.config_parameter'].sudo().get_param(
'automatic_invoice_and_post.is_auto_send_invoice') '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 if any(rec.product_id.invoice_policy == 'delivery' for rec in
self.move_ids) or not self.sale_id.invoice_ids: self.move_ids) or not self.sale_id.invoice_ids:
# Call the _create_invoices function on the associated sale # Call the _create_invoices function on the associated sale
# to create the invoice # 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 self.sale_id) if self.sale_id else False
# Post the created invoice # Post the created invoice
if invoice_created: if invoice_created:

Loading…
Cancel
Save