chore(plating): de-dash shipped code + intake-neutral customer emails
Replace em-dashes and en-dashes with hyphens across 789 shipped source files (py/xml/js/scss) so the delivered module reads as human-written; em-dashes had become a recognizable AI-generated tell. Internal .md dev notes are excluded. The WO-sticker mojibake strippers keep their dash search targets (now written — / –). No logic changes: comments and display strings only; validated with py_compile + lxml parse. Rewrite the 7 customer notification emails to be intake-neutral (ship-in / drop-off / pickup) and repair-aware, and fix the Shipped email documents line (packing slip vs bill of lading; certificate only when issued). Subjects use a hyphen separator. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -14,7 +14,7 @@ from odoo.exceptions import UserError
|
||||
|
||||
class FpCertVoidWizard(models.TransientModel):
|
||||
_name = 'fp.cert.void.wizard'
|
||||
_description = 'Fusion Plating — Void Certificate Wizard'
|
||||
_description = 'Fusion Plating - Void Certificate Wizard'
|
||||
|
||||
cert_id = fields.Many2one(
|
||||
'fp.certificate', string='Certificate', required=True, readonly=True,
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
</group>
|
||||
<group>
|
||||
<field name="void_reason"
|
||||
placeholder="e.g. Customer rejected lot — re-plating required. Replaced by CoC-30041."
|
||||
placeholder="e.g. Customer rejected lot - re-plating required. Replaced by CoC-30041."
|
||||
nolabel="1"/>
|
||||
</group>
|
||||
</sheet>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
#
|
||||
# When the parser extracts ≥1 reading, the wizard enters "review" state
|
||||
# and the editable reading table is shown. When 0 readings are found,
|
||||
# the wizard enters "manual" state — the operator can still save the
|
||||
# the wizard enters "manual" state - the operator can still save the
|
||||
# file as-is (attach-only fallback). Either way the file ends up in
|
||||
# place to satisfy the action_issue thickness gate.
|
||||
|
||||
@@ -20,7 +20,7 @@ import logging
|
||||
from odoo import _, api, fields, models
|
||||
from odoo.exceptions import UserError
|
||||
|
||||
# Lazy parser import — `from ..lib.fischerscope_parser import …` at
|
||||
# Lazy parser import - `from ..lib.fischerscope_parser import …` at
|
||||
# module top fails on Python 3.11+ because the parent package
|
||||
# `fusion_plating_certificates` is still mid-init when wizards/__init__
|
||||
# imports this file (relative traversal into a partially-loaded parent
|
||||
@@ -44,7 +44,7 @@ class FpThicknessUploadWizard(models.TransientModel):
|
||||
state = fields.Selection(
|
||||
[('upload', 'Upload file'),
|
||||
('review', 'Review parsed readings'),
|
||||
('manual', 'Parse failed — attach only')],
|
||||
('manual', 'Parse failed - attach only')],
|
||||
default='upload', required=True,
|
||||
)
|
||||
|
||||
@@ -133,7 +133,7 @@ class FpThicknessUploadWizard(models.TransientModel):
|
||||
raise UserError(_('Wizard has no certificate to write to.'))
|
||||
if cert.state != 'draft':
|
||||
raise UserError(_(
|
||||
'Cannot attach thickness data — certificate %s is in '
|
||||
'Cannot attach thickness data - certificate %s is in '
|
||||
'state %s. Only draft certificates can be edited.'
|
||||
) % (cert.display_name, cert.state))
|
||||
|
||||
@@ -157,7 +157,7 @@ class FpThicknessUploadWizard(models.TransientModel):
|
||||
'mimetype': self.parsed_image_mime or 'image/jpeg',
|
||||
})
|
||||
|
||||
# Write reading rows — same metadata copied onto every row
|
||||
# Write reading rows - same metadata copied onto every row
|
||||
# (decision confirmed 2026-05-19, so each row is fully self-
|
||||
# describing for downstream queries / reports).
|
||||
if self.reading_line_ids:
|
||||
@@ -189,7 +189,7 @@ class FpThicknessUploadWizard(models.TransientModel):
|
||||
# Chatter audit
|
||||
n = len(self.reading_line_ids)
|
||||
body = (
|
||||
_('Fischerscope thickness report uploaded — %d reading(s) '
|
||||
_('Fischerscope thickness report uploaded - %d reading(s) '
|
||||
'parsed from %s.') % (n, self.file_name or 'file')
|
||||
if n else
|
||||
_('Fischerscope thickness file attached (parse returned no '
|
||||
@@ -228,7 +228,7 @@ class FpThicknessUploadWizard(models.TransientModel):
|
||||
class FpThicknessUploadWizardLine(models.TransientModel):
|
||||
"""Editable reading row in the upload wizard."""
|
||||
_name = 'fp.thickness.upload.wizard.line'
|
||||
_description = 'Thickness Upload Wizard — Reading'
|
||||
_description = 'Thickness Upload Wizard - Reading'
|
||||
_order = 'reading_number'
|
||||
|
||||
wizard_id = fields.Many2one(
|
||||
@@ -240,5 +240,5 @@ class FpThicknessUploadWizardLine(models.TransientModel):
|
||||
p_percent = fields.Float(string='P %', digits=(6, 4))
|
||||
position_label = fields.Char(
|
||||
string='Position',
|
||||
help='Optional — where on the part this reading was taken.',
|
||||
help='Optional - where on the part this reading was taken.',
|
||||
)
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
<strong>Couldn't parse readings.</strong>
|
||||
The file format didn't match what we recognise
|
||||
(Fischerscope XDAL 600 export). You can still save it
|
||||
as-is — the file will attach to the certificate and
|
||||
as-is - the file will attach to the certificate and
|
||||
flow into the CoC PDF as page 2, but the readings
|
||||
won't appear as queryable rows.
|
||||
</div>
|
||||
@@ -122,7 +122,7 @@
|
||||
</record>
|
||||
|
||||
<!-- ================================================================== -->
|
||||
<!-- Window action — opened from the cert form button -->
|
||||
<!-- Window action - opened from the cert form button -->
|
||||
<!-- ================================================================== -->
|
||||
<record id="action_fp_thickness_upload_wizard" model="ir.actions.act_window">
|
||||
<field name="name">Upload Thickness Report</field>
|
||||
|
||||
Reference in New Issue
Block a user