changes
This commit is contained in:
@@ -50,7 +50,7 @@
|
||||
<field name="description">Filter-press cake from hexavalent chrome waste treatment system.</field>
|
||||
<field name="physical_state">liquid</field>
|
||||
<field name="generation_rate">45.0</field>
|
||||
<field name="generation_uom">kg/day</field>
|
||||
<field name="generation_uom">kg_day</field>
|
||||
<field name="disposal_method">Licensed hazardous waste facility</field>
|
||||
</record>
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
<field name="description">Spent sulphuric and hydrochloric acid from pickling tanks.</field>
|
||||
<field name="physical_state">liquid</field>
|
||||
<field name="generation_rate">120.0</field>
|
||||
<field name="generation_uom">L/day</field>
|
||||
<field name="generation_uom">l_day</field>
|
||||
<field name="disposal_method">Acid reclamation</field>
|
||||
</record>
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
<field name="description">Sludge from black oxide line waste treatment.</field>
|
||||
<field name="physical_state">sludge</field>
|
||||
<field name="generation_rate">10.0</field>
|
||||
<field name="generation_uom">kg/day</field>
|
||||
<field name="generation_uom">kg_day</field>
|
||||
<field name="disposal_method">Stabilisation and secure landfill</field>
|
||||
</record>
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
<field name="waste_stream_id" ref="demo_waste_stream_spent_acid"/>
|
||||
<field name="ship_date" eval="(DateTime.today()).strftime('%Y-%m-%d')"/>
|
||||
<field name="quantity">800.0</field>
|
||||
<field name="uom">L</field>
|
||||
<field name="uom">l</field>
|
||||
<field name="state">draft</field>
|
||||
<field name="notes" type="html"><p>Pending carrier assignment for spent acid pickup.</p></field>
|
||||
</record>
|
||||
@@ -107,7 +107,7 @@
|
||||
<field name="spill_date" eval="(DateTime.today() - timedelta(days=7)).strftime('%Y-%m-%d %H:%M:%S')"/>
|
||||
<field name="substance">Chromic Acid</field>
|
||||
<field name="quantity">5.0</field>
|
||||
<field name="uom">L</field>
|
||||
<field name="uom">l</field>
|
||||
<field name="location">Chrome line — tank overflow berm</field>
|
||||
<field name="containment_action">Spill contained within secondary containment berm. Absorbent pads deployed. Area neutralised with soda ash.</field>
|
||||
<field name="regulator_notified" eval="True"/>
|
||||
@@ -121,7 +121,7 @@
|
||||
<field name="spill_date" eval="(DateTime.today() - timedelta(days=45)).strftime('%Y-%m-%d %H:%M:%S')"/>
|
||||
<field name="substance">Nickel Sulphate Solution</field>
|
||||
<field name="quantity">2.0</field>
|
||||
<field name="uom">L</field>
|
||||
<field name="uom">l</field>
|
||||
<field name="location">East Annex — nickel line transfer pump</field>
|
||||
<field name="containment_action">Minor drip from pump seal. Caught by drip tray, cleaned immediately.</field>
|
||||
<field name="regulator_notified" eval="False"/>
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
from odoo import fields, models
|
||||
|
||||
from odoo.addons.fusion_plating.models._fp_uom_selection import FP_UOM_SELECTION
|
||||
|
||||
|
||||
class FpDischargeLimit(models.Model):
|
||||
_name = 'fusion.plating.discharge.limit'
|
||||
@@ -18,8 +20,11 @@ class FpDischargeLimit(models.Model):
|
||||
('combined', 'Combined Sewer'), ('air', 'Air Emission'), ('other', 'Other')],
|
||||
string='Discharge Point', default='sanitary', required=True,
|
||||
)
|
||||
limit_value = fields.Float(string='Limit', digits=(16, 4))
|
||||
uom = fields.Char(string='UoM')
|
||||
limit_value = fields.Float(string='Limit', digits=(16, 4),
|
||||
help='Numerical limit, expressed in the unit selected below.')
|
||||
uom = fields.Selection(FP_UOM_SELECTION, string='UoM',
|
||||
help='Unit the limit is enforced in (typical: mg/L for liquid '
|
||||
'discharge, mg/m³ for air emissions).')
|
||||
limit_type = fields.Selection(
|
||||
[('max', 'Maximum'), ('min', 'Minimum'), ('range', 'Range'), ('ceiling', 'Hard Ceiling')],
|
||||
string='Limit Type', default='max', required=True,
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
from odoo import api, fields, models
|
||||
|
||||
from odoo.addons.fusion_plating.models._fp_uom_selection import FP_UOM_SELECTION
|
||||
|
||||
|
||||
class FpDischargeSampleLine(models.Model):
|
||||
_name = 'fusion.plating.discharge.sample.line'
|
||||
@@ -12,8 +14,11 @@ class FpDischargeSampleLine(models.Model):
|
||||
sample_id = fields.Many2one('fusion.plating.discharge.sample', string='Sample', required=True, ondelete='cascade')
|
||||
limit_id = fields.Many2one('fusion.plating.discharge.limit', string='Limit', ondelete='restrict')
|
||||
parameter = fields.Char(string='Parameter', related='limit_id.parameter', store=True, readonly=False)
|
||||
value = fields.Float(string='Result', digits=(16, 4))
|
||||
uom = fields.Char(string='UoM')
|
||||
value = fields.Float(string='Result', digits=(16, 4),
|
||||
help='Measured value, expressed in the unit selected below.')
|
||||
uom = fields.Selection(FP_UOM_SELECTION, string='UoM',
|
||||
help='Unit of the measured value. Defaults to the limit\'s unit; '
|
||||
'override only when the lab reported in a different unit.')
|
||||
status = fields.Selection(
|
||||
[('ok', 'OK'), ('warning', 'Warning'), ('out_of_spec', 'Out of Spec'), ('pending', 'Pending')],
|
||||
string='Status', compute='_compute_status', store=True,
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
from odoo import api, fields, models
|
||||
|
||||
from odoo.addons.fusion_plating.models._fp_uom_selection import FP_UOM_SELECTION
|
||||
|
||||
|
||||
class FpSpillRegister(models.Model):
|
||||
_name = 'fusion.plating.spill.register'
|
||||
@@ -16,8 +18,10 @@ class FpSpillRegister(models.Model):
|
||||
spill_date = fields.Datetime(string='Spill Date', required=True, default=fields.Datetime.now, tracking=True)
|
||||
reported_by_id = fields.Many2one('res.users', string='Reported By', default=lambda s: s.env.user)
|
||||
substance = fields.Char(string='Substance', tracking=True)
|
||||
quantity = fields.Float(string='Quantity', digits=(16, 3))
|
||||
uom = fields.Char(string='UoM', default='L')
|
||||
quantity = fields.Float(string='Quantity', digits=(16, 3),
|
||||
help='Quantity spilled, expressed in the unit selected below.')
|
||||
uom = fields.Selection(FP_UOM_SELECTION, string='UoM', default='l',
|
||||
help='Unit of the spill quantity (L for liquids, kg for solids).')
|
||||
location = fields.Char(string='Location')
|
||||
containment_action = fields.Text(string='Containment Action')
|
||||
regulator_notified = fields.Boolean(string='Regulator Notified', tracking=True)
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
from odoo import api, fields, models
|
||||
|
||||
from odoo.addons.fusion_plating.models._fp_uom_selection import FP_UOM_SELECTION
|
||||
|
||||
|
||||
class FpWasteManifest(models.Model):
|
||||
_name = 'fusion.plating.waste.manifest'
|
||||
@@ -15,8 +17,10 @@ class FpWasteManifest(models.Model):
|
||||
facility_id = fields.Many2one('fusion.plating.facility', related='waste_stream_id.facility_id', store=True, readonly=True)
|
||||
company_id = fields.Many2one('res.company', related='facility_id.company_id', store=True, readonly=True)
|
||||
ship_date = fields.Date(string='Ship Date', default=fields.Date.context_today, tracking=True)
|
||||
quantity = fields.Float(string='Quantity', digits=(16, 3))
|
||||
uom = fields.Char(string='UoM', default='kg')
|
||||
quantity = fields.Float(string='Quantity', digits=(16, 3),
|
||||
help='Quantity shipped, expressed in the unit selected below.')
|
||||
uom = fields.Selection(FP_UOM_SELECTION, string='UoM', default='kg',
|
||||
help='Unit of the shipped quantity (kg, L, m³, etc.).')
|
||||
carrier_id = fields.Many2one('res.partner', string='Carrier', domain=[('is_company', '=', True)], tracking=True)
|
||||
receiver_id = fields.Many2one('res.partner', string='Receiver', domain=[('is_company', '=', True)], tracking=True)
|
||||
manifest_number = fields.Char(string='Manifest #', tracking=True)
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
# License OPL-1 (Odoo Proprietary License v1.0)
|
||||
from odoo import fields, models
|
||||
|
||||
from odoo.addons.fusion_plating.models._fp_uom_selection import FP_UOM_SELECTION
|
||||
|
||||
|
||||
class FpWasteStream(models.Model):
|
||||
_name = 'fusion.plating.waste.stream'
|
||||
@@ -19,8 +21,12 @@ class FpWasteStream(models.Model):
|
||||
[('liquid', 'Liquid'), ('solid', 'Solid'), ('sludge', 'Sludge'), ('gas', 'Gas')],
|
||||
string='Physical State', default='liquid',
|
||||
)
|
||||
generation_rate = fields.Float(string='Generation Rate')
|
||||
generation_uom = fields.Char(string='Rate UoM', default='kg/day')
|
||||
generation_rate = fields.Float(string='Generation Rate',
|
||||
help='Average rate this stream is produced at, expressed in the '
|
||||
'rate unit below (typical: kg/day, L/day).')
|
||||
generation_uom = fields.Selection(FP_UOM_SELECTION, string='Rate UoM',
|
||||
default='kg_day',
|
||||
help='Unit of the generation rate (kg/day, L/day, kg/month, etc.).')
|
||||
disposal_method = fields.Char(string='Disposal Method')
|
||||
approved_carrier_id = fields.Many2one('res.partner', string='Approved Carrier', domain=[('is_company', '=', True)])
|
||||
approved_facility_id = fields.Many2one('res.partner', string='Approved Receiving Facility', domain=[('is_company', '=', True)])
|
||||
|
||||
@@ -43,7 +43,8 @@
|
||||
<field name="regulator_id"/>
|
||||
</group>
|
||||
</group>
|
||||
<group string="Notes"><field name="notes" nolabel="1"/></group>
|
||||
<separator string="Notes"/>
|
||||
<field name="notes"/>
|
||||
</sheet>
|
||||
<chatter/>
|
||||
</form>
|
||||
|
||||
@@ -45,7 +45,8 @@
|
||||
</group>
|
||||
</group>
|
||||
<group><field name="reference_url" widget="url"/></group>
|
||||
<group string="Notes"><field name="notes" nolabel="1"/></group>
|
||||
<separator string="Notes"/>
|
||||
<field name="notes"/>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
@@ -48,9 +48,8 @@
|
||||
</list>
|
||||
</field>
|
||||
</group>
|
||||
<group string="Compliance Notes">
|
||||
<field name="x_fp_compliance_notes" nolabel="1"/>
|
||||
</group>
|
||||
<separator string="Compliance Notes"/>
|
||||
<field name="x_fp_compliance_notes"/>
|
||||
</page>
|
||||
</xpath>
|
||||
</field>
|
||||
|
||||
@@ -72,7 +72,8 @@
|
||||
<field name="owner_id"/>
|
||||
<field name="status"/>
|
||||
</group>
|
||||
<group string="Description"><field name="description" nolabel="1"/></group>
|
||||
<separator string="Description"/>
|
||||
<field name="description"/>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
@@ -50,7 +50,8 @@
|
||||
<field name="transferred_kg"/>
|
||||
</group>
|
||||
</group>
|
||||
<group string="Notes"><field name="notes" nolabel="1"/></group>
|
||||
<separator string="Notes"/>
|
||||
<field name="notes"/>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
@@ -35,7 +35,8 @@
|
||||
<field name="active" widget="boolean_toggle"/>
|
||||
</group>
|
||||
</group>
|
||||
<group string="Contact"><field name="contact_info" nolabel="1"/></group>
|
||||
<separator string="Contact"/>
|
||||
<field name="contact_info"/>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user