correction to module products
This commit is contained in:
parent
40204302f4
commit
8fad2a7cf3
28
locale/es.po
28
locale/es.po
@ -16,7 +16,7 @@ msgstr "Medidas del Equipo"
|
||||
|
||||
msgctxt "view:product.template:"
|
||||
msgid "Enviromental Conditions"
|
||||
msgstr "Condciones Ambientales"
|
||||
msgstr "Condciones Ambientales de Trabajo"
|
||||
|
||||
msgctxt "view:product.template:"
|
||||
msgid "Electrical Conditions"
|
||||
@ -82,13 +82,21 @@ msgctxt "field:product.template,origin_country:"
|
||||
msgid "Origin Country"
|
||||
msgstr "País de origen"
|
||||
|
||||
msgctxt "field:product.template,temperature:"
|
||||
msgid "Temperature"
|
||||
msgstr "Temperatura"
|
||||
msgctxt "field:product.template,temperature_min:"
|
||||
msgid "Temp Min"
|
||||
msgstr "Temp Min"
|
||||
|
||||
msgctxt "field:product.template,moisture:"
|
||||
msgid "Moisture"
|
||||
msgstr "Humedad"
|
||||
msgctxt "field:product.template,temperature_max:"
|
||||
msgid "Temp Max"
|
||||
msgstr "Temp Max"
|
||||
|
||||
msgctxt "field:product.template,moisture_min:"
|
||||
msgid "Moisture Min"
|
||||
msgstr "Humedad Min"
|
||||
|
||||
msgctxt "field:product.template,moisture_max:"
|
||||
msgid "Moisture Max"
|
||||
msgstr "Humedad Max"
|
||||
|
||||
msgctxt "field:product.template,frequency:"
|
||||
msgid "Frequency"
|
||||
@ -112,12 +120,16 @@ msgstr "Garantía"
|
||||
|
||||
msgctxt "field:product.template,uncertainy_pattern:"
|
||||
msgid "Uncertainy Pattern"
|
||||
msgstr "Patrón de Incertidumbre"
|
||||
msgstr "Incertidumbre Patrón"
|
||||
|
||||
msgctxt "field:product.template,k_pattern:"
|
||||
msgid "K Pattern"
|
||||
msgstr "Patrón K"
|
||||
|
||||
msgctxt "field:product.template,resolution_type:"
|
||||
msgid "Resolution Type"
|
||||
msgstr "Tipo de Resolución"
|
||||
|
||||
msgctxt "field:product.template,d_resolution:"
|
||||
msgid "Resolution d"
|
||||
msgstr "Resolución (d)"
|
||||
|
37
product.py
37
product.py
@ -7,7 +7,7 @@ from trytond.pyson import Bool, If, Eval, Id
|
||||
from trytond.exceptions import UserError
|
||||
|
||||
|
||||
_RISK = [('', ""),
|
||||
_RISK = [('N/A', "No aplíca"),
|
||||
('uno', 'I'),
|
||||
('dosA', 'IIA'),
|
||||
('dosB', 'IIB')]
|
||||
@ -18,7 +18,7 @@ _USE = [('', ""),
|
||||
('apoyo', 'Apoyo')]
|
||||
|
||||
_BIOMEDICAL_CLASS = [
|
||||
('', ""),
|
||||
('N/A', "No aplíca"),
|
||||
('diagnostico', 'Diagnóstico'),
|
||||
('rehabilitación', 'Rehabilitación')]
|
||||
|
||||
@ -96,17 +96,18 @@ class Template(metaclass=PoolMeta):
|
||||
)
|
||||
origin_country = fields.Many2One('country.country',"Origin Country")
|
||||
refurbish = fields.Boolean('Refurbish')
|
||||
software_version = fields.Char("Software version")
|
||||
|
||||
#These are measurements required for the equipments, are in this place
|
||||
# for manage of class 'product.template'
|
||||
|
||||
|
||||
temperature_init = fields.Float("Ti")
|
||||
temperature_end = fields.Float("Tf")
|
||||
temperature_min = fields.Float("Temp Min")
|
||||
temperature_max = fields.Float("Temp Max")
|
||||
temperature_uom = fields.Many2One('product.uom', 'Temperature UOM',
|
||||
domain=[('category', '=', Id('optical_equipment', "uom_cat_temperature"))],
|
||||
states={'invisible' : If(Eval('temperature_init') == None, True)},
|
||||
depends=['itemperature_init']
|
||||
states={'invisible' : If(Eval('temperature_min') == None, True)},
|
||||
depends=['itemperature_min']
|
||||
)
|
||||
frequency = fields.Float("Frequency")
|
||||
frequency_uom = fields.Many2One('product.uom', "Frequency UOM",
|
||||
@ -114,12 +115,12 @@ class Template(metaclass=PoolMeta):
|
||||
states={'invisible' : If(Eval('frequency') == None, True)},
|
||||
depends=['frequency']
|
||||
)
|
||||
moisture_init = fields.Float("Mi")
|
||||
moisture_end = fields.Float("Mf")
|
||||
moisture_min = fields.Float("Moisture Min")
|
||||
moisture_max = fields.Float("Moisture Max")
|
||||
moisture_uom = fields.Many2One('product.uom', "Moisture UOM",
|
||||
domain=[('category', '=', Id('optical_equipment', 'uom_cat_relative_humedity'))],
|
||||
states={'invisible' : If(Eval('moisture_init') == None, True)},
|
||||
depends=['moisture_init']
|
||||
states={'invisible' : If(Eval('moisture_min') == None, True)},
|
||||
depends=['moisture_min']
|
||||
)
|
||||
electrical_equipment = fields.Boolean("Electrical Equipment")
|
||||
frequency = fields.Float("Frequency",
|
||||
@ -148,12 +149,22 @@ class Template(metaclass=PoolMeta):
|
||||
|
||||
#### calibration parameters
|
||||
|
||||
uncertainy_pattern = fields.Char("Uncertainy Pattern",
|
||||
uncertainy_pattern = fields.Float("Uncertainy Pattern",
|
||||
help="Agregar valores separados por ',' Ej:-5,+5,-10,+10")
|
||||
k_pattern = fields.Char("K Pattern",
|
||||
help="Agregar valores separados por ',' Ej:-5,+5,-10,+10")
|
||||
d_resolution = fields.Integer("Resolution d")
|
||||
analog_resolution = fields.Integer("Analog resolution")
|
||||
|
||||
resolution_type = fields.Selection([('',""),
|
||||
('analoga', "Analoga"),
|
||||
('digital', "Digital")], "Resolution Type", required=True,
|
||||
states={'required': Eval('calibration', False)},
|
||||
depends=['calibration'])
|
||||
d_resolution = fields.Float("Resolution d",
|
||||
states={'invisible': If(Eval('resolution_type') != 'digital', True)},
|
||||
depends=['resolution_type'])
|
||||
analog_resolution = fields.Float("Analog resolution",
|
||||
states={'invisible': If(Eval('resolution_type') != 'analoga', True)},
|
||||
depends=['resolution_type'])
|
||||
Usubi = fields.Integer("Usub i")
|
||||
|
||||
@classmethod
|
||||
|
@ -85,6 +85,7 @@ class Line(metaclass=PoolMeta):
|
||||
software_version = fields.Char("Software version")
|
||||
health_register = fields.Char("Registro Medico")
|
||||
|
||||
|
||||
@classmethod
|
||||
def default_address_equipment(cls):
|
||||
pool = Pool()
|
||||
|
@ -33,6 +33,8 @@ this repository contains the full copyright notices and license terms. -->
|
||||
<field name="origin_country"/>
|
||||
<label name="main_tecnology"/>
|
||||
<field name="main_tecnology"/>
|
||||
<label name="software_version"/>
|
||||
<field name="software_version"/>
|
||||
<label name="useful_life"/>
|
||||
<field name="useful_life"/>
|
||||
<label name="warranty"/>
|
||||
@ -54,6 +56,9 @@ this repository contains the full copyright notices and license terms. -->
|
||||
<label name="k_pattern"/>
|
||||
<field name="k_pattern"/>
|
||||
<newline/>
|
||||
<label name="resolution_type"/>
|
||||
<field name="resolution_type"/>
|
||||
<newline/>
|
||||
<label name="d_resolution"/>
|
||||
<field name="d_resolution"/>
|
||||
<newline/>
|
||||
@ -69,20 +74,20 @@ this repository contains the full copyright notices and license terms. -->
|
||||
</xpath>
|
||||
<xpath
|
||||
expr="/form/notebook/page[@id='measurements']" position="inside">
|
||||
<separator id="enviromental_conditions" string="Enviromental Conditions" colspan="4"/>
|
||||
<separator id="enviromental_working_conditions" string="Enviromental Working Conditions" colspan="4"/>
|
||||
|
||||
<label name="temperature_init"/>
|
||||
<field name="temperature_init"/>
|
||||
<label name="temperature_min"/>
|
||||
<field name="temperature_min"/>
|
||||
<newline/>
|
||||
<label name="temperature_end"/>
|
||||
<field name="temperature_end"/>
|
||||
<label name="temperature_max"/>
|
||||
<field name="temperature_max"/>
|
||||
<field name="temperature_uom"/>
|
||||
<newline/>
|
||||
<label name="moisture_init"/>
|
||||
<field name="moisture_init"/>
|
||||
<label name="moisture_min"/>
|
||||
<field name="moisture_min"/>
|
||||
<newline/>
|
||||
<label name="moisture_end"/>
|
||||
<field name="moisture_end"/>
|
||||
<label name="moisture_max"/>
|
||||
<field name="moisture_max"/>
|
||||
<field name="moisture_uom"/>
|
||||
|
||||
<separator id="electrical_conditions" string="Electrical Conditions" colspan="4"/>
|
||||
|
Loading…
Reference in New Issue
Block a user