Merge pull request #39183 from frappe/mergify/bp/version-15-hotfix/pr-39161
refactor: allow sales invoice in Bank Reconciliation tool (backport #39161)
This commit is contained in:
commit
f1d25700a8
@ -366,15 +366,17 @@ def set_voucher_clearance(doctype, docname, clearance_date, self):
|
|||||||
and len(get_reconciled_bank_transactions(doctype, docname)) < 2
|
and len(get_reconciled_bank_transactions(doctype, docname)) < 2
|
||||||
):
|
):
|
||||||
return
|
return
|
||||||
frappe.db.set_value(doctype, docname, "clearance_date", clearance_date)
|
|
||||||
|
|
||||||
elif doctype == "Sales Invoice":
|
if doctype == "Sales Invoice":
|
||||||
frappe.db.set_value(
|
frappe.db.set_value(
|
||||||
"Sales Invoice Payment",
|
"Sales Invoice Payment",
|
||||||
dict(parenttype=doctype, parent=docname),
|
dict(parenttype=doctype, parent=docname),
|
||||||
"clearance_date",
|
"clearance_date",
|
||||||
clearance_date,
|
clearance_date,
|
||||||
)
|
)
|
||||||
|
return
|
||||||
|
|
||||||
|
frappe.db.set_value(doctype, docname, "clearance_date", clearance_date)
|
||||||
|
|
||||||
elif doctype == "Bank Transaction":
|
elif doctype == "Bank Transaction":
|
||||||
# For when a second bank transaction has fixed another, e.g. refund
|
# For when a second bank transaction has fixed another, e.g. refund
|
||||||
|
@ -494,6 +494,7 @@ bank_reconciliation_doctypes = [
|
|||||||
"Payment Entry",
|
"Payment Entry",
|
||||||
"Journal Entry",
|
"Journal Entry",
|
||||||
"Purchase Invoice",
|
"Purchase Invoice",
|
||||||
|
"Sales Invoice",
|
||||||
]
|
]
|
||||||
|
|
||||||
accounting_dimension_doctypes = [
|
accounting_dimension_doctypes = [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user