At this moment I write enum in model concern:

module Sizeable
  extend ActiveSupport::Concern

  included do
    enum pizza_size: { d22: 22, d33: 33, d38: 38 }
  end
end

Is there some more elegant way to do it with rails 4.1 standard enums? 
Before 4.1 I used EnumerateIt gem for this, but current standard rails 
enums is much cleaner.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/rubyonrails-core.
For more options, visit https://groups.google.com/d/optout.

Reply via email to