Sha256: 58085163a6d7481aa4a277ff1225a3a2c779b665c17b854b32b4c9a27ba88e50
Contents?: true
Size: 316 Bytes
Versions: 14
Compression:
Stored size: 316 Bytes
Contents
module ActiveMetadata::ValueFormatter extend ActiveSupport::Concern def value instance = model_class.constantize.new return read_attribute(:value).to_s unless instance.respond_to?(label.to_sym) instance.send :write_attribute, label.to_sym, read_attribute(:value) instance.send label end end
Version data entries
14 entries across 14 versions & 1 rubygems