mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-06 21:59:13 +00:00
fix(product-listing): Check if customer exists (#24030)
- It might happen that perty_name might not always be Customer (it might be Supplier as well)
This commit is contained in:
@@ -345,7 +345,7 @@ def _set_price_list(cart_settings, quotation=None):
|
|||||||
selling_price_list = None
|
selling_price_list = None
|
||||||
|
|
||||||
# check if default customer price list exists
|
# check if default customer price list exists
|
||||||
if party_name:
|
if party_name and frappe.db.exists("Customer", party_name):
|
||||||
selling_price_list = get_default_price_list(frappe.get_doc("Customer", party_name))
|
selling_price_list = get_default_price_list(frappe.get_doc("Customer", party_name))
|
||||||
|
|
||||||
# check default price list in shopping cart
|
# check default price list in shopping cart
|
||||||
|
|||||||
Reference in New Issue
Block a user