Add step_sequence field to bom inputs/outputs
This commit is contained in:
parent
2c90058ec2
commit
c3aac859f8
|
@ -30,10 +30,18 @@ msgctxt "field:production.bom.input,step:"
|
|||
msgid "Step"
|
||||
msgstr "Pas"
|
||||
|
||||
msgctxt "field:production.bom.input,step_sequence:"
|
||||
msgid "Step Sequence"
|
||||
msgstr "Ordre al pas"
|
||||
|
||||
msgctxt "field:production.bom.output,step:"
|
||||
msgid "Step"
|
||||
msgstr "Pas"
|
||||
|
||||
msgctxt "field:production.bom.output,step_sequence:"
|
||||
msgid "Step Sequence"
|
||||
msgstr "Ordre al pas"
|
||||
|
||||
msgctxt "field:production.process,active:"
|
||||
msgid "Active"
|
||||
msgstr "Actiu"
|
||||
|
@ -154,6 +162,10 @@ msgctxt "field:production.route.operation,step:"
|
|||
msgid "Step"
|
||||
msgstr "Pas"
|
||||
|
||||
msgctxt "field:stock.move,production_step:"
|
||||
msgid "Process"
|
||||
msgstr "Procés"
|
||||
|
||||
msgctxt "model:ir.action,name:act_production_process"
|
||||
msgid "Production Process"
|
||||
msgstr "Process de producció"
|
||||
|
@ -174,6 +186,14 @@ msgctxt "model:production.process.step,name:"
|
|||
msgid "Production Process Step"
|
||||
msgstr "Pas de process de producció"
|
||||
|
||||
msgctxt "view:production.bom.input:"
|
||||
msgid "BOM Inputs"
|
||||
msgstr "Entrades de la llista de materials"
|
||||
|
||||
msgctxt "view:production.bom.output:"
|
||||
msgid "BOM Outputs"
|
||||
msgstr "Sortides de la llista de materials"
|
||||
|
||||
msgctxt "view:production.process.step:"
|
||||
msgid "Description"
|
||||
msgstr "Descripció"
|
||||
|
|
|
@ -30,10 +30,18 @@ msgctxt "field:production.bom.input,step:"
|
|||
msgid "Step"
|
||||
msgstr "Paso"
|
||||
|
||||
msgctxt "field:production.bom.input,step_sequence:"
|
||||
msgid "Step Sequence"
|
||||
msgstr "Órden en el paso"
|
||||
|
||||
msgctxt "field:production.bom.output,step:"
|
||||
msgid "Step"
|
||||
msgstr "Paso"
|
||||
|
||||
msgctxt "field:production.bom.output,step_sequence:"
|
||||
msgid "Step Sequence"
|
||||
msgstr "Órden en el paso"
|
||||
|
||||
msgctxt "field:production.process,active:"
|
||||
msgid "Active"
|
||||
msgstr "Activo"
|
||||
|
@ -154,6 +162,10 @@ msgctxt "field:production.route.operation,step:"
|
|||
msgid "Step"
|
||||
msgstr "Paso"
|
||||
|
||||
msgctxt "field:stock.move,production_step:"
|
||||
msgid "Process"
|
||||
msgstr "Proceso"
|
||||
|
||||
msgctxt "model:ir.action,name:act_production_process"
|
||||
msgid "Production Process"
|
||||
msgstr "Proceso de producción"
|
||||
|
@ -174,6 +186,14 @@ msgctxt "model:production.process.step,name:"
|
|||
msgid "Production Process Step"
|
||||
msgstr "Paso de proceso de producción"
|
||||
|
||||
msgctxt "view:production.bom.input:"
|
||||
msgid "BOM Inputs"
|
||||
msgstr "Entradas lista de material"
|
||||
|
||||
msgctxt "view:production.bom.output:"
|
||||
msgid "BOM Outputs"
|
||||
msgstr "Salidas lista de material"
|
||||
|
||||
msgctxt "view:production.process.step:"
|
||||
msgid "Description"
|
||||
msgstr "Descripción"
|
||||
|
|
|
@ -166,8 +166,13 @@ class Step(ModelSQL, ModelView):
|
|||
name = fields.Char('Name', required=True)
|
||||
description = fields.Text('Description')
|
||||
sequence = fields.Integer('Sequence')
|
||||
inputs = fields.One2Many('production.bom.input', 'step', 'Inputs')
|
||||
outputs = fields.One2Many('production.bom.output', 'step', 'Outputs')
|
||||
inputs = fields.One2Many('production.bom.input', 'step', 'Inputs', order=[
|
||||
('step_sequence', 'ASC'),
|
||||
])
|
||||
outputs = fields.One2Many('production.bom.output', 'step', 'Outputs',
|
||||
order=[
|
||||
('step_sequence', 'ASC'),
|
||||
])
|
||||
operations = fields.One2Many('production.route.operation', 'step',
|
||||
'Operations',
|
||||
context={
|
||||
|
@ -220,6 +225,7 @@ class Step(ModelSQL, ModelView):
|
|||
|
||||
class BOMMixin:
|
||||
step = fields.Many2One('production.process.step', 'Step')
|
||||
step_sequence = fields.Integer('Step Sequence')
|
||||
|
||||
@classmethod
|
||||
def create(cls, vlist):
|
||||
|
|
|
@ -83,20 +83,28 @@
|
|||
<field name="perm_delete" eval="True"/>
|
||||
</record>
|
||||
|
||||
|
||||
<!-- bom -->
|
||||
<!-- production -->
|
||||
<record model="ir.ui.view" id="production_view_form">
|
||||
<field name="model">production</field>
|
||||
<field name="type">form</field>
|
||||
<field name="name">production_form</field>
|
||||
<field name="inherit" ref="production.production_view_form"/>
|
||||
</record>
|
||||
|
||||
<!-- production.bom.input -->
|
||||
<record model="ir.ui.view" id="bom_input_view_list">
|
||||
<field name="model">production.bom.input</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="inherit" ref="production.bom_input_view_list"/>
|
||||
<field name="name">bom_input_list</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="bom_input_view_list_sequence">
|
||||
<field name="model">production.bom.input</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="name">bom_input_list_sequence</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="bom_input_view_form">
|
||||
<field name="model">production.bom.input</field>
|
||||
<field name="type">form</field>
|
||||
|
@ -104,12 +112,20 @@
|
|||
<field name="name">bom_input_form</field>
|
||||
</record>
|
||||
|
||||
<!-- production.bom.output -->
|
||||
<record model="ir.ui.view" id="bom_output_view_list">
|
||||
<field name="model">production.bom.output</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="inherit" ref="production.bom_output_view_list"/>
|
||||
<field name="name">bom_output_list</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="bom_output_view_list_sequence">
|
||||
<field name="model">production.bom.output</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="name">bom_output_list_sequence</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="bom_output_view_form">
|
||||
<field name="model">production.bom.output</field>
|
||||
<field name="type">form</field>
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0"?>
|
||||
<!-- The COPYRIGHT file at the top level of this repository contains the full
|
||||
copyright notices and license terms. -->
|
||||
<tree string="BOM Inputs" sequence="step_sequence">
|
||||
<field name="product"/>
|
||||
<field name="quantity"/>
|
||||
<field name="uom"/>
|
||||
</tree>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0"?>
|
||||
<!-- The COPYRIGHT file at the top level of this repository contains the full
|
||||
copyright notices and license terms. -->
|
||||
<tree string="BOM Outputs" sequence="step_sequence">
|
||||
<field name="product"/>
|
||||
<field name="quantity"/>
|
||||
<field name="uom"/>
|
||||
</tree>
|
|
@ -12,8 +12,10 @@
|
|||
<field name="description" colspan="4"/>
|
||||
</page>
|
||||
<page string="Products" id="products">
|
||||
<field name="inputs" colspan="2"/>
|
||||
<field name="outputs" colspan="2"/>
|
||||
<field name="inputs" colspan="2"
|
||||
view_ids="production_process.bom_input_view_list_sequence"/>
|
||||
<field name="outputs" colspan="2"
|
||||
view_ids="production_process.bom_output_view_list_sequence"/>
|
||||
</page>
|
||||
<page string="Operations" id="operations">
|
||||
<field name="operations" colspan="4"/>
|
||||
|
|
Loading…
Reference in New Issue