我已从我的 spree 应用程序中删除了地址和交货状态并将其设置为:
Spree::Order.class_eval do
checkout_flow do
go_to_state :payment, :if => lambda { |order| order.payment_required? }
go_to_state :confirm, :if => lambda { |order| order.confirmation_required? }
go_to_state :complete
remove_transition :from => :payment, :to => :confirm
end
end
我删除它是因为目前我的雇主只想做店内取货。现在,如果用户已登录,这非常有用,那么我不会收到任何错误,但是如果我尝试进行访客结帐(我的雇主想要),我会收到此错误:
2 errors prohibited this record from being saved:
There were problems with the following fields:
State is invalid
State is invalid
现在我是狂欢的新手,所以如果这是一个愚蠢的问题,请原谅我,但是地址和/或交付中的什么会搞砸客人结帐不起作用?