I wanted my Odoo engineering blog to feel like a modern technical publication, complete with persistent thumbs up and down voting, multi-part series navigation, reading-time progress bars, one-click code copying, and an audio reader. Checking third-party app marketplaces immediately surfaced the classic ERP trap: almost none of the commercial blog addons are ported cleanly to Odoo 20.0, and the few legacy snippets that exist either override native templates destructively or break the visual Website Builder. Instead of installing fragile third-party bloat, I built a compact, upgrade-safe native Odoo addon with a full pre-install PostgreSQL rollback snapshot.
Good ERP customization follows one strict rule: extend what the platform lacks, and never touch what the platform already does well. Before writing a single line of XML, I inspected Odoo's live website_blog templates inside the container. Odoo already ships a crisp native Desktop and Mobile Table of Contents (opt_blog_post_toc_display). Rebuilding a duplicate TOC in custom JavaScript would have created double sidebars and future upgrade conflicts. By leaving the native TOC completely untouched and focusing purely on engagement, navigation, and structured SEO, the entire addon stayed clean, modular, and uninstallable in one click.
Rollback Insurance First: Before installing any custom addon onto a live Odoo database, I always run a compressed pg_dump -Fc checkpoint snapshot first. Even when a module is 100% additive and uninstallable via the Odoo Apps menu, having a verified 15-second restore point removes all deployment anxiety.
Three Odoo 20 Breaking Changes You Must Respect
Developers porting Odoo 17 or 18 patterns blindly into Odoo run straight into subtle framework changes. Building natively for 20.0 meant adopting three modern conventions from line one:
models.Constraint
Replaced legacy _sql_constraints lists with Odoo 20's modern models.Constraint("UNIQUE(post_id, voter_hash)", ...) declarations to enforce clean per-reader vote deduplication at the PostgreSQL layer.
ir.access.csv & Safe QWeb
Declared model ACLs via modern security/ir.access.csv conventions and wrapped every injected widget container in o_not_editable so Odoo's Website Builder never saves transient UI buttons back into article HTML.
Markup-Safe JSON-LD
Odoo's QWeb escapes raw strings inside t-out by default. Returning markupsafe.Markup(raw_json.replace("</", "<\\/")) emits valid, unescaped Article and BreadcrumbList schema safely.
What the Native Blog Studio Adds (Without Touching Core TOC)
Every feature was engineered to work cleanly in dark mode, degrade gracefully without heavy external libraries, and integrate directly with Odoo's existing CRM and Email Marketing models:
| Feature | Native Odoo Implementation | Why It Beats App Store Plugins |
|---|---|---|
| Thumbs Up / Down & Reactions | Custom blog.post.vote model with hashed HttpOnly voter token and stored computed counters |
Prevents ballot stuffing while surviving page reloads and keeping database queries fast. |
| Multi-Part Series Navigator | Custom blog.series model with series_sequence rendering Part X of Y and Previous/Next links |
Replaces hand-edited HTML navigation boxes across multi-part engineering series. |
| TL;DR Brief & Reading Metrics | Stored word_count and reading_time_min (225 WPM) plus optional executive_tldr card |
Gives busy engineering leaders a 15-second architecture brief right above the fold. |
| Zero-Cost Audio Reader | Browser Web Speech API bar with 1.0x to 1.75x speed toggle reading clean article prose | Zero monthly TTS API bills and instant playback on desktop or mobile browsers. |
| Editor-Safe Copy-Code | Runtime DOM injection on <pre> blocks skipped whenever body.editor_enable is active |
One-click code copying for readers without polluting saved QWeb content during edits. |
| Email-Gated Playbooks & Ask AI | Inline unlock endpoint creating an Odoo crm.lead + mailing.contact, plus deep link to Ask My Architecture |
Turns technical tutorials directly into grounded RAG Q&A sessions and qualified CRM leads. |
Catching the QWeb JSON-LD Escaping Bug Before Ship
Never assume a template renders clean structured data until you curl the live HTML and parse the script tag with json.loads(). On my very first post-install verification check, curling a live article revealed that QWeb had HTML-escaped every double quote inside <script type="application/ld+json"> into " because the helper returned a plain Python str. Search engines silently discard HTML-escaped JSON-LD blocks.
Fixing it took two lines using MarkupSafe while still defending against script-tag breakout sequences:
from markupsafe import Markup
raw_json = json.dumps([article, breadcrumbs], ensure_ascii=False).replace("</", "<\\/")
return Markup(raw_json)
Re-running my live verification script confirmed that the rendered application/ld+json block parsed cleanly via json.loads(), returned both Article and BreadcrumbList objects, and passed every controller test: voting up, toggling down, deduplicating repeat clicks, and rendering clean print/PDF stylesheets.
When you own your ERP codebase, a 250-line native module you actually understand will always outlast a black-box marketplace plugin that breaks on the next major version jump.
Why Native Addons Compound Over Time
Now that blog.series and executive_tldr live directly inside Odoo's ORM, every multi-part campaign I stage, from cybersecurity forensics teardowns to sovereign infrastructure operations, links itself together cleanly with structured metadata, live reader feedback, and automatic reading metrics. You can browse live builds across my open-source showcase or reach out if your organization wants custom Odoo modules engineered cleanly without marketplace lock-in.