Skip to content

Commit

Permalink
Add missing form tag and OC and shops injectors on order form to make…
Browse files Browse the repository at this point in the history
… the OC field, the distributor field and the update button work
  • Loading branch information
luisramos0 committed Jan 31, 2019
1 parent 017015b commit 4c3df43
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions app/views/spree/admin/orders/_form.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,17 @@
%legend= Spree.t(:order_total)
%span.order-total= order.display_total
= render partial: 'spree/admin/orders/_form/distribution_fields'
= admin_inject_shops(module: 'admin.orders')
= admin_inject_order_cycles
%div{"ng-app" => "admin.orders", "ng-controller" => "orderCtrl", "ofn-distributor-id" => @order.distributor_id, "ofn-order-cycle-id" => @order.order_cycle_id}
= form_for @order, url: admin_order_url(@order), method: :put do |f|
= render partial: 'spree/admin/orders/_form/distribution_fields'
.filter-actions.actions{"ng-show" => "distributionChosen()"}
= button t(:update_and_recalculate_fees), 'icon-refresh'
%span.or
= t(:or)
= link_to_with_icon 'button icon-arrow-left', t(:back), admin_orders_url
.filter-actions.actions{"ng-show" => "distributionChosen()"}
= button t(:update_and_recalculate_fees), 'icon-refresh'
%span.or
= t(:or)
= link_to_with_icon 'button icon-arrow-left', t(:back), admin_orders_url
= javascript_tag do
var order_number = '#{@order.number}';
Expand Down

0 comments on commit 4c3df43

Please sign in to comment.