Module: AASM::Persistence::MongoMapperPersistence::ClassMethods
- Defined in:
- lib/aasm/persistence/mongo_mapper_persistence.rb
Instance Method Summary collapse
-
#aasm_column(column_name = nil) ⇒ Object
Maps to the aasm_column in the database.
Instance Method Details
#aasm_column(column_name = nil) ⇒ Object
67 68 69 70 71 72 73 74 75 76 77 |
# File 'lib/aasm/persistence/mongo_mapper_persistence.rb', line 67 def aasm_column(column_name=nil) if column_name AASM::StateMachine[self].config.column = column_name.to_sym # @aasm_column = column_name.to_sym else AASM::StateMachine[self].config.column ||= :aasm_state # @aasm_column ||= :aasm_state end # @aasm_column AASM::StateMachine[self].config.column end |