Sha256: b7c49f95fc237e4c11854b16383d0ee32184f85778abf48b37934ae4cd036ca1
Contents?: true
Size: 495 Bytes
Versions: 1
Compression:
Stored size: 495 Bytes
Contents
module Detour::Concerns module CustomHumanAttributes extend ActiveSupport::Concern included do @human_attribute_names = {} class << self alias :original_human_attribute_name :human_attribute_name end def self.human_attribute_name(*args) @human_attribute_names[args[0]] || original_human_attribute_name(*args) end def self.set_human_attribute_name(key, name) @human_attribute_names[key] = name end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
detour-0.0.15 | app/models/detour/concerns/custom_human_attributes.rb |