Files
Odoo-Modules/fusion_plating/fusion_plating_jobs/__manifest__.py
gsinghpal ca44461b6f feat(fusion_plating): partial order handling on the shop floor
Operators can now see and advance a job's parts across multiple stages
at once (e.g. 10 Masking / 20 Plating / 20 Baking on one 50-part job).
Tracking model C (fluid per-stage quantities + existing hold/scrap/
rework records for exceptions); board option 2 (a card per occupied
stage); wait-to-reconverge close. Additive only — no new model, no
migration, no change to the close/cert/ship lifecycle.

Board (fusion_plating_shopfloor/controllers/plant_kanban.py):
- One card PER (job, stage), composite key "{job_id}:{area}". Unsplit
  jobs render exactly as before. _job_presences/_render_presence;
  primary presence keeps full job card_state, secondary presences
  derive state from their focus step.

Card (plant_card.js/.xml/.scss):
- "20 of 50 here" badge; tap opens the workspace focused on that
  stage's step (focus_step_id, already accepted by the workspace).

Move + light-up (move_controller.py, fusion_plating_jobs/fp_job_step.py):
- Availability/pre-fill now from qty_at_step (step had no qty_done/
  qty_scrapped fields — the old read was always 0, dead path).
- Forward move auto-flips destination pending->ready (no auto-start;
  labour timer stays explicit) and auto-finishes a drained source
  (best-effort). Predecessor gate is qty-aware: a step with real
  arrived parts is startable regardless of upstream completion
  (_fp_has_real_incoming, single source of truth for can_start /
  blocker / button_start / move blockers).

Operator advance (job_workspace.js):
- "Send -> <next>" action on in_progress/paused steps opens the slimmed
  Move dialog (qty steppers, no keyboard; advanced fields collapsed).
  Was only wired into the deprecated shopfloor_tablet before.

Close (fp_job.py):
- button_mark_done counts move-based scrap (_fp_scrapped_via_moves) into
  qty_scrapped and derives qty_done = qty - scrapped (was blindly
  = job.qty, over-counting). Reconciliation gate unchanged.

Static-validated: pyflakes (py), lxml parse (xml), node --check (js).
Dynamic tests + browser check need an installed env (entech/trial) —
plating modules can't install on the local Community DB.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 01:30:51 -04:00

110 lines
5.3 KiB
Python

# -*- coding: utf-8 -*-
# Copyright 2026 Nexa Systems Inc.
# License OPL-1 (Odoo Proprietary License v1.0)
{
'name': 'Fusion Plating — Native Jobs',
'version': '19.0.11.6.0',
'category': 'Manufacturing/Plating',
'summary': 'Native plating job model — replaces mrp.production / mrp.workorder bridge.',
'author': 'Nexa Systems Inc.',
'website': 'https://www.nexasystems.ca',
'maintainer': 'Nexa Systems Inc.',
'support': 'support@nexasystems.ca',
'price': 0.00,
'currency': 'CAD',
'description': """
Native Plating Job Bridge
=========================
Bridges fp.job and fp.job.step (defined in fusion_plating core, Phase 1 of
the migration spec dated 2026-04-25) to the rest of the Fusion Plating
module family — configurator, portal, logistics, quality, certificates.
Coexists with fusion_plating_bridge_mrp during the migration period.
Activate native jobs via the x_fc_use_native_jobs settings flag (default:
False). When False, SO confirm continues to create mrp.production records
through bridge_mrp. When True, SO confirm creates fp.job records here.
19.0.4.0.0 (2026-04-24): Operator UI consolidation. The parallel
OWL/controller stack (job_process_tree, job_plant_overview,
job_manager_dashboard, job_tablet) was removed. The canonical
operator-facing UIs now live in fusion_plating_shopfloor and bind
directly to fp.job / fp.job.step. This module retains lifecycle hooks,
SO → fp.job creation, reports, and the QR-scan redirect.
See docs/superpowers/specs/2026-04-25-fp-native-job-model-design.md for
full design rationale and §6.2 of the implementation plan for task list.
""",
'depends': [
'fusion_plating', # fp.job, fp.job.step, fp.work.centre
'fusion_plating_batch', # fusion.plating.batch (Phase 3)
'fusion_plating_certificates', # fp.certificate, fp.thickness.reading
'fusion_plating_configurator', # fp.part.catalog
'fusion_plating_kpi', # fusion.plating.kpi.value (Phase 4)
'fusion_plating_logistics', # fusion.plating.delivery
'fusion_plating_notifications', # fp.notification.template (Phase 4)
'fusion_plating_portal', # fusion.plating.portal.job
'fusion_plating_quality', # fusion.plating.customer.spec, fusion.plating.quality.hold
'fusion_plating_receiving', # fp.racking.inspection (Phase 3)
'fusion_plating_reports', # paperformat helpers, customer_line_header (Phase 5)
'fusion_plating_shopfloor', # canonical operator UI consoles
],
'data': [
'security/legacy_groups.xml',
'security/ir.model.access.csv',
'data/fp_cron_data.xml',
# Spec 2026-05-25 — mail.activity.type for QM Issue-CoC nudge.
'data/fp_activity_types_data.xml',
# Sub 14 — workflow state catalog (must load before fp_job_form_inherit
# so the statusbar's m2o has its targets available at view-render time).
'data/fp_workflow_state_data.xml',
'views/fp_workflow_state_views.xml',
'views/fp_job_step_quick_look_views.xml',
'views/fp_job_form_inherit.xml',
'views/fp_job_quality_buttons.xml',
'views/sale_order_views.xml',
'views/fp_receiving_views.xml',
'views/fp_certificate_views.xml',
'views/fp_job_consumption_views.xml',
'views/fp_step_priority_views.xml',
'views/jobs_in_shopfloor_menu.xml',
'views/legacy_menu_hide.xml',
'views/fp_job_cert_backfill.xml',
'views/res_users_views.xml',
'wizards/fp_job_step_move_wizard_views.xml',
'wizards/fp_job_step_input_wizard_views.xml',
'wizards/fp_cert_issue_wizard_views.xml',
'report/report_fp_job_sticker.xml',
'report/report_fp_job_traveller.xml',
'report/report_fp_job_wo_detail.xml',
'report/report_fp_job_margin.xml',
],
'assets': {
# Sub 12d — Step Details quick-look modal styles
# Sub 12e v4 — Record Inputs OWL Dialog (replaces v2/v3)
# Both registered in both bundles so light + dark mode each
# compile correctly ($o-webclient-color-scheme branches at
# compile time per CLAUDE.md note).
'web.assets_backend': [
'fusion_plating_jobs/static/src/scss/fp_step_quick_look.scss',
'fusion_plating_jobs/static/src/scss/fp_record_inputs_dialog.scss',
'fusion_plating_jobs/static/src/scss/fp_finish_btn.scss',
'fusion_plating_jobs/static/src/js/fp_record_inputs_dialog.js',
'fusion_plating_jobs/static/src/js/fp_cert_issue_wizard_autoedit.js',
'fusion_plating_jobs/static/src/xml/fp_record_inputs_dialog.xml',
],
'web.assets_web_dark': [
'fusion_plating_jobs/static/src/scss/fp_step_quick_look.scss',
'fusion_plating_jobs/static/src/scss/fp_record_inputs_dialog.scss',
'fusion_plating_jobs/static/src/scss/fp_finish_btn.scss',
'fusion_plating_jobs/static/src/js/fp_record_inputs_dialog.js',
'fusion_plating_jobs/static/src/js/fp_cert_issue_wizard_autoedit.js',
'fusion_plating_jobs/static/src/xml/fp_record_inputs_dialog.xml',
],
},
'installable': True,
'application': False,
'auto_install': False,
'license': 'OPL-1',
}