Prevent Duplicate Customer PO on Sales Orders in Odoo

We’ve added a new feature to help prevent sales teams from accidentally duplicating a customer’s purchase order, a critical need for many of our clients who rely on customer-issued PO references to manage order approvals and payment processing.
This feature introduces automatic checks and interactive warnings when users attempt to reuse the same Customer Reference (PO number) for the same commercial partner.
How It Works
If a user enters a Customer Reference on a Sales Order, the system checks if that reference has already been used on a confirmed order for the same parent-level customer.
Depending on the customer’s configuration, the system will either:
- Show a warning, allowing the user to proceed
- Block order confirmation, unless bypassed through a pop-up
- Or do nothing, if the customer has not enabled duplicate checking
- Duplicate Detection
- A yellow warning banner appears if the entered reference already exists for another order.
- On confirm, the user sees a popup saying:
- “The Customer PO reference already exists, would you like to proceed anyway?”
- If confirmed, the system logs:
- “Acknowledged and Approved Order with Duplicate Customer Reference”
-
Some customers require a PO reference on all orders.
- If this is enabled, users will not be able to confirm an order without entering a Customer Reference.
- If a user attempts to confirm without one, a pop-up explains the issue and requires acknowledgement before continuing.
How it’s configured
- In the Sales app go to Configuration > Settings > Orders and Quotations > Customer PO Ref Warnings.
- There, you will see configuration options for “Missing customer PO Ref” and “Duplicate customer PO ref”
- These control both warning visibility and whether order confirmation is allowed or blocked when rules are not met.
- You can set these options to “Never warn” or “Always warn”.
- When you select the “Always Warn” option, a “Blocks Confirmation” appears, allowing you to choose whether you want the order confirmation to be blocked when the warning is triggered.
- Interactive popups (bypass wizards) Two bypass flows guide the user when rules are violated:
-
Missing Reference Warning
- Displays a message that the customer requires a PO reference
- Buttons: Cancel, Confirm Anyway (if bypass is allowed)
- Duplicate Reference Warning
- Shows the existing conflicting PO
- Buttons: Cancel, Confirm Anyway (if bypass is allowed)
- Shows the existing conflicting PO
Each wizard ensures users understand what they’re overriding — and who approved it.
Website behavior
To avoid disrupting customer purchases, duplicate reference checking is disabled on website orders. Orders placed online will still be processed even if the reference already exists.
Related posts

Pop-up warning when PO line created with $0 cost in Odoo
To help prevent one of the most common and costly mistakes, accidentally confirming purchase orders (POs) with $0 cost lines, Steersman has developed a new Odoo customization: the $0 PO Line Warning pop-up.

Warn (or Block) Users from Editing Contacts Used in Odoo Orders
We’ve added a new feature that protects your order history from accidental changes. Now, if a user tries to edit a contact that has been used on sales orders, deliveries, invoices, or payments, Odoo will alert them or block the edit entirely, depending on their permissions.

Automatically Print Product Allocation Labels on Receipts and Transfers in Odoo
When validating an internal transfer or vendor receipt, Odoo can now generate ZPL labels that show where each group of items is going next — including any sales orders they're destined for. Each label is printed based on the pickings the received items are allocated to (i.e., where they’ll be moved next). Labels are printed via PrintNode to a dedicated Zebra printer called the Inventory Allocation Label Printer.

Customer Credit Limits and Blocks in Odoo
Automatic credit holds on customers with overdue invoices past a grace period, blocks on new SO's going over credit limit, manual blocks on SO's or deliveries