From 99bc02d0e0450718eab19883b2ee16c971231d86 Mon Sep 17 00:00:00 2001 From: iamkhanraheel Date: Mon, 23 Jun 2025 14:20:27 +0530 Subject: [PATCH] fix: update fieldname in filter --- .../doctype/party_specific_item/party_specific_item.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/selling/doctype/party_specific_item/party_specific_item.py b/erpnext/selling/doctype/party_specific_item/party_specific_item.py index cce29f0ed27..d1775c2467c 100644 --- a/erpnext/selling/doctype/party_specific_item/party_specific_item.py +++ b/erpnext/selling/doctype/party_specific_item/party_specific_item.py @@ -23,13 +23,13 @@ class PartySpecificItem(Document): def validate(self): exists = frappe.db.exists( + "Party Specific Item", { - "doctype": "Party Specific Item", "party_type": self.party_type, "party": self.party, "restrict_based_on": self.restrict_based_on, - "based_on": self.based_on_value, - } + "based_on_value": self.based_on_value, + }, ) if exists: frappe.throw(_("This item filter has already been applied for the {0}").format(self.party_type))