fix(fusion_plating_shopfloor): stop breadcrumb URL growth; embed racking panel in step row
Surface switches between the plant kanban and job workspace used
doAction({..., target: "current"}), which APPENDS to Odoo 19's
controller/breadcrumb stack -- so the /odoo/... URL grew one segment
per switch, and the tablet lock/unlock window.location.reload()
preserved the bloat, compounding it every lock cycle. Switched those
navigations to target: "main" (Odoo sets clearBreadcrumbs when
action.target === "main" -> _computeStackIndex returns 0 -> stack
resets to a single action). The genuine one-level drill-down
(onJumpToBlocker -> hold/NCR form) keeps target: "current" so
breadcrumb-back still works there.
Also embeds the multi-rack racking panel inside the Racking step row
(gated on step.area_kind == 'racking') instead of a job-level section,
tying it to the recipe's Racking step.
19.0.37.0.1 -> 19.0.37.0.3. Both changes live on entech.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -75,6 +75,8 @@ class FpWorkspaceController(http.Controller):
|
||||
'name': step.name or '',
|
||||
'kind': step.kind or 'other',
|
||||
'kind_label': dict(step._fields['kind'].selection).get(step.kind, ''),
|
||||
# Drives the embedded rack-split panel inside this step's row.
|
||||
'is_racking': step.area_kind == 'racking',
|
||||
'state': step.state,
|
||||
'assigned_user_id': step.assigned_user_id.id or False,
|
||||
'assigned_user_name': step.assigned_user_id.name or '',
|
||||
@@ -283,14 +285,9 @@ class FpWorkspaceController(http.Controller):
|
||||
'is_manager': env.user.has_group(
|
||||
'fusion_plating.group_fusion_plating_manager',
|
||||
),
|
||||
# Racking panel (multi-rack split) shows when the WO is at the
|
||||
# racking step and it's the current actionable work. Detect by
|
||||
# area_kind == 'racking' (corrected classification) — NOT
|
||||
# _fp_is_racking_step(), which would also match mis-tagged
|
||||
# De-Racking steps (kind='racking' in the data).
|
||||
'is_at_racking': bool(job.step_ids.filtered(
|
||||
lambda s: s.area_kind == 'racking'
|
||||
and s.state in ('ready', 'in_progress', 'paused'))),
|
||||
# Note: the rack-split panel is gated per-step via each step's
|
||||
# 'is_racking' flag (area_kind == 'racking'), embedded in the
|
||||
# racking step's row — not a job-level panel.
|
||||
}
|
||||
|
||||
# ======================================================================
|
||||
|
||||
Reference in New Issue
Block a user