Sha256: bb3e07785fad98c082701c638db31b54de01662b4a983cb0178bc7beb553ee11
Contents?: true
Size: 925 Bytes
Versions: 1
Compression:
Stored size: 925 Bytes
Contents
# Intialize the gem by including some extension to ActiveRecord::Base require File.dirname(__FILE__) + '/has_setting/ar_extensions' require File.dirname(__FILE__) + '/has_setting/formatters' require File.dirname(__FILE__) + '/has_setting/setting' ActiveRecord::Base.class_eval do include(HasSetting::InstanceMethods) extend(HasSetting::ClassMethods) end HasSetting::Formatters.register_formatter(:string, HasSetting::Formatters::StringFormatter.new) HasSetting::Formatters.register_formatter(:strings, HasSetting::Formatters::StringsFormatter.new) HasSetting::Formatters.register_formatter(:float, HasSetting::Formatters::FloatFormatter.new) HasSetting::Formatters.register_formatter(:floats, HasSetting::Formatters::FloatFormatter.new) HasSetting::Formatters.register_formatter(:int, HasSetting::Formatters::IntFormatter.new) HasSetting::Formatters.register_formatter(:ints, HasSetting::Formatters::IntsFormatter.new)
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
simplificator-has_setting-0.3.9 | lib/has_setting.rb |