Skip to content

Commit

Permalink
fix: use name for links not item_code (#30462)
Browse files Browse the repository at this point in the history
(cherry picked from commit 76dce2e)

# Conflicts:
#	erpnext/selling/report/item_wise_sales_history/item_wise_sales_history.py
  • Loading branch information
ankush authored and mergify-bot committed Mar 29, 2022
1 parent 8e59e67 commit 02f56e9
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,7 @@ def get_customer_details():
return customer_details

def get_item_details():
<<<<<<< HEAD
details = frappe.db.get_all("Item",
fields=["item_code", "item_name", "item_group"])
item_details = {}
Expand All @@ -218,6 +219,14 @@ def get_item_details():
"item_name": d.item_name,
"item_group": d.item_group
}))
=======
details = frappe.db.get_all("Item", fields=["name", "item_name", "item_group"])
item_details = {}
for d in details:
item_details.setdefault(
d.name, frappe._dict({"item_name": d.item_name, "item_group": d.item_group})
)
>>>>>>> 76dce2eddc (fix: use `name` for links not `item_code` (#30462))
return item_details

def get_sales_order_details(company_list, filters):
Expand Down

0 comments on commit 02f56e9

Please sign in to comment.