Skip to main content

Price Rules

Price Rules in ianaiERP let you adjust an item's selling price automatically based on who is buying, what is being bought, and the item's attributes. A rule combines a target (which customers and items it applies to) with a price adjustment (how the price changes), and matching active rules are applied in priority order at quote/invoice time.

Accessing the Price Rule

To view, edit, or manage Price Rules:

  1. Go to Miscellaneous > Price Rule.

Key Features

  • Automatic Price Adjustments: Adjust item prices automatically in Sales Orders and Estimates based on predefined rules.
  • Flexible Targeting: Apply rules to all or selected customers/items using conditions like customer type, item category, attributes, and more.
  • Multiple Adjustment Methods: Supports percentage-based, fixed amount, and conditional rules based on item options or attributes.
  • Cumulative Rule Application: All matching rules are applied in order of priority, allowing layered pricing strategies.
  • Priority Control: Drag-and-drop interface to define the sequence of rule application, crucial for correct calculation when using percentages.
  • Date-Based Activation: Rules can be configured to apply only within a specific date range.
  • Inline Price Breakdown: See a breakdown of applied rules by hovering over unit prices in Estimates and Sales Orders.
  • Bulk Add Items / Customers: Add many items or customers in one step via a multi-select picker or paste-list.
  • Bulk Row Actions: Activate, deactivate, shift dates, duplicate, or delete several rules at once from the list.
  • Duplicate Wizard: Clone a rule with overrides, or fan it out across customers, customer types, or item categories.
  • Matrix Editor: Author tabular pricing across 1–3 dimensions (e.g. width × height × material) without hand-building hundreds of tiers.

Setting Up the Price Rule

Click Add New on the top right to define a new price rule. A price rule consists of three key sections.

1. Basic Information

  • Name: A descriptive label to identify the rule.
  • Description: Optional explanation for internal use.
  • Start Date / End Date: Defines the active period of the rule (either one or both dates can be set).
  • Enabled: Toggle to activate or deactivate the rule.

If the current date is outside the defined period or the rule is disabled, it will not be applied.

2. Target Definition

Specify which customers or items the rule will apply to. The Target section contains two tabs: Customer and Item. Each tab offers three targeting methods:

  • All: Apply to all customers/items.
  • Select By Condition: Apply based on conditions.
  • Select Individually: Apply to specific customers/items.

Select By Condition

Build a condition expression with AND/OR logic and parentheses.

  • Customer side fields: Customer, Customer Type, Sales Representative, Companies.
  • Item side fields: Item, Item Category, Item Type, Item Attribute, Item Option.

Multiple conditions can be combined to fine-tune the target selection.

Select Individually

The tab shows a wrapping list of pills — one per chosen customer/item. To remove an entry, click the small × on its pill.

To add many at once:

  1. Click Add Items (on the Item tab) or Add Customers (on the Customer tab).
  2. The picker opens with two tabs:
    • Search — multi-select dropdown with checkboxes against customer/item search. Already-selected entries are filtered out so you can't pick the same one twice.
    • Paste List — paste SKUs (or names) one per line, then click Resolve. The system reports how many resolved, how many were not found, and how many duplicate. You can fix the unresolved ones and Resolve again.
  3. Click Add N to append the picks. The picker stays open until you press Cancel or the close icon — clicks outside the dialog will not cancel your selection.

3. Price Adjustment

Defines how the unit price is adjusted. The base price used for adjustment is the item's Sales Price. There are four available methods.

Percentage

Apply a percentage-based increase or decrease.

  • Direction: Increase / Decrease
  • Value: Percentage (e.g., 10%)

Fixed Amount

Apply a fixed monetary adjustment.

  • Direction: Increase / Decrease
  • Value: Fixed amount (e.g., 20)

Adjust Price Based on Item Options

Apply an additional charge or discount based on item options or attributes.

  • Define multiple adjust price lines (tiers), each with its own conditions and adjustment value.
  • Each line can include multiple conditions combined using AND/OR logic.
  • If all conditions within a line are met, the corresponding extra price will be applied.
  • All matching lines are applied cumulatively.

For each condition:

  • Type: Item Option / Item Attribute
  • Field Name: The field to evaluate (e.g., color, material)
  • Condition: Operator and Value (e.g., Equals "Blue")
  • Extra Price: Amount to adjust (can be positive or negative); supports formulas referencing item variables, e.g. {width}*0.1+50

Use this method to layer multiple additional charges or discounts based on complex item configurations. For grid-shaped pricing (e.g. price by width × height), see the Matrix view below.

Set Price Based on Item Options

Override the item's unit price entirely when specific conditions are met.

  • Value: The final unit price to be set (e.g., 222)
  • Conditions: Define one or more item option-based rules.
    • If the conditions match, the unit price is set to the defined value instead of being adjusted.
    • Conditions can be combined using AND/OR logic.
    • Supported fields: Item Option / Item Attribute.

This method overrides the original sales price. It does not stack with other price adjustments for that line. Use with caution when combining with other rules.

List vs Matrix View (Conditional methods)

When the method is Adjust Price Based on Item Options, a small List / Matrix toggle appears next to the Method dropdown.

  • List view (default): one tier per row. Best for a handful of one-off tiers.
  • Matrix view: a grid editor — see the dedicated section below.

Switching from List → Matrix on a rule that already has hand-built tiers will warn you before clearing them. Original tiers stay intact in List view until you explicitly save in Matrix mode.

Matrix Editor

The Matrix editor lets you author tabular pricing across 1–3 dimensions — for example, door price by width × height × material — without manually creating every tier.

Defining Axes

For each axis (1–3 max):

  • Source: Item Attribute or Item Option.
  • Label: pick from the available attribute/option keys for the rule's items (the dropdown is populated from the same data the List view uses).
  • Kind:
    • Range (numeric) — supply sorted breakpoints. The system creates ranges using (prev, curr] semantics. Values below the first breakpoint or above the last fall through to the rule's base behavior — they are not adjusted by the matrix. To cover those cases, extend the breakpoint list.
    • Discrete values — supply explicit values (e.g. aluminum, steel). When used as the third axis, values render as tabs.

Filling the Grid

  • Each cell is a price string. Empty cells emit no tier (the rule simply doesn't match for that combination).
  • Cell values can be plain numbers (100) or formulas ({width}*0.1+50).
  • Use Fill empty cells… to set every empty cell to the same value or formula.
  • You can paste a TSV block from a spreadsheet (Excel, Google Sheets) directly into the grid.

Saving and Reopening

When you save, the matrix is converted to flat tier rows under the hood, plus a small UI hint so the rule reopens in Matrix view next time. The runtime evaluates the flat tiers — there is no behavior difference between a List-authored rule and a Matrix-authored one with equivalent tiers.

The Matrix editor enforces an upper bound (10,000 cells) and warns at 1,000 cells. If you need a bigger grid, split the rule.

Rule Application Logic

  • Multiple Rules Apply: All rules that match the target and are within their date range will be applied.
  • Priority Matters: Rules are cumulative, so the order in which they apply affects the final price — especially with percentage-based rules.

You can configure the application order by clicking Priority Setting at the top of the list and using drag-and-drop to reorder the rules.

Bulk Actions on the List

Select rules with the row checkboxes, then open the Group Actions menu in the table header. The same actions are also available per-row in the row's three-dot menu.

ActionWhat it does
ActivateSets Enabled = true on every selected rule. Hidden when all selected rules are active.
DeactivateSets Enabled = false on every selected rule. Hidden when all selected rules are inactive.
Shift DatesAdds or subtracts N days to start_date and/or end_date. Rules with no dates are skipped and reported separately.
DuplicateOpens the Duplicate wizard with the selection as a template (see below).
DeleteSoft-deletes the selected rules. An admin can restore them.

Duplicate Wizard

The Duplicate wizard is the quickest way to create a rule similar to an existing one — or to create many rules from a single template.

Step 1 — Copy mode

  • Single copy with manual edits: make 1+ copies of the source rule with the overrides from Step 2 applied uniformly.
  • Fan out across a list: generate one copy per target. Choose the target source:
    • Customers — one rule per customer.
    • Customer types — one rule per customer type.
    • Item categories — one rule per item category.

Step 2 — Field overrides

  • Name prefix — defaults to Copy of . When fanning out, each rule's name is suffixed with the target name (e.g. Copy of Source Rule — Beta Mart).
  • Shift start_date / end_date by N days — apply a uniform shift.
  • Override Price Adjustment Value — replace the source's value (e.g. 1012 to bump a percent).
  • Initial Active — by default, new rules are created inactive so you can review them before flipping them on.

Step 3 — Preview & confirm

A table shows every rule that will be created (rule name, fanout target). Click Create N to commit. Successes and failures are reported per rule.

Using Price Rules in Sales Transactions

When creating an Estimate or Sales Order, ianaiERP will:

  • Determine which price rules apply to each line item.
  • Start with the item's base Sales Price.
  • Apply matching rules in priority order.
  • Display a breakdown of applied adjustments when hovering over the unit price.

This provides full transparency into how the final price was calculated.

Best Practices

  1. Use separate rules for different adjustment methods (e.g., one for discount, one for option-based pricing).
  2. Carefully manage rule priorities to ensure accurate pricing.
  3. Use condition-based targeting to handle promotional pricing, customer tiers, and product variations.
  4. For repetitive multi-dimensional pricing (e.g. price by size), prefer the Matrix view over hand-built tiers — it is far easier to audit and edit.
  5. Use the Duplicate wizard with fan-out to roll out per-customer or per-category variations of a master rule, then tweak the values.
  6. Disable rules instead of deleting; soft-delete is reversible by an admin, but leaving rules disabled keeps a cleaner audit trail.
  7. Regularly review rule effectiveness and overlaps.

For more advanced scenarios or examples, please contact your system administrator or support team.