lims_report_html: add fields to list of samples pending reporting
This commit is contained in:
parent
74095c6fdd
commit
cd49bc54c1
|
@ -7,6 +7,7 @@ from . import action
|
|||
from . import html_template
|
||||
from . import sample
|
||||
from . import results_report
|
||||
from . import notebook
|
||||
|
||||
|
||||
def register():
|
||||
|
@ -17,6 +18,7 @@ def register():
|
|||
sample.Sample,
|
||||
sample.CreateSampleStart,
|
||||
results_report.ResultsReportVersionDetail,
|
||||
notebook.Notebook,
|
||||
module='lims_report_html', type_='model')
|
||||
Pool.register(
|
||||
action.ReportTranslationSet,
|
||||
|
|
|
@ -10,6 +10,14 @@ msgctxt "field:lims.create_sample.start,resultrange_origin:"
|
|||
msgid "Comparison range"
|
||||
msgstr "Rango de comparación"
|
||||
|
||||
msgctxt "field:lims.notebook,result_template:"
|
||||
msgid "Report Template"
|
||||
msgstr "Plantilla de Informe"
|
||||
|
||||
msgctxt "field:lims.notebook,resultrange_origin:"
|
||||
msgid "Comparison range"
|
||||
msgstr "Rango de comparación"
|
||||
|
||||
msgctxt "field:lims.result_report.template,content:"
|
||||
msgid "Content"
|
||||
msgstr "Contenido"
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
# This file is part of lims_report_html module for Tryton.
|
||||
# The COPYRIGHT file at the top level of this repository contains
|
||||
# the full copyright notices and license terms.
|
||||
|
||||
from trytond.model import fields
|
||||
from trytond.pool import PoolMeta
|
||||
|
||||
__all__ = ['Notebook']
|
||||
|
||||
|
||||
class Notebook(metaclass=PoolMeta):
|
||||
__name__ = 'lims.notebook'
|
||||
|
||||
result_template = fields.Function(fields.Many2One(
|
||||
'lims.result_report.template', 'Report Template'), 'get_sample_field')
|
||||
resultrange_origin = fields.Function(fields.Many2One('lims.range.type',
|
||||
'Comparison range'), 'get_sample_field')
|
|
@ -18,5 +18,18 @@
|
|||
<field name="name">create_sample_start_form</field>
|
||||
</record>
|
||||
|
||||
<!-- Samples Pending Reporting -->
|
||||
|
||||
<record model="ir.ui.view" id="samples_pending_reporting_view_list">
|
||||
<field name="model">lims.notebook</field>
|
||||
<field name="inherit" ref="lims.lims_samples_pending_reporting_view_list"/>
|
||||
<field name="name">samples_pending_reporting_list</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="samples_pending_reporting_view_form">
|
||||
<field name="model">lims.notebook</field>
|
||||
<field name="inherit" ref="lims.lims_samples_pending_reporting_view_form"/>
|
||||
<field name="name">samples_pending_reporting_form</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</tryton>
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0"?>
|
||||
<data>
|
||||
<xpath expr="/form/field[@name='department']" position="after">
|
||||
<label name="result_template"/>
|
||||
<field name="result_template"/>
|
||||
<label name="resultrange_origin"/>
|
||||
<field name="resultrange_origin"/>
|
||||
</xpath>
|
||||
</data>
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0"?>
|
||||
<data>
|
||||
<xpath expr="/tree/field[@name='department']" position="after">
|
||||
<field name="result_template"/>
|
||||
</xpath>
|
||||
</data>
|
Loading…
Reference in New Issue