mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Fixing some regressions to data submission
This commit is contained in:
@@ -25,10 +25,10 @@ Darkswarm.factory 'Checkout', (CurrentOrder, ShippingMethods, PaymentMethods, $h
|
||||
munged_order["ship_address_attributes"] = value
|
||||
when "payment_method_id"
|
||||
munged_order["payments_attributes"] = [{payment_method_id: value}]
|
||||
|
||||
when "form_state" # don't keep this shit
|
||||
else
|
||||
when "shipping_method_id", "payment_method_id", "email"
|
||||
munged_order[name] = value
|
||||
else
|
||||
# Ignore everything else
|
||||
|
||||
if @ship_address_same_as_billing
|
||||
munged_order.ship_address_attributes = munged_order.bill_address_attributes
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
"ng-model" => "order.payment_method_id"
|
||||
= method.name
|
||||
|
||||
.row{"ng-if" => "order.payment_method_id == method.id"}
|
||||
.row{"ng-show" => "order.payment_method_id == #{method.id}"}
|
||||
.small-12.columns
|
||||
= render partial: "spree/checkout/payment/#{method.method_type}", :locals => { :payment_method => method }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user