feat(certificates): module scaffold + fp.thickness.reading model
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
6
fusion-plating/fusion_plating_certificates/__init__.py
Normal file
6
fusion-plating/fusion_plating_certificates/__init__.py
Normal file
@@ -0,0 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
# Part of the Fusion Plating product family.
|
||||
|
||||
from . import models
|
||||
40
fusion-plating/fusion_plating_certificates/__manifest__.py
Normal file
40
fusion-plating/fusion_plating_certificates/__manifest__.py
Normal file
@@ -0,0 +1,40 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
# Part of the Fusion Plating product family.
|
||||
|
||||
{
|
||||
'name': 'Fusion Plating — Certificates',
|
||||
'version': '19.0.1.0.0',
|
||||
'category': 'Manufacturing/Plating',
|
||||
'summary': 'Certificate registry for CoC, thickness reports, and quality documents.',
|
||||
'description': """
|
||||
Fusion Plating — Certificates
|
||||
===============================
|
||||
|
||||
Unified certificate registry tracking all quality documents issued to customers.
|
||||
Includes Fischerscope thickness measurement data capture.
|
||||
""",
|
||||
'author': 'Nexa Systems Inc.',
|
||||
'website': 'https://www.nexasystems.ca',
|
||||
'maintainer': 'Nexa Systems Inc.',
|
||||
'support': 'support@nexasystems.ca',
|
||||
'license': 'OPL-1',
|
||||
'price': 0.00,
|
||||
'currency': 'CAD',
|
||||
'depends': [
|
||||
'fusion_plating',
|
||||
'fusion_plating_portal',
|
||||
'mrp',
|
||||
'sale_management',
|
||||
],
|
||||
'data': [
|
||||
'security/ir.model.access.csv',
|
||||
'data/fp_certificate_sequence_data.xml',
|
||||
'views/fp_certificate_views.xml',
|
||||
'views/fp_certificates_menu.xml',
|
||||
],
|
||||
'installable': True,
|
||||
'application': False,
|
||||
'auto_install': False,
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo noupdate="1">
|
||||
<record id="seq_fp_certificate" model="ir.sequence">
|
||||
<field name="name">Fusion Plating: Certificate</field>
|
||||
<field name="code">fp.certificate</field>
|
||||
<field name="prefix">CERT-</field>
|
||||
<field name="padding">5</field>
|
||||
<field name="company_id" eval="False"/>
|
||||
</record>
|
||||
</odoo>
|
||||
@@ -0,0 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
# Part of the Fusion Plating product family.
|
||||
|
||||
from . import fp_thickness_reading
|
||||
from . import fp_certificate
|
||||
@@ -0,0 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
# Part of the Fusion Plating product family.
|
||||
|
||||
# Placeholder — fp.certificate model will be implemented in a subsequent task.
|
||||
@@ -0,0 +1,61 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2026 Nexa Systems Inc.
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
# Part of the Fusion Plating product family.
|
||||
|
||||
from odoo import fields, models
|
||||
|
||||
|
||||
class FpThicknessReading(models.Model):
|
||||
"""Fischerscope thickness measurement data.
|
||||
|
||||
Captures individual XRF readings from equipment like the
|
||||
Fischerscope XDAL 600. Linked to certificates and/or MOs.
|
||||
Data is manually entered for now; future: CSV import from equipment.
|
||||
"""
|
||||
_name = 'fp.thickness.reading'
|
||||
_description = 'Fusion Plating — Thickness Reading'
|
||||
_order = 'reading_number'
|
||||
|
||||
certificate_id = fields.Many2one(
|
||||
'fp.certificate', string='Certificate', ondelete='cascade',
|
||||
)
|
||||
production_id = fields.Many2one(
|
||||
'mrp.production', string='Manufacturing Order',
|
||||
)
|
||||
reading_number = fields.Integer(
|
||||
string='Reading #', default=1, help='Sequence number (n=1, n=2, n=3).',
|
||||
)
|
||||
nip_mils = fields.Float(
|
||||
string='NiP (mils)', digits=(10, 4), help='NiP thickness in mils.',
|
||||
)
|
||||
ni_percent = fields.Float(
|
||||
string='Ni %', digits=(6, 3), help='Nickel content percentage.',
|
||||
)
|
||||
p_percent = fields.Float(
|
||||
string='P %', digits=(6, 4), help='Phosphorus content percentage.',
|
||||
)
|
||||
position_label = fields.Char(
|
||||
string='Position', help='Where on the part this reading was taken.',
|
||||
)
|
||||
equipment_model = fields.Char(
|
||||
string='Equipment', default='Fischerscope XDAL 600',
|
||||
)
|
||||
product_ref = fields.Char(
|
||||
string='Product Ref', help='e.g. "2805031 / NiP/Al-alloys 2805030"',
|
||||
)
|
||||
calibration_std_ref = fields.Char(
|
||||
string='Calibration Std', help='e.g. "NiP/Al STD SET SN 100174568"',
|
||||
)
|
||||
microscope_image_id = fields.Many2one(
|
||||
'ir.attachment', string='Microscope Image',
|
||||
)
|
||||
operator_id = fields.Many2one(
|
||||
'res.users', string='Operator', default=lambda self: self.env.user,
|
||||
)
|
||||
reading_datetime = fields.Datetime(
|
||||
string='Reading Date/Time', default=fields.Datetime.now,
|
||||
)
|
||||
measuring_time_seconds = fields.Integer(
|
||||
string='Measuring Time (sec)', default=120,
|
||||
)
|
||||
@@ -0,0 +1,7 @@
|
||||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
access_fp_certificate_operator,fp.certificate.operator,model_fp_certificate,fusion_plating.group_fusion_plating_operator,1,0,0,0
|
||||
access_fp_certificate_supervisor,fp.certificate.supervisor,model_fp_certificate,fusion_plating.group_fusion_plating_supervisor,1,1,1,0
|
||||
access_fp_certificate_manager,fp.certificate.manager,model_fp_certificate,fusion_plating.group_fusion_plating_manager,1,1,1,1
|
||||
access_fp_thickness_reading_operator,fp.thickness.reading.operator,model_fp_thickness_reading,fusion_plating.group_fusion_plating_operator,1,0,0,0
|
||||
access_fp_thickness_reading_supervisor,fp.thickness.reading.supervisor,model_fp_thickness_reading,fusion_plating.group_fusion_plating_supervisor,1,1,1,0
|
||||
access_fp_thickness_reading_manager,fp.thickness.reading.manager,model_fp_thickness_reading,fusion_plating.group_fusion_plating_manager,1,1,1,1
|
||||
|
Binary file not shown.
|
After Width: | Height: | Size: 26 KiB |
@@ -0,0 +1,2 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo></odoo>
|
||||
@@ -0,0 +1,2 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo></odoo>
|
||||
Reference in New Issue
Block a user