mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 10:49:09 +00:00
fix: Revert commit 46372fe
This commit is contained in:
@@ -691,7 +691,7 @@ class PaymentEntry(AccountsController):
|
|||||||
"cost_center": self.cost_center
|
"cost_center": self.cost_center
|
||||||
}, item=self)
|
}, item=self)
|
||||||
|
|
||||||
dr_or_cr = "credit" if self.payment_type == 'Receive' else "debit"
|
dr_or_cr = "credit" if erpnext.get_party_account_type(self.party_type) == 'Receivable' else "debit"
|
||||||
|
|
||||||
for d in self.get("references"):
|
for d in self.get("references"):
|
||||||
gle = party_gl_dict.copy()
|
gle = party_gl_dict.copy()
|
||||||
@@ -700,11 +700,11 @@ class PaymentEntry(AccountsController):
|
|||||||
"against_voucher": d.reference_name
|
"against_voucher": d.reference_name
|
||||||
})
|
})
|
||||||
|
|
||||||
allocated_amount_in_company_currency = abs(flt(flt(d.allocated_amount) * flt(d.exchange_rate),
|
allocated_amount_in_company_currency = flt(flt(d.allocated_amount) * flt(d.exchange_rate),
|
||||||
self.precision("paid_amount")))
|
self.precision("paid_amount"))
|
||||||
|
|
||||||
gle.update({
|
gle.update({
|
||||||
dr_or_cr + "_in_account_currency": abs(d.allocated_amount),
|
dr_or_cr + "_in_account_currency": d.allocated_amount,
|
||||||
dr_or_cr: allocated_amount_in_company_currency
|
dr_or_cr: allocated_amount_in_company_currency
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user