From 7966f8d5051c61c00421c35ad9c5762ea731d95b Mon Sep 17 00:00:00 2001 From: gsinghpal Date: Sun, 24 May 2026 10:48:29 -0400 Subject: [PATCH] fix(shopfloor): tablet tiles domain uses group_ids (Odoo 19 rename) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Same mistake as the original implementer wave — used the deprecated groups_id field name on res.users in the search domain. Odoo 19 raises ValueError: Invalid field res.users.groups_id. Should be group_ids. CLAUDE.md rule 13l example also fixed so future-Claude doesn't copy the bug from the documentation. Module version: 19.0.32.0.12 -> 19.0.32.0.13 Co-Authored-By: Claude Opus 4.7 (1M context) --- fusion_plating/CLAUDE.md | 2 +- fusion_plating/fusion_plating_shopfloor/__manifest__.py | 2 +- .../fusion_plating_shopfloor/controllers/tablet_controller.py | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/fusion_plating/CLAUDE.md b/fusion_plating/CLAUDE.md index 447d0862..02b16a2f 100644 --- a/fusion_plating/CLAUDE.md +++ b/fusion_plating/CLAUDE.md @@ -240,7 +240,7 @@ Use only: `name`, `model_id`, `state`, `code` (or `function`/`model`), `interval 'fusion_plating.group_fp_owner', )] users = env['res.users'].sudo().search([ - ('groups_id', 'in', shop_branch_ids), + ('group_ids', 'in', shop_branch_ids), # NB: group_ids not groups_id in Odoo 19, see rule 13c ('share', '=', False), ('active', '=', True), ]) ``` diff --git a/fusion_plating/fusion_plating_shopfloor/__manifest__.py b/fusion_plating/fusion_plating_shopfloor/__manifest__.py index 6c9ca722..49ba505d 100644 --- a/fusion_plating/fusion_plating_shopfloor/__manifest__.py +++ b/fusion_plating/fusion_plating_shopfloor/__manifest__.py @@ -5,7 +5,7 @@ { 'name': 'Fusion Plating — Shop Floor', - 'version': '19.0.32.0.12', + 'version': '19.0.32.0.13', 'category': 'Manufacturing/Plating', 'summary': 'Shop-floor tablet stations, QR scanning, bake window enforcer, ' 'first-piece inspection gates.', diff --git a/fusion_plating/fusion_plating_shopfloor/controllers/tablet_controller.py b/fusion_plating/fusion_plating_shopfloor/controllers/tablet_controller.py index 6b88ebc8..c97fb7c9 100644 --- a/fusion_plating/fusion_plating_shopfloor/controllers/tablet_controller.py +++ b/fusion_plating/fusion_plating_shopfloor/controllers/tablet_controller.py @@ -242,8 +242,9 @@ class FpTabletController(http.Controller): return {'ok': False, 'error': 'shop-branch role groups missing'} Users = env['res.users'].sudo() + # Odoo 19 renamed res.users.groups_id -> group_ids (CLAUDE.md rule 13c). users = Users.search([ - ('groups_id', 'in', group_ids), + ('group_ids', 'in', group_ids), ('share', '=', False), ('active', '=', True), ])