fix(UX): Optimize rate updation of changing price list

(cherry picked from commit 6087d5a603)
This commit is contained in:
Deepesh Garg
2021-12-20 12:16:14 +05:30
committed by mergify-bot
parent cfb6b26e47
commit ab09dc545e
2 changed files with 6 additions and 3 deletions

View File

@@ -1097,7 +1097,7 @@ def apply_price_list(args, as_doc=False):
}
def apply_price_list_on_item(args):
item_doc = frappe.get_doc("Item", args.item_code)
item_doc = frappe.db.get_value("Item", args.item_code, ['name', 'variant_of'], as_dict=1)
item_details = get_price_list_rate(args, item_doc)
item_details.update(get_pricing_rule_for_item(args, item_details.price_list_rate))