1
0
Fork 0
mirror of https://github.com/aasm/aasm synced 2023-03-27 23:22:41 -04:00
aasm/spec/models/active_record/no_scope.rb

22 lines
498 B
Ruby
Raw Normal View History

class NoScope < ActiveRecord::Base
include AASM
aasm :create_scopes => false do
state :pending, :initial => true
state :running
event :run do
transitions :from => :pending, :to => :running
end
end
end
2015-07-01 07:41:44 -04:00
class MultipleNoScope < ActiveRecord::Base
include AASM
aasm :left, :column => :aasm_state, :create_scopes => false do
2015-07-01 07:41:44 -04:00
state :pending, :initial => true
state :running
event :run do
transitions :from => :pending, :to => :running
end
end
end