From 0fa15b6d482fda02e467d06d160165c1c1f26c8b Mon Sep 17 00:00:00 2001 From: maniamartial Date: Wed, 3 Jul 2024 11:19:43 +0300 Subject: [PATCH] Code cleaning --- burundi_compliance/burundi_compliance/utils/schedular.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/burundi_compliance/burundi_compliance/utils/schedular.py b/burundi_compliance/burundi_compliance/utils/schedular.py index a8862d2..58622ae 100644 --- a/burundi_compliance/burundi_compliance/utils/schedular.py +++ b/burundi_compliance/burundi_compliance/utils/schedular.py @@ -81,7 +81,7 @@ def check_and_send_pending_cancelled_invoice_from_integration_request(): for integration_request in integration_requests: try: sales_invoice_doc = frappe.get_doc("Sales Invoice", integration_request.reference_docname) - if sales_invoice_doc.docstatus == 2 and sales_invoice_doc.custom_submitted_to_obr == 1 and sales_invoice_doc.custom_ebms_invoice_cancelled == 0: + if sales_invoice_doc.docstatus == 2 and sales_invoice_doc.custom_submitted_to_obr == 0 and sales_invoice_doc.custom_ebms_invoice_cancelled == 0: cancel_invoice(sales_invoice_doc) except Exception as e: frappe.log_error(frappe.get_traceback(), "Error in sending sales invoice {0}".format(integration_request.reference_docname))