Skip to content

Commit

Permalink
Add delivery step back in
Browse files Browse the repository at this point in the history
  • Loading branch information
nateberkopec committed Mar 14, 2013
1 parent e27e22b commit 4c9df89
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion core/app/models/order.rb
Expand Up @@ -83,8 +83,10 @@ def item_count

event :next do
transition :from => 'cart', :to => 'address'
transition :from => 'address', :to => 'delivery', :if => :delivery_required?
transition :from => 'address', :to => 'payment'
transition :from => 'payment', :to => 'complete'
transition :from => 'delivery', :to => 'payment'
transition :from => 'payment', :to => 'complete'
end

event :cancel do
Expand Down Expand Up @@ -167,6 +169,10 @@ def restore_state

end

def delivery_required?
false
end

before_validation :clone_billing_address, :if => "@use_billing"
attr_accessor :use_billing

Expand Down

0 comments on commit 4c9df89

Please sign in to comment.