mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-18 14:32:13 +00:00
refactor: filter to toggle employee advance scenario in AP
(cherry picked from commit 257e13c299)
# Conflicts:
# erpnext/accounts/report/accounts_payable/accounts_payable.js
This commit is contained in:
@@ -158,8 +158,13 @@ frappe.query_reports["Accounts Payable"] = {
|
||||
fieldtype: "Check",
|
||||
},
|
||||
{
|
||||
<<<<<<< HEAD
|
||||
fieldname: "in_party_currency",
|
||||
label: __("In Party Currency"),
|
||||
=======
|
||||
fieldname: "handle_employee_advances",
|
||||
label: __("Handle Employee Advances"),
|
||||
>>>>>>> 257e13c299 (refactor: filter to toggle employee advance scenario in AP)
|
||||
fieldtype: "Check",
|
||||
},
|
||||
],
|
||||
|
||||
@@ -214,7 +214,11 @@ class ReceivablePayableReport:
|
||||
|
||||
# Build and use a separate row for Employee Advances.
|
||||
# This allows Payments or Journals made against Emp Advance to be processed.
|
||||
if not row and ple.against_voucher_type == "Employee Advance":
|
||||
if (
|
||||
not row
|
||||
and ple.against_voucher_type == "Employee Advance"
|
||||
and self.filters.handle_employee_advances
|
||||
):
|
||||
_d = self.build_voucher_dict(ple)
|
||||
_d.voucher_type = ple.against_voucher_type
|
||||
_d.voucher_no = ple.against_voucher_no
|
||||
|
||||
Reference in New Issue
Block a user