mirror of
https://github.com/aasm/aasm
synced 2023-03-27 23:22:41 -04:00
13 lines
208 B
Ruby
13 lines
208 B
Ruby
class TimestampsWithNamedMachineExample
|
|
include AASM
|
|
|
|
attr_accessor :opened_at
|
|
|
|
aasm :my_state, timestamps: true do
|
|
state :opened
|
|
|
|
event :open do
|
|
transitions to: :opened
|
|
end
|
|
end
|
|
end
|