← ClaudeAtlas

odoo-viewslisted

Authoring or editing Odoo view XML — form, list, kanban, search, pivot, graph, calendar, activity, gantt — and view inheritance (inherit_id, xpath, position, <attribute>). Use whenever writing a view, adding a field/button/page/filter to an existing view, fixing field visibility, or migrating old view XML, even if the user never says "skill". Covers the v17/18 breaking syntax LLMs get wrong: `attrs` and `states` are REMOVED — use direct `invisible=` / `readonly=` / `required=` / `column_invisible=` with Python expressions; the list root is `<list>` (was `<tree>`); chatter is `<chatter/>`. Before editing any view, dump the inheritance-resolved arch + existing buttons/modifiers with the `odoo-introspect` skill (entrypoints) so your xpath targets actually exist — a wrong xpath fails silently.
tuanle96/odoo-ai-skills · ★ 4 · AI & Automation · score 62
Install: claude install-skill tuanle96/odoo-ai-skills
# Odoo views The view you edit is **not** the view that renders. Odoo merges the base arch with every inheriting view across the addon graph at `get_view()` time. An xpath that doesn't match the *resolved* arch silently no-ops — the field you "added" never appears and nothing is logged. **Read ground truth first.** Run the `odoo-introspect` skill's **entrypoints** on the model: it dumps the inheritance-resolved arch, the buttons (which method/action each fires), and the view-level field modifiers (readonly/invisible/required). It also returns the **`inheritance_chain`** — the base view plus every applied extension in priority order — so you pick the right view to inherit and can see which siblings already touch your target node. Render one specific view with `--view-xmlid`/`--view-id`. Now your xpath targets exist and you won't duplicate a field. **Version floor: Odoo 17/18, through Odoo 19 (current LTS).** Pre-17 deltas and the v18.1 → 19 changes → `skills/odoo-introspect/references/version-matrix.md`. ## v17/18 breaking syntax — get this right | Old (≤16) | Current | Since | |---|---|---| | `attrs="{'invisible': [('state','=','done')]}"` | `invisible="state == 'done'"` | **17.0** | | `attrs` for readonly/required | `readonly="<expr>"` / `required="<expr>"` | **17.0** | | `states="draft,sent"` | `invisible="state not in ['draft','sent']"` | **17.0** | | `invisible` to hide a **list column** | `column_invisible="<expr>"` (plain `invisible` hides only the cell) | 17.0 | |