Skip to Content
Odoo Menu
  • Sign in
  • Try it free
  • Apps
    Finance
    • Accounting
    • Invoicing
    • Expenses
    • Spreadsheet (BI)
    • Documents
    • Sign
    Sales
    • CRM
    • Sales
    • POS Shop
    • POS Restaurant
    • Subscriptions
    • Rental
    Websites
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Supply Chain
    • Inventory
    • Manufacturing
    • PLM
    • Purchase
    • Maintenance
    • Quality
    Human Resources
    • Employees
    • Recruitment
    • Time Off
    • Appraisals
    • Referrals
    • Fleet
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Events
    • Marketing Automation
    • Surveys
    Services
    • Project
    • Timesheets
    • Field Service
    • Helpdesk
    • Planning
    • Appointments
    Productivity
    • Discuss
    • Approvals
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Third party apps Odoo Studio Odoo Cloud Platform
  • Industries
    Retail
    • Book Store
    • Clothing Store
    • Furniture Store
    • Grocery Store
    • Hardware Store
    • Toy Store
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Beverage Distributor
    • Hotel
    Real Estate
    • Real Estate Agency
    • Architecture Firm
    • Construction
    • Property Management
    • Gardening
    • Property Owner Association
    Consulting
    • Accounting Firm
    • Odoo Partner
    • Marketing Agency
    • Law firm
    • Talent Acquisition
    • Audit & Certification
    Manufacturing
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • Corporate Gifts
    Health & Fitness
    • Sports Club
    • Eyewear Store
    • Fitness Center
    • Wellness Practitioners
    • Pharmacy
    • Hair Salon
    Trades
    • Handyman
    • IT Hardware & Support
    • Solar Energy Systems
    • Shoe Maker
    • Cleaning Services
    • HVAC Services
    Others
    • Nonprofit Organization
    • Environmental Agency
    • Billboard Rental
    • Photography
    • Bike Leasing
    • Software Reseller
    Browse all Industries
  • Community
    Learn
    • Tutorials
    • Documentation
    • Certifications
    • Training
    • Blog
    • Podcast
    Empower Education
    • Education Program
    • Scale Up! Business Game
    • Visit Odoo
    Get the Software
    • Download
    • Compare Editions
    • Releases
    Collaborate
    • Github
    • Forum
    • Events
    • Translations
    • Become a Partner
    • Services for Partners
    • Register your Accounting Firm
    Get Services
    • Find a Partner
    • Find an Accountant
      • Get a Tailored Demo
    • Implementation Services
    • Customer References
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +32 2 290 34 90
    • Get a Tailored Demo
  • Pricing
  • Help
  1. APPS
  2. Sales
  3. Sale Price Control v 18.0
  4. Sales Conditions FAQ

Sale Price Control

by Mohamed Yaseen Dahab
Odoo
v 18.0 Third Party 11
Download for v 18.0 Deploy on Odoo.sh
Apps purchases are linked to your Odoo account, please sign in or sign up first.
Availability
Odoo Online
Odoo.sh
On Premise
Odoo Apps Dependencies • Sales (sale_management)
• Discuss (mail)
• Invoicing (account)
Lines of code 196
Technical Name sale_price_control
LicenseLGPL-3
Versions 17.0 18.0 19.0
You bought this module and need support? Click here!
Availability
Odoo Online
Odoo.sh
On Premise
Odoo Apps Dependencies • Sales (sale_management)
• Discuss (mail)
• Invoicing (account)
Lines of code 196
Technical Name sale_price_control
LicenseLGPL-3
Versions 17.0 18.0 19.0

🔒 Sale Price Control

Prevent sale orders from being confirmed when prices are below cost — requires password authorization from authorized users before proceeding.

Odoo 18.0 Sales Below-Cost Protection Password Authorization LGPL-3

📋 Overview

Sale Price Control adds a critical business safeguard to your Odoo sales workflow. When a salesperson clicks "Confirm" on a sale order, the module checks every order line to see if the unit price is below the product's cost price.

If any below-cost lines are found, confirmation is blocked and a password authorization wizard appears. Only users belonging to the "Allow Below Cost Price" security group — who have configured their personal override password — can authorize the confirmation.

Screenshot Overview

⭐ Key Features

  • ✓ Below-Cost Detection: Automatically checks all order lines — compares unit price against product cost (standard_price)
  • ✓ Password Authorization Wizard: Blocks order confirmation and shows a wizard with detailed below-cost line info
  • ✓ Security Group: Dedicated "Allow Below Cost Price" group — only members can authorize overrides
  • ✓ Per-User Password: Each authorized user has their own password set in their Preferences
  • ✓ Approval Tracking: Each line gets a "Price Override Approved" flag — so approved lines are not rechecked
  • ✓ Auto-Reset Approval: Approval is automatically cleared if the price, product is changed
  • ✓ 100% Server-Side: No JavaScript or browser-side code — reliable, no cache issues
  • ✓ Clear Error Messages: Specific validation messages for missing password, wrong password, or missing group

⚡ How It Works

✅ Click Confirm
Salesperson confirms SO
→ 🔍 Check Prices
Compare vs cost price
→ 🔒 Wizard Opens
Shows lines + asks password
→ 🔓 Authorize
Password OK → order confirmed

Validation Checks (in order)

Check Error If Failed
1. Password entered? "Please enter a password."
2. User in "Allow Below Cost Price" group? "You do not belong to the Allow Below Cost Price group."
3. User has a password configured? "No price override password is configured for your user."
4. Password matches? "Incorrect password."
â„šī¸
No below-cost lines? If all prices are at or above cost, the order confirms normally — no wizard, no interruption, just the standard Odoo flow.

đŸ“Ĩ Installation

Requirements

Requirement Details
Odoo Version 18.0 (Community & Enterprise)
Depends On sale_management, product,
Python Libraries None
License LGPL-3

Steps

1 Upload the module
Copy sale_price_control into your addons directory.
2 Update app list
Go to Apps → Update Apps List
3 Install
Search for "Sale Price Control" and click Install.

âš™ī¸ Configuration

Two things need to be set up: group membership and password.

Step 1 — Assign the Security Group

1 Go to Settings → Users & Companies → Users
2 Select the user (e.g. Sales Manager)
3 Under the Sale Price Control section, enable "Allow Below Cost Price"

Step 2 — Set the Override Password

1 On the same user form, go to the Preferences tab
2 Find the "Sale Price Override" section (only visible for group members)
3 Enter and save the Price Override Password (displayed as dots for security)
💡
Self-service: Users can also set their own password from their own Preferences page (top-right menu → My Profile → Preferences).

🛒 Usage

Scenario: Confirming an Order with Below-Cost Prices

1 Create a Sale Order and add products. Set a price below cost on one or more lines.
2 Click "Confirm". Instead of confirming, a wizard popup appears.
3 The wizard shows all below-cost lines with product name, unit price, and cost price.
4 Enter your price override password.
5 Click "🔓 Authorize & Confirm Order". If the password is correct, the lines are marked as approved and the order is confirmed.

What the Wizard Shows

⚠ Warning: The following order lines have prices below cost.
Widget X: Unit Price 8.00 — Cost Price 10.00
Gadget Y [Box]: Unit Price 45.00 — Cost Price 50.00

Approval Auto-Reset

If a line has been approved but then one of the following is changed, the approval is automatically cleared and the check will trigger again on the next confirmation:

  • â†ē Unit Price changed (via UI or direct write)
  • â†ē Product changed

❓ Frequently Asked Questions

Can a regular salesperson bypass the check?

No. The wizard requires both group membership and a correct password. Without both, the order cannot be confirmed with below-cost prices. The salesperson must either fix the prices or ask an authorized user to enter the password.

What if a product has zero cost price?

Products with cost = 0 are skipped. The check only triggers when standard_price > 0 and price_unit < standard_price.

Is the override password stored securely?

The password is stored as plain text in the database (like many Odoo configuration passwords). It is displayed as dots in the UI via the password="True" widget. This is an authorization PIN, not a login credential.

Does this require any JavaScript?

No. The module is 100% server-side Python + XML. No JS assets, no browser cache issues, no frontend dependencies.

🤝 Support

For questions, bug reports, or feature requests:

WhatsApp +20 100 780 2335
Email mohamed.yaseen.dahab@gmail.com
💡
Upgrade command:
./odoo-bin -u sale_price_control -d your_database

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author, please use the developer contact information. They can usually be found in the description.
Please choose a rating from 1 to 5 for this module.
Community
  • Tutorials
  • Documentation
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Translations
Services
  • Odoo.sh Hosting
  • Support
  • Upgrade
  • Custom Developments
  • Education
  • Find an Accountant
  • Find a Partner
  • Become a Partner
About us
  • Our company
  • Brand Assets
  • Contact us
  • Jobs
  • Events
  • Podcast
  • Blog
  • Customers
  • Legal â€ĸ Privacy
  • Security

Odoo is a suite of open source business apps that cover all your company needs: CRM, eCommerce, accounting, inventory, point of sale, project management, etc.

Odoo's unique value proposition is to be at the same time very easy to use and fully integrated.

Website made with