| Issue 108: | Entering a faulty shipping address after it has a saved pre-existing billing addresses causes a 500 | |
| 2 people starred this issue and may be notified of changes. | Back to list |
What steps will reproduce the problem?
1. create an order
2. do checkout, enter [only] a billing address
3. use back button on your browser
now enter a faulty shipping address.
What is the expected output? What do you see instead?
Should show errors for the shipping address fields.
Shows a 500.
What version of the product are you using? On what operating system?
1.0a3
Appears that adding to update_orders_from post method the 'save!' method [thus]
...
if @billing_address == @shipping_address || @shipping_address.nil?
@shipping_address =
@order_user.order_addresses.create(params[:shipping_address])
@shipping_address.save! # raise some errors
@order.shipping_address_id = @shipping_address.id
result = @order.save! # add this line
logger.info "results was #{result} from #{@order.inspect}"
else
...
overcomes it.
Sorry it's not a real patch :)
Thanks!
Aug 15, 2008
Project Member
#1
subim...@gmail.com
Status:
Accepted
Aug 28, 2008
(No comment was entered for this change.)
Labels:
-Priority-Medium Priority-High
Dec 16, 2008
so that's to app\controllers\order_helper.rb add the line @shipping_address.save! [near the end]. (This still occurs currently.) Thanks so much! |