This commit is contained in:
gsinghpal
2026-04-28 19:39:37 -04:00
parent 2d42b33d68
commit 13e300d90e
103 changed files with 4959 additions and 331 deletions

View File

@@ -7,6 +7,7 @@ from odoo import api, fields, models, _
from odoo.exceptions import ValidationError
from .fp_tz import fp_isoformat_utc
from ._fp_uom_selection import FP_UOM_SELECTION
class FpProcessNode(models.Model):
@@ -352,6 +353,7 @@ class FpProcessNode(models.Model):
('final_inspect', 'Final Inspection'),
('ship', 'Shipping'),
('gating', 'Gating'),
('contract_review', 'Contract Review (QA-005)'),
],
string='Step Kind',
)
@@ -652,9 +654,11 @@ class FpProcessNodeInput(models.Model):
string='Sequence',
default=10,
)
uom = fields.Char(
uom = fields.Selection(
FP_UOM_SELECTION,
string='Unit',
help='Unit label (e.g. °C, min, psi).',
help='Unit the operator is recording in (pick from the curated list — '
'avoids "kg" vs "kgs" vs "kilo" inconsistencies).',
)
# ===== Sub 12a — kind + target ranges + compliance tag ==================
@@ -668,9 +672,19 @@ class FpProcessNodeInput(models.Model):
'recorded when leaving the step (Sub 12b uses these in the '
'Move Parts dialog).',
)
target_min = fields.Float(string='Target Min')
target_max = fields.Float(string='Target Max')
target_unit = fields.Char(string='Target Unit')
target_min = fields.Float(
string='Target Min',
help='Lower bound of the acceptable range, expressed in Target Unit.',
)
target_max = fields.Float(
string='Target Max',
help='Upper bound of the acceptable range, expressed in Target Unit.',
)
target_unit = fields.Selection(
FP_UOM_SELECTION,
string='Target Unit',
help='Unit Target Min / Target Max are measured in.',
)
compliance_tag = fields.Selection(
[
('none', 'None'),