From 01aa8cb761c933fc70e7584efeb72217ae3a9099 Mon Sep 17 00:00:00 2001 From: Rafael Schouten Date: Fri, 10 Oct 2014 15:30:53 +1100 Subject: [PATCH] Use serialiser instead of rabl for current order injection --- app/views/checkout/_form.html.haml | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/app/views/checkout/_form.html.haml b/app/views/checkout/_form.html.haml index 52f6f983cc..bcbcb615fc 100644 --- a/app/views/checkout/_form.html.haml +++ b/app/views/checkout/_form.html.haml @@ -6,20 +6,14 @@ = inject_available_shipping_methods = inject_available_payment_methods - :javascript - angular.module('Darkswarm').value('order', #{render "checkout/order"}) + = inject_current_order - %div - / %h3.text-center.pad-top - / Checkout from - / = current_distributor.name - - = render partial: "checkout/details", locals: {f: f} - = render partial: "checkout/billing", locals: {f: f} - = render partial: "checkout/shipping", locals: {f: f} - = render partial: "checkout/payment", locals: {f: f} - %p - %button.button.primary{type: :submit, - "ng-disabled" => "checkout.$invalid"} - Place order now - / {{ checkout.$valid }} + = render partial: "checkout/details", locals: {f: f} + = render partial: "checkout/billing", locals: {f: f} + = render partial: "checkout/shipping", locals: {f: f} + = render partial: "checkout/payment", locals: {f: f} + %p + %button.button.primary{type: :submit, + "ng-disabled" => "checkout.$invalid"} + Place order now + / {{ checkout.$valid }}