How to make transfers in Rails 3?

In Rails 2, I know several plugins for enums, such as act_as_enumeration and enumerate_by, but they do not seem to be supported or updated for Rails 3. Preferably, the solution would store the enumeration in memory, not a database for performance, but really any method was would be useful since it can always be cached.

I found an enumerated_attribute that claims to work with Rails 3, but to be honest, I don't like the API and was hoping for another good solution.

(Sorry for linking to only one plugin, but it will not allow me to send more than one link until I get a higher reputation)

+7
ruby-on-rails-3
source share
3 answers

I am currently using lwe simple_enum , which seems to be actively developing and storing values ​​in memory or if you prefer them in a table.

+5
source share

If you are using DataMapper, since your ORM is looking at dm-types , which includes an Enum type.

0
source share

There is this stone, enumerate_it , it has good documentation and is very well made!

0
source share

All Articles