Sha256: ddfbc4a6db1aac7ac42ae9c5b0a670e08b01533cbc72400584bffae9f48212bc
Contents?: true
Size: 636 Bytes
Versions: 1
Compression:
Stored size: 636 Bytes
Contents
require 'active_support/core_ext/string/inflections' require 'rails_admin/config/fields' module RailsAdmin module Config module Fields module Types @@registry = {} def self.load(type) @@registry[type.to_sym] or raise "Unsupported field datatype: #{type}" end def self.register(type, klass = nil) if klass == nil && type.kind_of?(Class) klass = type type = klass.name.to_s.demodulize.underscore end @@registry[type.to_sym] = klass end require 'rails_admin/config/fields/types/all' end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
elucid-rails_admin-0.0.1 | lib/rails_admin/config/fields/types.rb |