mirror of
https://github.com/aasm/aasm
synced 2023-03-27 23:22:41 -04:00
add aasm_column to examples
This commit is contained in:
parent
ef0eb25715
commit
5737182e2b
1 changed files with 4 additions and 0 deletions
|
@ -66,6 +66,8 @@ Here's a quick example highlighting some of the features.
|
|||
class Conversation
|
||||
include AASM
|
||||
|
||||
aasm_column :current_state # defaults to aasm_state
|
||||
|
||||
aasm_initial_state :unread
|
||||
|
||||
aasm_state :unread
|
||||
|
@ -88,6 +90,8 @@ This example uses a few of the more complex features available.
|
|||
|
||||
class Relationship
|
||||
include AASM
|
||||
|
||||
aasm_column :status
|
||||
|
||||
aasm_initial_state Proc.new { |relationship| relationship.strictly_for_fun? ? :intimate : :dating }
|
||||
|
||||
|
|
Loading…
Reference in a new issue