Quoting & Ordering ยท Module 3.5 Module 3.5 UPDATED v3.9

PO Approval Workflows

Two complementary systems in one module: a checkout approval gate that holds orders above a threshold for manager sign-off, and an admin PO panel where buyers submit purchase orders for conversion into WooCommerce orders โ€” complete with net-terms invoicing, payment tracking, and reminder emails.

Two systems, one module. System 1 (Checkout Gate) intercepts orders at checkout and holds them for approval. System 2 (Admin PO Panel) is a complete purchase order workflow where buyers submit POs that your team reviews, converts to orders, and invoices. They can be used independently or together.

๐Ÿšฆ Tiered Approval Thresholds

Define as many tiers as needed: auto-approve under $500, manager approval $500โ€“$2K, admin sign-off above $2K. Each tier can have different approver roles.

๐Ÿ“‹ PO Number at Checkout

Require buyers to enter a PO number at checkout. Stored as HPOS-compatible order meta. Visible in admin, emails, and the PO panel. Custom format validation supported.

๐Ÿ—๏ธ HPOS Compatible

Approval status, approver ID, rejection reason โ€” all stored as WC order meta via HPOS-safe methods. Admin columns work on both classic and HPOS order screens.

๐Ÿ“ง Email Notifications

Approvers get instant email when an order needs sign-off. Buyers get notified on approval or rejection. Payment reminders can be sent manually from the PO panel.

๐Ÿ’ณ Net Terms Invoicing (PO Panel)

Convert approved POs into WooCommerce orders. Set payment due dates based on Net terms. Track paid/unpaid status. Mark as paid when payment is received โ€” company credit balance updates automatically.

๐Ÿ”— Rule-Based Auto Routing

Rules engine evaluates order total and buyer's user group to determine whether to auto-approve or route to a specific approver. Supports specific user or user-group approvers.

System 1

Checkout Approval Gate #

When a buyer places an order and their cart total hits an approval threshold, the order is intercepted at checkout and placed in "Pending Approval" status instead of going straight to processing. The designated approver receives an email notification and can approve or reject with a single click โ€” either from the email link or from My Account โ†’ Pending Approvals.

In plain terms: Think of it like a spending limit for your wholesale buyers. Under $500 โ€” they order and it processes normally. $500 to $2,000 โ€” their order is held and their manager gets an email. Above $2,000 โ€” only you (admin) can approve it. The buyer always sees a clear "Your order is awaiting approval" message.

How Approval Thresholds Work

Go to B2B Commerce Kit โ†’ PO Approval โ†’ Approval Rules. Each rule defines:

Example Threshold Setup

๐ŸŸข Tier 1: Under $500 โ€” Auto approve

Small orders go straight through. No interruption to the buyer's experience.

Action: Auto-approve
Buyer sees: Normal order confirmation. "Your order is being processed."

๐ŸŸก Tier 2: $500โ€“$2,000 โ€” Manager approval

Mid-range orders wait for the buyer's designated manager or company admin to sign off.

Action: Route to approver role
Buyer sees: "Your order is awaiting approval." Manager gets email with approve/reject links.

๐Ÿ”ด Tier 3: Over $2,000 โ€” Admin only

Large orders need you personally to review before they process.

Action: Route to specific user
Buyer sees: "Your order requires administrator approval." You get an email.

๐Ÿ”ต No matching rule โ€” falls back to global default

If an order doesn't match any rule, the global default action applies (auto-approve or require approval).

Settings โ†’ Default Action
Configure in: Settings โ†’ PO Approval Settings โ†’ Default Action.

Order Meta Stored (HPOS-Compatible)

When an order enters the approval queue, these values are stored using $order->update_meta_data() โ€” safe on both HPOS and classic order storage:

Meta KeyWhat It Stores
_woob2b_approval_statuspending / approved / rejected / cancelled
_woob2b_approver_idWordPress user ID of the designated approver
_woob2b_approval_company_idCompany ID (for company admin access checks)
_woob2b_approval_rule_idWhich rule triggered this approval requirement
_woob2b_rejection_reasonReason text when an approver rejects (stored on reject)
System 2

Admin PO Panel #

A complete purchase order workflow separate from the normal checkout flow. Buyers browse your catalogue and submit a formal Purchase Order. Your team reviews it, can modify it, then converts it into a real WooCommerce order. The order is invoiced and tracked until payment is received.

In plain terms: Instead of going to checkout, the buyer submits a "request to buy" โ€” a PO. Your sales team reviews it, maybe adjusts quantities, then converts it into an actual order. From that point, it's invoiced to the company and you wait for payment. This is how traditional B2B wholesale purchasing works.

PO Lifecycle

PO Status Flow

Pending โ†’ Approved โ†’ Converted โ†’ Paid  or  Rejected

Key Settings

SettingWhat it doesDefault
Require PO NumberAdd a mandatory PO number field to checkout for eligible roles. Stored as HPOS-compatible order meta.Off
Approval Expiry DaysDays before unapproved pending orders auto-cancel. Approvers receive reminder emails before this.7
Default ActionWhat happens to orders with no matching rule โ€” auto-approve or require approval.Auto-approve
Notify SubmitterEmail the buyer when their order is approved, rejected, or marked paid.On
Default Payment TermsAuto-set payment due date on converted POs (number of days from conversion).30
Credit Check on ApproveCheck company credit availability before approving. Log a warning if credit would be exceeded.Off
Sub-Account PermissionAllow sub-accounts to submit POs through the buyer portal.No

Frequently Asked Questions

System 1 โ€” Checkout Gate: The buyer goes through normal checkout. If their order total triggers a rule, the order is intercepted and held for approval. The buyer has already added everything to their cart and gone through checkout โ€” you're just adding a sign-off step before it processes.

System 2 โ€” Admin PO Panel: The buyer doesn't go to checkout at all. They submit a formal Purchase Order document. You review, approve, then convert it into a WooCommerce order yourself. This is more formal and suits industries where all purchases require an official PO document.

Yes โ€” fully. Approval status, approver ID, company ID, rule ID, and rejection reason are all stored as WC_Order meta using update_meta_data(). The admin order column (showing pending/approved/rejected badges) is registered for both the classic shop_order posts screen and the HPOS wc-orders screen via separate hooks, so it works regardless of which order storage mode you use.

Yes. When a sub-account's order requires approval, the parent company admin can approve or reject it from My Account โ†’ Pending Approvals. They see all pending orders from users within their company. Site admins with manage_woocommerce capability can always approve any order.

Orders auto-cancel after the Approval Expiry Days setting (default: 7 days). Approvers receive email reminders before expiry. The buyer is notified when their order is cancelled. For System 2 POs, they remain in the panel and can be manually cancelled by the buyer from their portal.

Yes. The "Convert to Order" screen has optional fields for shipping cost, shipping method name, and coupon code. These are applied when the WooCommerce order is created. If a coupon fails (invalid or expired), a note is added to the order but conversion still completes.

Yes. The following action hooks are available: woob2b_order_pending_approval, woob2b_order_approved, woob2b_order_rejected (System 1), and woob2b_po_submitted, woob2b_po_approved, woob2b_po_paid (System 2). See the Hooks reference for full parameter lists and code examples.