Skip to content

Commit

Permalink
fix: add item group filter added in item-wise purchase register (#36937)
Browse files Browse the repository at this point in the history
fix: add item group filter added in item-wise purchase register (#36937)
  • Loading branch information
Nandhinidevi123 authored Sep 19, 2023
1 parent 141ba25 commit 6be567d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ frappe.query_reports["Item-wise Purchase Register"] = {
"fieldtype": "Link",
"options": "Item",
},
{
"fieldname": "item_group",
"label": __("Item Group"),
"fieldtype": "Link",
"options": "Item Group",
},
{
"fieldname":"supplier",
"label": __("Supplier"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,7 @@ def get_conditions(filters):
("from_date", " and `tabPurchase Invoice`.posting_date>=%(from_date)s"),
("to_date", " and `tabPurchase Invoice`.posting_date<=%(to_date)s"),
("mode_of_payment", " and ifnull(mode_of_payment, '') = %(mode_of_payment)s"),
("item_group", " and ifnull(`tabPurchase Invoice Item`.item_group, '') = %(item_group)s"),
):
if filters.get(opts[0]):
conditions += opts[1]
Expand Down

0 comments on commit 6be567d

Please sign in to comment.