Module: MongoMapper::EdgeStateMachine::ClassMethods
- Defined in:
- lib/mongo_mapper/edge-state-machine.rb
Instance Method Summary collapse
Instance Method Details
#add_scope(state, machine_name) ⇒ Object
73 74 75 76 |
# File 'lib/mongo_mapper/edge-state-machine.rb', line 73 def add_scope(state, machine_name) machine = state_machines[machine_name] scope state.name, where(machine.persisted_variable_name.to_sym => state.name.to_s) end |