Revision 12cc808b
Added by Dmitri Dolguikh over 10 years ago
lib/core_extensions.rb | ||
---|---|---|
def id_and_type
|
||
"#{id}-#{self.class.table_name.humanize}"
|
||
end
|
||
alias_attribute :to_label, :name
|
||
alias_attribute :to_label, :name_method
|
||
alias_attribute :to_s, :to_label
|
||
|
||
def self.unconfigured?
|
Also available in: Unified diff
fixes #4161: plugin ActiveRecord models that do no define 'name' method no longer throw NoMethodError when to_s is called