nicer find_field

This commit is contained in:
simon lehericey 2020-10-30 14:44:42 +01:00 committed by Paul Chavard
parent e5da1d7111
commit f37c27a243

View file

@ -263,7 +263,7 @@ class ProcedurePresentation < ApplicationRecord
end
def find_field(table, column)
fields.find { |c| c['table'] == table && c['column'] == column }
fields.find { |field| field.values_at('table', 'column') == [table, column] }
end
def check_allowed_displayed_fields