Using in an Entry

All current Pricing Rules show up as checkboxes. Whatever you tick creates a relationship between the entry and the products, so you can list them in your templates using the plugin's custom variable.

Important

Products tied to a Pricing Rule won't show once the rule has expired, even if it was ticked and saved against the entry earlier. The relationship itself stays intact; the products are just hidden, not removed.Out-of-stock products are not hidden automatically. If you want those excluded too, pass hasStock: true when you call getSaleIds() in your template, see Templates.

Removed Rules

If a Pricing Rule you'd ticked earlier is later deleted in Commerce, the field flags it. You'll see a note telling you the stale selection will drop off the next time the entry is saved, so nothing lingers quietly in the background.

Use Cases

Special Offers Page

Say a client wants a Special Offers page that only shows curated products matching certain pricing rules, rather than everything. See example

Offer Categories

Say a client wants Special Offer Categories: July Offers, Autumn Offers, and so on.