mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-05 03:23:35 +00:00
fix: check if product_info exists
This commit is contained in:
@@ -73,7 +73,8 @@ class ProductQuery:
|
||||
|
||||
for item in result:
|
||||
product_info = get_product_info_for_website(item.item_code, skip_quotation_creation=True).get('product_info')
|
||||
item.formatted_price = product_info['price'].get('formatted_price') if product_info['price'] else None
|
||||
if product_info:
|
||||
item.formatted_price = product_info['price'].get('formatted_price') if product_info['price'] else None
|
||||
|
||||
return result
|
||||
|
||||
|
||||
Reference in New Issue
Block a user