lims_analysis_sheet_stock: improves interface function

This commit is contained in:
Adrián Bernardi 2021-02-09 11:50:46 -03:00
parent 3a398c4b08
commit 78b55ab689
1 changed files with 3 additions and 1 deletions

View File

@ -20,7 +20,9 @@ def get_m2o_field(m2o_field, m2o_name, field_name, dict_key=None):
table_id = Transaction().context.get('lims_interface_table')
column = Field.search([
('table', '=', table_id),
('name', '=', m2o_name),
['OR', ('name', '=', m2o_name),
('name', 'like', m2o_name + "\_%"),
],
('related_model', '!=', None),
])
if not column: