mirror of
https://github.com/aasm/aasm
synced 2023-03-27 23:22:41 -04:00
document logger configuration
This commit is contained in:
parent
a26b2f3b03
commit
9ba044af8a
1 changed files with 19 additions and 1 deletions
20
README.md
20
README.md
|
@ -869,6 +869,7 @@ end
|
|||
AASM supports query methods for states and events
|
||||
|
||||
Given the following `Job` class:
|
||||
|
||||
```ruby
|
||||
class Job
|
||||
include AASM
|
||||
|
@ -889,7 +890,7 @@ class Job
|
|||
transitions :from => [:running, :cleaning], :to => :sleeping
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def cleaning_needed?
|
||||
false
|
||||
end
|
||||
|
@ -937,6 +938,23 @@ Job.aasm.states_for_select
|
|||
```
|
||||
|
||||
|
||||
### Warning output
|
||||
|
||||
Warnings are by default printed to `STDERR`. If you want to log those warnings to another output,
|
||||
use
|
||||
|
||||
```ruby
|
||||
class Job
|
||||
include AASM
|
||||
|
||||
aasm :logger => Rails.logger do
|
||||
...
|
||||
end
|
||||
end
|
||||
```
|
||||
|
||||
Be aware though, that this is not yet released. It will be part of _AASM_ version `4.11.0`.
|
||||
|
||||
### RubyMotion support
|
||||
|
||||
Now supports [CodeDataQuery](https://github.com/infinitered/cdq.git) !
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue