stateflow 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG.rdoc CHANGED
@@ -1,3 +1,6 @@
1
+ = Version 0.2.1
2
+ * Reverted the writes back to update_attributes
3
+
1
4
  = Version 0.2
2
5
  * Added a transition to any event, please look at the tests to understand how it works - Thanks to nu7hatch for the patch!
3
6
  * Changed the persistence layers to use write_attribute, instead of update_attribute - Thanks to achirkunov
data/Rakefile CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
2
2
  require 'rake'
3
3
  require 'echoe'
4
4
 
5
- Echoe.new('stateflow', '0.2.0') do |p|
5
+ Echoe.new('stateflow', '0.2.1') do |p|
6
6
  p.description = "State machine that allows dynamic transitions for business workflows"
7
7
  p.url = "http://github.com/ryanza/stateflow"
8
8
  p.author = "Ryan Oberholzer"
@@ -12,8 +12,7 @@ module Stateflow
12
12
  end
13
13
 
14
14
  def save_to_persistence(new_state)
15
- self.write_attribute(machine.state_column.to_sym, new_state)
16
- self.save
15
+ self.update_attribute(machine.state_column.to_sym, new_state)
17
16
  end
18
17
 
19
18
  def ensure_initial_state
@@ -12,8 +12,7 @@ module Stateflow
12
12
  end
13
13
 
14
14
  def save_to_persistence(new_state)
15
- self.write_attribute(machine.state_column.to_sym, new_state)
16
- self.save
15
+ self.update_attributes(machine.state_column.to_sym => new_state)
17
16
  end
18
17
 
19
18
  def ensure_initial_state
@@ -12,8 +12,7 @@ module Stateflow
12
12
  end
13
13
 
14
14
  def save_to_persistence(new_state)
15
- self.write_attribute(machine.state_column.to_sym, new_state)
16
- self.save
15
+ self.update_attributes(machine.state_column.to_sym => new_state)
17
16
  end
18
17
 
19
18
  def ensure_initial_state
data/stateflow.gemspec CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{stateflow}
5
- s.version = "0.2.0"
5
+ s.version = "0.2.1"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Ryan Oberholzer"]
9
- s.date = %q{2010-09-22}
9
+ s.date = %q{2010-10-01}
10
10
  s.description = %q{State machine that allows dynamic transitions for business workflows}
11
11
  s.email = %q{ryan@platform45.com}
12
12
  s.extra_rdoc_files = ["CHANGELOG.rdoc", "README.rdoc", "lib/stateflow.rb", "lib/stateflow/event.rb", "lib/stateflow/exception.rb", "lib/stateflow/machine.rb", "lib/stateflow/persistence.rb", "lib/stateflow/persistence/active_record.rb", "lib/stateflow/persistence/mongo_mapper.rb", "lib/stateflow/persistence/mongoid.rb", "lib/stateflow/persistence/none.rb", "lib/stateflow/state.rb", "lib/stateflow/transition.rb"]
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stateflow
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 0
10
- version: 0.2.0
9
+ - 1
10
+ version: 0.2.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Ryan Oberholzer
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-09-22 00:00:00 +02:00
18
+ date: 2010-10-01 00:00:00 +02:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency