Module: AASM::Generators::OrmHelpers
- Included in:
- ActiveRecord::Generators::AASMGenerator, Mongoid::Generators::AASMGenerator, NoBrainer::Generators::AASMGenerator
- Defined in:
- lib/generators/aasm/orm_helpers.rb
Instance Method Summary collapse
Instance Method Details
#model_contents ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/generators/aasm/orm_helpers.rb', line 5 def model_contents if column_name == 'aasm_state' <<RUBY include AASM aasm do end RUBY else <<RUBY include AASM aasm :column => '#{column_name}' do end RUBY end end |