How We Build Custom Odoo POS Modules for Textile Businesses
When Al-Ghazl Al-Arabi Trading Company needed a way to manage fabric cutting orders directly from their Point of Sale, we built a custom Odoo 18 module that handles the entire workflow. Here's the technical architecture behind ma_pos_cutting — now published on the Odoo Apps Store.
Architecture
The module extends PosOrder and PosOrderline with custom cutting fields (dimensions, fabric type, urgency level). We use OWL v2 components with a dedicated CuttingOrderScreen that renders inside the POS UI. Backend models connect to stock.picking for real-time warehouse updates when cuts are completed.
Key Challenge: OWL v2 Migration
Moving from Odoo 16 to 18 required migrating from the old pos.db access pattern to pos.models['product.product']. The deprecated t-att-* directives on OWL components caused silent failures. We fixed IndexedDB serialization errors by overriding _load_pos_data_fields in Python to exclude mail.thread fields.
Real-Time Stock
Our POS Stock Real-Time module (ma_rs_pos_stock) syncs inventory across all POS sessions using reactive badge updates via pos-stock-refreshed custom events. Batch loading handles catalogs with 10,000+ products. A navbar refresh button gives cashiers manual control.