mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-24 07:29:22 +00:00
refactor: allow reconciliation date for exchange gain / loss
(cherry picked from commit 95af63e305)
# Conflicts:
# erpnext/accounts/doctype/accounts_settings/accounts_settings.json
This commit is contained in:
@@ -537,8 +537,12 @@
|
|||||||
"fieldname": "exchange_gain_loss_posting_date",
|
"fieldname": "exchange_gain_loss_posting_date",
|
||||||
"fieldtype": "Select",
|
"fieldtype": "Select",
|
||||||
"label": "Posting Date Inheritance for Exchange Gain / Loss",
|
"label": "Posting Date Inheritance for Exchange Gain / Loss",
|
||||||
|
<<<<<<< HEAD
|
||||||
"options": "Invoice\nPayment"
|
"options": "Invoice\nPayment"
|
||||||
>>>>>>> 3fbd2ca0d9 (refactor: configurable posting date for Exc Gain / Loss journal)
|
>>>>>>> 3fbd2ca0d9 (refactor: configurable posting date for Exc Gain / Loss journal)
|
||||||
|
=======
|
||||||
|
"options": "Invoice\nPayment\nReconciliation Date"
|
||||||
|
>>>>>>> 95af63e305 (refactor: allow reconciliation date for exchange gain / loss)
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"icon": "icon-cog",
|
"icon": "icon-cog",
|
||||||
@@ -546,11 +550,15 @@
|
|||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
|
<<<<<<< HEAD
|
||||||
<<<<<<< HEAD
|
<<<<<<< HEAD
|
||||||
"modified": "2024-01-22 12:10:10.151819",
|
"modified": "2024-01-22 12:10:10.151819",
|
||||||
=======
|
=======
|
||||||
"modified": "2025-01-22 17:53:47.968079",
|
"modified": "2025-01-22 17:53:47.968079",
|
||||||
>>>>>>> 3fbd2ca0d9 (refactor: configurable posting date for Exc Gain / Loss journal)
|
>>>>>>> 3fbd2ca0d9 (refactor: configurable posting date for Exc Gain / Loss journal)
|
||||||
|
=======
|
||||||
|
"modified": "2025-01-23 13:15:44.077853",
|
||||||
|
>>>>>>> 95af63e305 (refactor: allow reconciliation date for exchange gain / loss)
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Accounts",
|
"module": "Accounts",
|
||||||
"name": "Accounts Settings",
|
"name": "Accounts Settings",
|
||||||
@@ -579,4 +587,4 @@
|
|||||||
"sort_order": "ASC",
|
"sort_order": "ASC",
|
||||||
"states": [],
|
"states": [],
|
||||||
"track_changes": 1
|
"track_changes": 1
|
||||||
}
|
}
|
||||||
@@ -46,7 +46,7 @@ class AccountsSettings(Document):
|
|||||||
enable_fuzzy_matching: DF.Check
|
enable_fuzzy_matching: DF.Check
|
||||||
enable_immutable_ledger: DF.Check
|
enable_immutable_ledger: DF.Check
|
||||||
enable_party_matching: DF.Check
|
enable_party_matching: DF.Check
|
||||||
exchange_gain_loss_posting_date: DF.Literal["Invoice", "Payment"]
|
exchange_gain_loss_posting_date: DF.Literal["Invoice", "Payment", "Reconciliation Date"]
|
||||||
frozen_accounts_modifier: DF.Link | None
|
frozen_accounts_modifier: DF.Link | None
|
||||||
general_ledger_remarks_length: DF.Int
|
general_ledger_remarks_length: DF.Int
|
||||||
ignore_account_closing_balance: DF.Check
|
ignore_account_closing_balance: DF.Check
|
||||||
|
|||||||
@@ -385,6 +385,8 @@ class PaymentReconciliation(Document):
|
|||||||
res.update({"gain_loss_posting_date": pay.get("posting_date")})
|
res.update({"gain_loss_posting_date": pay.get("posting_date")})
|
||||||
if exc_gain_loss_posting_date == "Invoice":
|
if exc_gain_loss_posting_date == "Invoice":
|
||||||
res.update({"gain_loss_posting_date": inv.get("invoice_date")})
|
res.update({"gain_loss_posting_date": inv.get("invoice_date")})
|
||||||
|
elif exc_gain_loss_posting_date == "Reconciliation Date":
|
||||||
|
res.update({"gain_loss_posting_date": nowdate()})
|
||||||
|
|
||||||
if pay.get("amount") == 0:
|
if pay.get("amount") == 0:
|
||||||
entries.append(res)
|
entries.append(res)
|
||||||
|
|||||||
Reference in New Issue
Block a user