Scott Barron
cf2bd90cfb
StateMachine supports adding State
2008-05-31 15:33:17 -07:00
Scott Barron
7dbbc1480b
Add StateMachine object and StateMachineFactory
...
Supports initial state in SM
2008-05-31 15:27:15 -07:00
Scott Barron
28fd460950
Move state for select logic into State
2008-05-31 15:11:18 -07:00
Scott Barron
3ccbeaca88
Support enter and exit actions on states
2008-05-31 15:08:12 -07:00
Scott Barron
2bb30ee84b
Combine event firing logic for ! (persistent) and non-! (non-persistent) event triggers
2008-05-31 14:39:25 -07:00
Scott Barron
fd9c275aa8
remove spurious comment
2008-05-31 14:34:06 -07:00
Scott Barron
d3c49b6e72
Use State objects
2008-05-31 14:33:45 -07:00
Scott Barron
30a8d15ef5
Modify State to prep for enter/entering/exit actions
2008-05-31 14:33:07 -07:00
Scott Barron
0ee1ad986f
coverage for event fired/failed method when using non-! methods
2008-05-30 16:33:27 -07:00
Scott Barron
83bbe4d082
Merge in Jan De Poorter's [DefV] named_scope addition to AR persistence layer, with some organizational clean up.
2008-05-30 14:23:23 -07:00
Scott Barron
270d9e1244
add coverage output to gitignore
2008-05-29 13:28:06 -07:00
Scott Barron
f430051af6
That doesn't work
2008-05-29 13:27:44 -07:00
Scott Barron
f00863cd3d
Make rcov excludes non-osx friendly
2008-05-29 13:25:38 -07:00
Scott Barron
e090e3c59a
Exclude std ruby files from rcov output
2008-05-29 13:24:54 -07:00
Scott Barron
61b5327cc8
Fix AR specs and rcov target
2008-05-29 13:23:53 -07:00
Scott Barron
9e348d718b
Add .find_in_state, .count_in_state, .calculate_in_state back to AR layer
2008-05-29 13:10:31 -07:00
Chad Humphries
5bd5639704
Updating readme
2008-05-29 07:24:01 -07:00
Chad Humphries
0fc6b42ac3
Updated changelog and version
2008-05-29 07:16:45 -07:00
Chad Humphries
34444b7632
Corrected aasm_states_for_select to return state as string for option value.
2008-05-29 07:05:50 -07:00
Edgecase Pair One
fc86784602
Added success callback which takes place after persistent aasm writes
2008-05-20 15:27:35 -04:00
Scott Barron
9e240e70cb
Fix README to reflect github gem installation
...
Fix README instructions for building your own gem
Fix VERSION - not sure why it was set to 3.0.0
2008-04-29 20:51:12 -04:00
Scott Barron
ed1d03fec6
will changing the version make the stupid gem rebuild?
2008-04-29 18:33:54 -04:00
Scott Barron
0f950a6708
some more gemspec changes
2008-04-29 18:32:28 -04:00
Scott Barron
48e660a5fe
Another incompat with rake based gemspec
2008-04-29 18:26:35 -04:00
Scott Barron
6e8351d56c
github criples external querying like Rake's FileList - yucky manual entry
2008-04-29 18:16:25 -04:00
Scott Barron
ee2c18daf0
Adding a gemspec - trying out github's gem hosting
2008-04-29 18:13:38 -04:00
Jeff Dean
482e8d970d
Changed scott's email address to protect it from spambots when publishing rdocs
2008-04-29 02:12:27 -04:00
Jeff Dean
277373b41a
updated docs
2008-04-29 02:08:51 -04:00
Jeff Dean
a0bb1c404c
make sure the 2 fields are in sync by using before_validation_on_create
2008-04-29 01:58:05 -04:00
Jeff Dean
cb6bd4f534
* Specs and bug fixes for the ActiveRecordPersistence, keeping persistence columns in sync
...
Allowing for nil values in states for active record
New non-(!) methods that allow for firing events without persisting [Jeff Dean]
2008-04-29 01:27:56 -04:00
Chad Humphries
c196fef669
Re-exposing options on state, for devious extra uses
2008-04-14 19:49:57 -04:00
Chad Humphries
bd788a5212
Added aasm_states_for_select that will return a select friendly collection of states.
...
Also added additional tests
2008-04-14 15:57:34 -04:00
Scott Barron
ba3b99ff1b
Adding .rdoc to README just to see github's rendering.
2008-03-13 13:10:28 -04:00
Scott Barron
d3f97d2edf
Start beefing up the README for release
2008-03-04 18:59:58 -05:00
Scott Barron
61b6b8ec06
Add two event callbacks:
...
aasm_event_fired(from, to) - called when an event is fired successfully
aasm_event_failed(event) - called when an event fails
These could be used to implement transition logging [Artem Vasiliev] or
setting a timestamp column [Mike Ferrier] as well as other pieces of love and magic.
2008-03-02 07:52:46 -05:00
Scott Barron
29304c70ae
Some specs for #aasm_events_for_current_state
2008-03-02 07:33:37 -05:00
Scott Barron
32156165d4
Add aasm_events_for_state and aasm_events_for_current_state [Joao Paulo Lins]
2008-02-28 08:33:40 -05:00
Scott Barron
bb5f7e00a4
update changelog
2008-02-27 16:31:40 -05:00
Scott Barron
05249c09a3
Fix AR persistence so new records have their state set. [Joao Paulo Lins]
...
Ensure that a state is written for a new record even if aasm_current_state or
{state}= are never called.
2008-02-27 15:32:52 -05:00
Scott Barron
d9300f5abc
Throw a quick blurb in the readme
2008-02-22 18:23:19 -05:00
Scott Barron
10562aeb47
Updated TODO
2008-02-22 15:47:05 -05:00
Scott Barron
ebb36e697d
Some automatic persistence hooks for ActiveRecord objects
2008-02-22 15:46:31 -05:00
Scott Barron
ea7820db4a
More consistent aasm_ namespacing
2008-02-21 12:59:28 -05:00
Scott Barron
551503d12f
Add .aasm_states method to get a list of all states for a class
2008-02-21 12:54:42 -05:00
Scott Barron
543ac695fd
Add AASM::VERSION module and have the gem task use it
2008-02-21 12:37:56 -05:00
Scott Barron
8fc83db605
Further set up for functional tests
2008-02-21 12:32:04 -05:00
Scott Barron
7a734376c4
Reorg spec dir to have units and functionals
2008-02-21 12:18:08 -05:00
Scott Barron
a68200556e
Make #event! methods return a boolean [Joel Chippindale]
2008-02-21 12:11:25 -05:00
Scott Barron
073bcbf695
Throw in a TODO of actions
2008-02-21 12:11:06 -05:00
Scott Barron
85baeda50a
Prepare rakefile and rake tasks for gem packaging and rdocing
2008-02-21 11:41:56 -05:00