f94be9dfa92e7f539413e8d32b68829906e3fe2f
Three fixes on fp.part.catalog form:
1. 3D Model upload actually works now. The old field exposed only a
Many2one search dropdown — no way to add a new file. Added a
Binary upload slot (model_upload + model_upload_filename) that
fires an onchange which wraps the bytes in an ir.attachment and
links it to model_attachment_id. The upload slot is hidden once a
model is already attached, so the current file stays visible.
Accepts STEP/STP/STL/IGES/IGS/BREP. Auto-runs the surface-area
calculation after attach, same as before.
2. Part Number is now the big <h1> title, Part Name is the smaller
field underneath. Matches how plating shops actually identify
parts (by customer part number, not a free-text name). Swapped
column order in the list view too — Part Number first, then Name.
3. Four smart buttons now on the part form:
- Customer → opens res.partner record
- Sale Orders (already existed)
- Work Orders → filtered mrp.workorder list across SOs for this part
- Quotes (already existed)
- Revisions → shown only when 2+ revs exist, opens the revision
tree filtered by root part
New compute fields workorder_count + revision_count feed the
statinfo widgets, with matching action_view_customer,
action_view_workorders, action_view_revisions handlers.
Verified on demo data:
VS-ESMC6H00801P01 → SO=2, WO=18, REV=2
VS-PQR8440 → SO=1, WO=9, REV=3
All counts light up, buttons drill in cleanly.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Description
Odoo 19 custom modules
Languages
Python
55.9%
HTML
26.1%
JavaScript
14.9%
SCSS
1.8%
CSS
0.8%
Other
0.4%