Commission Rules
Commission Rules is where managers define how each staff member earns commission — a flat percentage, a fixed amount per sale or per item, which base the percentage applies to, and which sale-amount range or priority the rule takes effect at.
Overview
Every rule is tied to exactly one staff member; the same person can have multiple rules with different priorities and sale-amount ranges (e.g. a higher rate for big-ticket sales).
When multiple rules could match the same sale, Priority (lower number = higher priority) decides which one is actually applied.
Rules are never hard-deleted from here — the Delete action deactivates a rule (sets it inactive) rather than removing history, since past commissions were already calculated against it.
Before You Start
- Requires the Commissions feature on the Advanced plan tier or above, and manager-level access.
- The staff member you are configuring a rule for must already exist as a user in Settings → Staff/Users.
Step-by-Step Guide
1 Create a new commission rule
- Click Add Rule.
- Select the Staff Member this rule applies to (required) — the dropdown shows each user's name and role.
- Enter a Rule Name (required), e.g. "Default Sales Commission" or "Bulk Order Bonus".
- Choose the Commission Type: Percentage, Fixed per Sale, or Fixed per Item.
- If Percentage is selected, enter the Percentage (0–100, required) and choose what it applies to under Apply On — Total Amount, Subtotal (before tax), or Profit Margin.
- If Fixed per Sale or Fixed per Item is selected, enter the Fixed Amount instead.
- Optionally set a Minimum Sale Amount and/or Maximum Sale Amount so the rule only triggers within that sale-value range.
- Set the Priority (lower number wins when more than one rule could apply to the same sale) — defaults to 10.
- Toggle Exclude discounted sales if heavily discounted sales should not earn this commission.
- Leave Active checked (default) so the rule takes effect immediately, add any Notes, then click Create Rule.
2 Edit an existing rule
- Click the pencil (edit) icon on any rule row/card.
- The same form opens pre-filled with the rule's current values, including the correct fields shown/hidden for its Commission Type.
- Adjust any field and click Update Rule to save.
3 Deactivate (delete) a rule
- Click the trash icon on the rule.
- Confirm the prompt ("Are you sure you want to deactivate the commission rule…?").
- The rule is deactivated — its Status badge changes to Inactive rather than the row disappearing.
4 Sort and search rules
- The list sorts by Priority ascending by default, so the highest-priority rules appear first.
- Use the search box to find rules by staff name, role, or rule name.
- Switch between table and card view, or export the current rule list, using the data grid toolbar.
Every Field & Button, Explained
| Field / Button | What it does |
|---|---|
Add Rule | Opens a blank rule-creation modal. |
Staff Member | Required — the user this commission rule applies to. |
Rule Name | Required free-text label to identify the rule, shown in the list. |
Commission Type | Percentage, Fixed per Sale, or Fixed per Item — determines which amount fields are shown. |
Percentage | Shown only for Percentage type; 0–100, required, accepts decimals. |
Apply On | Shown only for Percentage type: Total Amount, Subtotal (before tax), or Profit Margin — the base the percentage is calculated against. |
Fixed Amount | Shown only for Fixed per Sale / Fixed per Item types; a flat currency amount, required. |
Minimum Sale Amount | Optional floor — the rule only applies to sales at or above this amount. |
Maximum Sale Amount | Optional ceiling — leave blank ("No limit") for no upper bound. |
Priority | Numeric tie-breaker when multiple rules could apply to the same sale; lower number = higher priority. Defaults to 10. |
Exclude discounted sales | Checkbox — when on, sales with a discount applied do not earn this commission. |
Active | Checkbox — inactive rules are kept for history but never applied to new sales. |
Notes | Free-text notes about the rule's intent or conditions. |
Commission (column) | Human-readable summary of the rule, e.g. "10% of total" or "₹50 per sale". |
Min Sale (column) | The configured minimum sale amount, or "—" if none set. |
Edit (pencil icon) | Opens the same form pre-filled for that rule. |
Delete (trash icon) | Deactivates the rule after a confirmation prompt (soft delete, not permanent removal). |
Tips & Best Practices
- Give every staff member at least one low-priority "default" rule (e.g. Priority 10, applies to Total Amount) as a safety net, then add higher-priority rules (lower Priority number) for special cases like bulk-order bonuses.
- Use Minimum/Maximum Sale Amount to create tiered incentives — e.g. a richer percentage rule for sales above a certain threshold, with a lower-priority number so it is checked first.
- Turn on Exclude discounted sales for high-margin categories where you do not want staff incentivised to over-discount just to close a sale.
Troubleshooting & FAQ
"Please select a staff member" / "Please enter a rule name" error on save.
A staff member has two rules and I am not sure which one applied to a sale.
I deleted a rule but it still shows in the list.
Commissions are not appearing on My Commissions for a staff member with a rule configured here.
🧑💻 Developer Notes
Source component(s):
frontend-app/packages/pos-react-lib/src/pages/CommissionRulesPage.jsx
Backend endpoints used:
GET /staff-commissions/rulesGET /settings/usersPOST /staff-commissions/rulesPUT /staff-commissions/rules/:idDELETE /staff-commissions/rules/:id
Related tables (db-core repositories):
CommissionRuleUser
Redux slices:
scope (selectCurrentScope / getScopeQueryParams)
Feature flag key: commissions (requires advanced plan tier or above)
The "Apply On" field is only rendered for Commission Type = PERCENTAGE, and the Fixed Amount field only for FIXED_PER_SALE / FIXED_PER_ITEM, driven by conditional JSX on formData.commissionType. DELETE calls the same /staff-commissions/rules/:id endpoint as a true removal at the API layer, but the frontend confirmation copy and UX describe it as "deactivate" — treat it as a soft delete from the user's perspective. Uses the shared DataGrid component with a custom rowActions renderer for the edit/delete icon pair.