End-to-end workflow tightening + the team / skills system. Three
phases bundled because they share the same touchpoints (button_start /
button_finish / Manager Desk dropdown).
PHASE 1 — In-Odoo notifications + timer audit
=============================================
Workers now get a bell-icon notification (Odoo Discuss inbox) the
moment a manager assigns them a WO. No email — operators check Discuss
between jobs, and the customer-facing notification dispatcher stays
out of the worker loop.
- mrp.workorder.write() override fires message_notify(message_type=
'user_notification') only when x_fc_assigned_user_id transitions to
a non-empty value (clearing or no-op writes don't ping)
- 4 new fields on the WO header surface what was previously buried in
time_ids: x_fc_started_by_user_id, x_fc_started_at,
x_fc_finished_by_user_id, x_fc_finished_at
- button_start stamps started_* once (subsequent pause/resume cycles
preserve the original); button_finish stamps finished_* every time
the WO closes
- New "Timer Audit" group on the WO form (Time & Cost tab)
PHASE 2 — Presence-aware Manager Desk
=====================================
Manager Desk now knows who's clocked in. Works with vanilla
hr_attendance and fusion_clock — both expose hr.attendance with an
open record while the operator is on shift.
- bridge_mrp depends on hr_attendance
- hr.employee.x_fc_is_clocked_in computed field (batched query — one
DB hit for the whole employee set, not N+1)
- hr.employee._fp_clocked_in_user_ids() classmethod for the dashboard
- manager_controller sends operators with is_clocked_in / role_ids /
lead_hand_role_ids per worker, plus presence dict {clocked_in: N,
total: M}; each WO carries role_id/role_name so the dropdown can
match qualified operators
Manager Desk OWL:
- Header gets a "Present 7 / 12" pill chip; tap to toggle hideOffShift
(off-shift hidden when active, accent colour when filter is on)
- New operatorsForWO(wo) helper sorts dropdown options into 4 buckets:
qualified+clocked-in → lead-hand+clocked-in → clocked-in untrained
(training mode) → off-shift (greyed; only shown when hideOffShift
is false). Each option carries a ●/○ dot prefix and a soft suffix.
PHASE 3 — Skills, lead-hand-per-role, auto-promotion
====================================================
The team grows organically: managers assign training tasks, operators
finish them, the system auto-promotes after N successful runs.
- fp.work.role.mastery_required (integer, default reads from the
company-level Default Mastery Threshold). Each role can override —
masking might need 1 success, electroless nickel 5.
- res.company.x_fc_default_mastery_threshold + res.config.settings
exposure under "Workforce Settings" in the Fusion Plating settings
block (default 3)
- hr.employee.x_fc_lead_hand_role_ids m2m, separate from
x_fc_work_role_ids — Sarah can be a lead hand for masking + racking
even if those aren't her primary roles. Manager-only group access.
- New fp.operator.proficiency model (one row per employee+role) with
completed_count, first/last_completed_at, promoted, promoted_at,
progress_label compute. SQL-unique on (employee, role).
- mrp.workorder.button_finish increments the (employee, role)
counter, then if count >= role.mastery_required AND not promoted,
adds the role to x_fc_work_role_ids and posts a "🎉 Promoted"
chatter line on the employee record. Wrapped in try/except so a
tracker glitch never blocks production.
- Promotion uses the WO's assigned_user_id, NOT env.user — credit
goes to the operator who was supposed to do it, even if a manager
finished on their behalf.
Employee form gets a "Shop Roles" tab (supervisor+):
- "Tasks This Operator Can Do" m2m
- "Lead Hand For" m2m (manager-only)
- Read-only Task Proficiency list with progress / promotion badges
Verified on odoo-entech: all fields land, default threshold = 3,
asset bundle regenerated as 9f38f05.
Module bumps: fusion_plating 19.0.4.0.0,
fusion_plating_bridge_mrp 19.0.4.0.0,
fusion_plating_shopfloor 19.0.11.0.0.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
3.2 KiB
3.2 KiB
| 1 | id | name | model_id:id | group_id:id | perm_read | perm_write | perm_create | perm_unlink |
|---|---|---|---|---|---|---|---|---|
| 2 | access_fp_bridge_mrp_workcenter_manager | fp.bridge.mrp.workcenter.manager | mrp.model_mrp_workcenter | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 0 |
| 3 | access_fp_bridge_mrp_workcenter_supervisor | fp.bridge.mrp.workcenter.supervisor | mrp.model_mrp_workcenter | fusion_plating.group_fusion_plating_supervisor | 1 | 0 | 0 | 0 |
| 4 | access_fp_bridge_mrp_workorder_manager | fp.bridge.mrp.workorder.manager | mrp_workorder.model_mrp_workorder | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 0 |
| 5 | access_fp_bridge_mrp_workorder_supervisor | fp.bridge.mrp.workorder.supervisor | mrp_workorder.model_mrp_workorder | fusion_plating.group_fusion_plating_supervisor | 1 | 0 | 0 | 0 |
| 6 | access_fp_bridge_mrp_production_manager | fp.bridge.mrp.production.manager | mrp.model_mrp_production | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 0 |
| 7 | access_fp_bridge_mrp_production_supervisor | fp.bridge.mrp.production.supervisor | mrp.model_mrp_production | fusion_plating.group_fusion_plating_supervisor | 1 | 0 | 0 | 0 |
| 8 | access_fp_job_node_override_operator | fp.job.node.override.operator | model_fusion_plating_job_node_override | fusion_plating.group_fusion_plating_operator | 1 | 0 | 0 | 0 |
| 9 | access_fp_job_node_override_supervisor | fp.job.node.override.supervisor | model_fusion_plating_job_node_override | fusion_plating.group_fusion_plating_supervisor | 1 | 1 | 1 | 0 |
| 10 | access_fp_job_node_override_manager | fp.job.node.override.manager | model_fusion_plating_job_node_override | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |
| 11 | access_fp_recipe_config_wizard_supervisor | fp.recipe.config.wizard.supervisor | model_fp_recipe_config_wizard | fusion_plating.group_fusion_plating_supervisor | 1 | 1 | 1 | 0 |
| 12 | access_fp_recipe_config_wizard_manager | fp.recipe.config.wizard.manager | model_fp_recipe_config_wizard | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |
| 13 | access_fp_recipe_config_wizard_line_supervisor | fp.recipe.config.wizard.line.supervisor | model_fp_recipe_config_wizard_line | fusion_plating.group_fusion_plating_supervisor | 1 | 1 | 1 | 0 |
| 14 | access_fp_recipe_config_wizard_line_manager | fp.recipe.config.wizard.line.manager | model_fp_recipe_config_wizard_line | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |
| 15 | access_fp_job_consumption_operator | fp.job.consumption.operator | model_fp_job_consumption | fusion_plating.group_fusion_plating_operator | 1 | 1 | 1 | 0 |
| 16 | access_fp_job_consumption_supervisor | fp.job.consumption.supervisor | model_fp_job_consumption | fusion_plating.group_fusion_plating_supervisor | 1 | 1 | 1 | 0 |
| 17 | access_fp_job_consumption_manager | fp.job.consumption.manager | model_fp_job_consumption | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |
| 18 | access_fp_work_role_operator | fp.work.role.operator | model_fp_work_role | fusion_plating.group_fusion_plating_operator | 1 | 0 | 0 | 0 |
| 19 | access_fp_work_role_manager | fp.work.role.manager | model_fp_work_role | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |
| 20 | access_fp_proficiency_operator | fp.operator.proficiency.operator | model_fp_operator_proficiency | fusion_plating.group_fusion_plating_operator | 1 | 0 | 0 | 0 |
| 21 | access_fp_proficiency_supervisor | fp.operator.proficiency.supervisor | model_fp_operator_proficiency | fusion_plating.group_fusion_plating_supervisor | 1 | 1 | 1 | 0 |
| 22 | access_fp_proficiency_manager | fp.operator.proficiency.manager | model_fp_operator_proficiency | fusion_plating.group_fusion_plating_manager | 1 | 1 | 1 | 1 |