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. Technical
  3. Base v 19.0
  4. Sales Conditions FAQ

Base

by Syntax & Sabotage https://praetorx.net , Lars Weiler https://praetorx.net
Odoo
v 19.0 Third Party 13
Download for v 19.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 Discuss (mail)
Lines of code 691
Technical Name praetorx_base
LicenseLGPL-3
Websitehttps://praetorx.net
You bought this module and need support? Click here!
Availability
Odoo Online
Odoo.sh
On Premise
Odoo Apps Dependencies Discuss (mail)
Lines of code 691
Technical Name praetorx_base
LicenseLGPL-3
Websitehttps://praetorx.net

PraetorX Base

Queue Jobs, Batch Processing & Validation Framework for Odoo 19

v19.0.1.1.0 Community Enterprise Odoo.sh Developer Library Free

Reusable technical patterns for building robust Odoo modules. Background job queue with cron processing, a validation mixin with HTML summaries, a state-machine batch processing mixin, and an OWL split-view component — all ready to inherit in your own models.

praetorx.net | Syntax & Sabotage

  • Features
  • Setup
  • FAQ
  • Releases

Core Patterns

Queue Job System

Background job processing via cron. Create jobs with model name, method, and record IDs. Processed in FIFO order, up to 100 per minute. Retry failed jobs or cancel pending ones.

Validation Mixin

Structured validation returning errors and warnings with HTML-formatted summaries. Inherit praetorx.validation.mixin and override validate_all() in your model.

Batch Processing Mixin

State machine for parent-child workflows: Draft → Validated → Posted (and Cancel/Reset). Inherit praetorx.batch.mixin — includes validation hooks, deletion guards, and button visibility.

Split View Component

OWL component for master-detail UI patterns. Configurable panel widths, item selection callback, scoped template slots for master and detail panels.

Shared Security Groups

Three-tier hierarchy: User → Manager → Administrator. Used by all PraetorX modules for consistent access control. Admin assigned to base.user_admin by default.

PDF Display Mode

Configurable report behavior: download PDF to disk or open in a new browser tab. Set once in Settings, applies to all PraetorX report actions.

Technical Reference

ComponentDetails
praetorx.queue.jobConcrete model — name, model_name, method_name, record_ids (JSON), state (pending/processing/done/failed), timestamps, error message. Retry and cancel actions.
praetorx.validation.mixinAbstract model — validate_all() returns list of dicts with level/message/field/code. HTML summary with Bootstrap alert classes. Batch validation support.
praetorx.batch.mixinAbstract model — state field (draft/validated/posted/cancelled), 4 workflow actions, 7 validation and processing hooks, computed button visibility, deletion guards.
SplitViewOWL component — master-detail layout with configurable widths (default 35%/65%), item selection, scoped slots for master and detail panels.
res.config.settingsExtended — praetorx_report_display_mode selection field (download / inline). Stored as system parameter.
CronProcesses pending queue jobs every 1 minute in FIFO order, batch size 100.

Queue Job Lifecycle

Pending → Processing → Done
Pending → Processing → Failed → (Retry) → Pending
Pending / Processing → (Cancel) → Failed

FIFO processing

Oldest pending jobs processed first. Cron runs every minute.

Retry failed jobs

One-click retry resets failed jobs to pending. Error message preserved for debugging.

Full job views

List view with state badges, form view with JSON editor for record IDs, search with filters and group-by.

Batch Processing Workflow

Draft → Validated → Posted (terminal)
Draft / Validated → Cancelled → Draft (reset)

Validation hooks

Override _validate_before_validate(), _validate_before_post(), _validate_before_cancel(), _validate_before_reset() to add custom checks.

Processing hooks

Override _post_processing(), _cancel_processing(), _reset_processing() for custom logic after state transitions.

Use Cases

Large Dataset Processing

Offload heavy operations (mass invoice posting, document classification, data import) to the queue. Users don’t wait — the cron handles it.

Multi-Step Validation

Run multiple validation checks and display the results as a single HTML summary. Errors block, warnings inform.

Document Workflows

Draft → Validated → Posted lifecycle for invoices, purchase orders, quality checks. Deletion guards prevent accidental loss of posted records.

Master-Detail UIs

Use the SplitView OWL component for email-client-style layouts. Left panel shows a list, right panel shows details. Scoped slots for full template control.

Setup Guide

Prerequisites
  • Odoo 19.0 (Community or Enterprise)
  • Python 3.10+
  • Required modules: base, mail, web
  • No external Python dependencies
  • No external services or API keys

No Enterprise dependency. Works on Community, Enterprise, and Odoo.sh.

Installation

Install from the Odoo Apps menu. Search for “PraetorX Base” or “Queue Job”.

PraetorX Base is typically installed automatically as a dependency of other PraetorX modules (Roles, Shell, Cockpit, etc.).

Queue Jobs

Queue jobs are processed automatically by a cron that runs every minute.

View and manage jobs at PraetorX → Technical → Queue Jobs. By default the list shows pending jobs.

Failed jobs show an error message. Click Retry to re-queue, or Cancel to dismiss.

PDF Display Mode
  1. Navigate to Settings → PraetorX
  2. Under PDF Reports, choose Download PDF or Open in Browser Tab
  3. Click Save
Security Groups

PraetorX / User: Access PraetorX features (subject to module-specific rules). Read-only access to queue jobs.

PraetorX / Manager: Configure PraetorX settings. Implies User.

PraetorX / Administrator: Full control over all PraetorX modules. Implies Manager. Assigned to admin by default.

Using the Mixins in Your Module

Add praetorx_base to your module’s depends list, then inherit:

class MyModel(models.Model):
    _name = "my.model"
    _inherit = ["praetorx.batch.mixin", "praetorx.validation.mixin"]

Override validate_all() for validation rules and use the batch mixin’s workflow actions (action_validate, action_post, etc.) in your form view buttons.

FAQ

Does this require Odoo Enterprise?
No. Depends on base, mail, and web only — all included in Odoo Community. Works on Community, Enterprise, and Odoo.sh.
How is this different from OCA queue_job?
PraetorX Base’s queue is simpler and self-contained — it uses a standard Odoo cron (1-minute interval), no external worker processes, no Redis, no additional infrastructure. It’s designed for moderate workloads. OCA queue_job is better for high-throughput scenarios that need dedicated workers.
Can I use the mixins without the queue job system?
Yes. The validation mixin, batch processing mixin, and SplitView component are fully independent. Inherit only what you need. The queue job model and cron exist but don’t interfere if unused.
What happens if a queue job fails?
The job state is set to “failed” and the error message is stored. Failed jobs remain visible in the list view (highlighted in red). Click Retry to re-queue the job, or Cancel to dismiss it.
Can I delete posted records when using the batch mixin?
No. The batch mixin blocks deletion of validated and posted records. Only draft and cancelled records can be deleted. This prevents accidental loss of confirmed data.
Does the cron job run even if there are no pending jobs?
Yes, the cron triggers every minute, but if there are no pending jobs it returns immediately with no processing. The overhead is negligible — a single database query.
Is there a performance impact from the cron?
No. The cron processes up to 100 jobs per execution in a single batch. Each empty check is one lightweight query. The 1-minute interval is standard Odoo cron behavior.

Release History

v19.0.1.1.0 — April 2026

Current Release

  • Added shared module categories (PRAETORX / Core) for privilege-based access
  • Shared security groups moved here from praetorx_security
  • Shared PraetorX root menu and Configuration submenu

v19.0.1.0.0 — Initial Release

Initial Release

  • Queue Job System — background processing via cron with state management
  • Validation Mixin — structured validation with HTML summaries
  • Batch Processing Mixin — state machine for document workflows
  • SplitView OWL component — master-detail UI pattern
  • PDF Display Mode setting (download vs. inline)
  • German translations (de.po)
  • 73 automated tests

Modules That Depend on PraetorX Base

PraetorX Roles

Role-based user group management with date-gated assignments and additive sync.

39 EUR
PraetorX Shell

Branded backend theme with sidebar, home tiles, activity dashboard, and role-based color theming.

Free
SharePoint Sync

Enterprise-grade bidirectional sync between Odoo Documents and SharePoint Online.

349 EUR
Nextcloud Sync

Bidirectional sync between Odoo Documents and Nextcloud/WebDAV.

149 EUR

Made with ♥ by Syntax & Sabotage

© 2026 Syntax & Sabotage, Lars Weiler. All rights reserved. LGPL-3.

Impressum · support@syntaxandsabotage.io

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.
  • Ratings
  • Discuss
Quiet, opinionated, and very effective.
by
COO
on 3/22/26, 2:00 PM

PraetorX Base is one of those modules you don’t notice — until you realize everything built on top of it is cleaner, more consistent, and way less painful to maintain.


There are no comments yet!
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