feat(jobs): Phase 6 — Process Tree OWL component for fp.job
Ports fusion_plating_shopfloor's process_tree.js to bind to fp.job instead of mrp.production. Consumes the /fp/jobs/process_tree JSON endpoint built in Phase 6 lean. Renders the recipe tree as cards. Each operation card shows the step state (pending/ready/in_progress/done/etc.) when there's a matching fp.job.step. Click an operation card -> open the step form. Click Back -> return to the job form. New 'Process Tree' button on the fp.job form (manager-only) launches the client action with job_id context. Manifest 19.0.2.1.0 -> 19.0.2.2.0. Part of: native job model migration (spec 2026-04-25) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<odoo>
|
||||
<!--
|
||||
Adds a "Process Tree" button to the fp.job form header, launching
|
||||
the fp_job_process_tree client action with job_id in context.
|
||||
|
||||
Hidden while the job is in draft (no recipe-derived steps yet).
|
||||
-->
|
||||
<record id="view_fp_job_form_jobs_inherit" model="ir.ui.view">
|
||||
<field name="name">fp.job.form.jobs.inherit</field>
|
||||
<field name="model">fp.job</field>
|
||||
<field name="inherit_id" ref="fusion_plating.view_fp_job_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="action_open_process_tree" type="object"
|
||||
string="Process Tree"
|
||||
class="btn-secondary"
|
||||
icon="fa-sitemap"
|
||||
invisible="state == 'draft'"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<odoo>
|
||||
<!--
|
||||
fp_job_process_tree client action — opened from the "Process Tree"
|
||||
button on the fp.job form (action_open_process_tree on fp.job)
|
||||
with {'job_id': self.id} in context.
|
||||
-->
|
||||
<record id="action_job_process_tree" model="ir.actions.client">
|
||||
<field name="name">Job Process Tree</field>
|
||||
<field name="tag">fp_job_process_tree</field>
|
||||
</record>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user