1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-11 22:24:21 +01:00
fab-manager/app/models/history_value.rb
2023-03-24 17:21:44 +01:00

18 lines
410 B
Ruby

# frozen_string_literal: true
# Setting values, kept history of modifications
class HistoryValue < Footprintable
belongs_to :setting
belongs_to :invoicing_profile
has_one :chained_element, as: :element, dependent: :restrict_with_exception
delegate :footprint, to: :chained_element
delegate :user, to: :invoicing_profile
after_create :chain_record
def sort_on_field
'created_at'
end
end