Table Name: tabPricing Rule
| Sr | Fieldname | Type | Label | Options |
|---|---|---|---|---|
| 1 | applicability_section |
Section Break | ||
| 2 | title |
Data | Title | |
| 3 | apply_on |
Select | Apply On |
Item Code Item Group Brand |
| 4 | item_code |
Link | Item Code | Item |
| 5 | brand |
Link | Brand | Brand |
| 6 | item_group |
Link | Item Group | Item Group |
| 7 | column_break_7 |
Column Break | ||
| 8 | priority |
Select |
Priority
Higher the number, higher the priority |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
| 9 | disable |
Check | Disable | |
| 10 | section_break_7 |
Section Break | ||
| 11 | selling |
Check | Selling | |
| 12 | buying |
Check | Buying | |
| 13 | column_break_11 |
Column Break | ||
| 14 | applicable_for |
Select | Applicable For |
Customer Customer Group Territory Sales Partner Campaign Supplier Supplier Type |
| 15 | customer |
Link | Customer | Customer |
| 16 | customer_group |
Link | Customer Group | Customer Group |
| 17 | territory |
Link | Territory | Territory |
| 18 | sales_partner |
Link | Sales Partner | Sales Partner |
| 19 | campaign |
Link | Campaign | Campaign |
| 20 | supplier |
Link | Supplier | Supplier |
| 21 | supplier_type |
Link | Supplier Type | Supplier Type |
| 22 | section_break_19 |
Section Break | ||
| 23 | min_qty |
Float | Min Qty | |
| 24 | column_break_21 |
Column Break | ||
| 25 | max_qty |
Float | Max Qty | |
| 26 | section_break_23 |
Section Break | ||
| 27 | valid_from |
Date | Valid From | |
| 28 | valid_upto |
Date | Valid Upto | |
| 29 | col_break1 |
Column Break | ||
| 30 | company |
Link | Company | Company |
| 31 | price_discount_section |
Section Break | ||
| 32 | price_or_discount |
Select | Price or Discount |
Price Discount Percentage |
| 33 | col_break2 |
Column Break | ||
| 34 | price |
Float | Price | |
| 35 | discount_percentage |
Float | Discount on Price List Rate (%) | |
| 36 | for_price_list |
Link | For Price List | Price List |
| 37 | help_section |
Section Break |
Simple |
|
| 38 | pricing_rule_help |
HTML | Pricing Rule Help |
Inherits from frappe.exceptions.ValidationError
Inherits from frappe.model.document.Document
No docs
No docs
validate_applicable_for_selling_or_buying (self)
No docs
No docs
No docs
No docs
validate_price_or_discount (self)
No docs
erpnext.accounts.doctype.pricing_rule.pricing_rule.apply_internal_priority (pricing_rules, field_set, args)
No docs
Public API
/api/method/erpnext.accounts.doctype.pricing_rule.pricing_rule.apply_pricing_rule
erpnext.accounts.doctype.pricing_rule.pricing_rule.apply_pricing_rule (args)
args = { "itemlist": [{"doctype": "", "name": "", "itemcode": "", "brand": "", "itemgroup": ""}, ...], "customer": "something", "customergroup": "something", "territory": "something", "supplier": "something", "suppliertype": "something", "currency": "something", "conversionrate": "something", "pricelist": "something", "plcconversionrate": "something", "company": "something", "transactiondate": "something", "campaign": "something", "salespartner": "something", "ignorepricing_rule": "something" }
erpnext.accounts.doctype.pricing_rule.pricing_rule.filter_pricing_rules (args, pricing_rules)
No docs
erpnext.accounts.doctype.pricing_rule.pricing_rule.get_pricing_rule_for_item (args)
No docs
erpnext.accounts.doctype.pricing_rule.pricing_rule.get_pricing_rules (args)
No docs
erpnext.accounts.doctype.pricing_rule.pricing_rule.if_all_rules_same (pricing_rules, fields)
No docs