CI / Static checks (pull_request) Failing after 31s
Compatibility / WP latest / WC latest / PHP 7.4 (pull_request) Skipped
Compatibility / WP latest / WC beta / PHP 8.3 (pull_request) Skipped
Compatibility / WP latest / WC latest / PHP 8.3 (pull_request) Skipped
Compatibility / WP nightly / WC latest / PHP 8.3 (pull_request) Skipped
Compatibility / WP latest / WC latest / PHP 8.4 (pull_request) Skipped
Compatibility / Keep the compatibility headers honest (pull_request) Skipped
CI / WordPress latest + WooCommerce latest on PHP 8.3 (pull_request) Successful in 1m20s
Co-Authored-By: Claude Code <noreply@anthropic.com>
74 lines
3.4 KiB
Markdown
74 lines
3.4 KiB
Markdown
# Nolimit Discounts
|
|
|
|
Version 1.7.0 · a WooCommerce plugin · slug `woocommerce-email-discount-manager`
|
|
|
|
Gives a customer a discount, and decides which shipping methods they may
|
|
choose, based on the email address they check out with.
|
|
|
|
## What it does
|
|
|
|
A shop puts in email patterns and says what each one is worth. At checkout the
|
|
plugin looks at the customer's email, finds the most specific pattern that
|
|
matches, and applies it.
|
|
|
|
Three kinds of assignment, one per email pattern:
|
|
|
|
| type | effect |
|
|
| --- | --- |
|
|
| **Group** | the customer gets a discount group's percent, on the product categories attached to that group |
|
|
| **Coupon** | an existing WooCommerce coupon is applied automatically |
|
|
| **Custom** | a flat percent off the whole cart |
|
|
|
|
Patterns can be a full address (`john@example.com`), a domain
|
|
(`@company.com` — everyone there), or a fragment (`john` — any address
|
|
containing it). When more than one matches, the most specific wins: exact
|
|
address, then domain, then fragment.
|
|
|
|
## Shipping
|
|
|
|
A discount group can be given shipping rules, which is the half worth reading
|
|
twice because it decides what a stranger sees.
|
|
|
|
A method a group is set to **only** is *reserved* for that group. Customers
|
|
who match no group do not see it. Before 1.6.0 a method set up for approved
|
|
company addresses stayed on the checkout for everybody, so free delivery meant
|
|
for one customer could be chosen by anyone who found it — the bug that release
|
|
fixed. **Show** is the weaker rule and reserves nothing: it offers the method
|
|
to the group and leaves everyone else alone. 1.6.0 made show do both, which
|
|
took ordinary methods away from strangers whenever they were listed beside a
|
|
free one; the next release split them and turned every old show rule into only.
|
|
|
|
The plugin never leaves a customer with no shipping method at all. If applying
|
|
the rules would empty the list, every method comes back.
|
|
|
|
## What it is not
|
|
|
|
Facts that take a while to establish by reading the source, so they are written
|
|
down here:
|
|
|
|
- **Not a coupon engine.** The Coupon assignment type applies a coupon
|
|
WooCommerce already has. This plugin does not create, price or validate one.
|
|
- **No public REST surface.** There is a REST API, and every route requires
|
|
`manage_woocommerce`. Nothing is readable by an anonymous visitor.
|
|
- **No telemetry.** Nothing is sent anywhere. The only outbound request is the
|
|
update check against the release feed, and it asks for a version number.
|
|
- **No block editor or shortcode.** The customer-facing side is the cart and
|
|
checkout calculation and nothing else.
|
|
- **Data survives uninstall.** There is no `uninstall.php` and no uninstall
|
|
hook, so deleting the plugin leaves its five tables and its options in the
|
|
database. That is deliberate — deleting a plugin by accident should not
|
|
destroy a shop's discount configuration — but it means a clean removal is a
|
|
manual job. See ARCHITECTURE.md.
|
|
|
|
## Where the rest is
|
|
|
|
| document | what is in it |
|
|
| --- | --- |
|
|
| [SETUP.md](SETUP.md) | installing it, and how to tell it is actually working |
|
|
| [ARCHITECTURE.md](ARCHITECTURE.md) | files, boot order, where data lives, what activation does |
|
|
| [CONTRACT.md](CONTRACT.md) | every hook this plugin offers and every one it answers |
|
|
| [RELEASE.md](RELEASE.md) | how a release is cut, and what is checked before it is called done |
|
|
|
|
Requires WordPress 5.8+, WooCommerce 6.0+, PHP 7.4+. Tested against WordPress
|
|
7.1.2 and WooCommerce 11.1.2 on PHP 7.4, 8.3 and 8.4.
|