add procedure_id to column.id

This commit is contained in:
simon lehericey 2024-10-07 21:46:59 +02:00
parent 3c7521a428
commit 3740a79219
No known key found for this signature in database
GPG key ID: CDE670D827C7B3C5
14 changed files with 65 additions and 49 deletions

View file

@ -5,7 +5,8 @@ class Column
attr_reader :table, :column, :label, :classname, :type, :scope, :value_column, :filterable, :displayable
def initialize(table:, column:, label: nil, type: :text, value_column: :value, filterable: true, displayable: true, classname: '', scope: '')
def initialize(procedure_id:, table:, column:, label: nil, type: :text, value_column: :value, filterable: true, displayable: true, classname: '', scope: '')
@procedure_id = procedure_id
@table = table
@column = column
@label = label || I18n.t(column, scope: [:activerecord, :attributes, :procedure_presentation, :fields, table])