Skip to content

Commit

Permalink
fix(pricing rule): consider child tables in condition (backport #33469)…
Browse files Browse the repository at this point in the history
… (#33470)

fix(pricing rule): consider child tables in condition (#33469)

(cherry picked from commit cabaed9)

Co-authored-by: Dany Robert <rtdany10@gmail.com>
  • Loading branch information
mergify[bot] and rtdany10 authored Dec 29, 2022
1 parent 1b7be86 commit 3bceb47
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions erpnext/accounts/doctype/pricing_rule/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,10 +246,15 @@ def get_other_conditions(conditions, values, args):

if args.get("doctype") in [
"Quotation",
"Quotation Item",
"Sales Order",
"Sales Order Item",
"Delivery Note",
"Delivery Note Item",
"Sales Invoice",
"Sales Invoice Item",
"POS Invoice",
"POS Invoice Item",
]:
conditions += """ and ifnull(`tabPricing Rule`.selling, 0) = 1"""
else:
Expand Down

0 comments on commit 3bceb47

Please sign in to comment.