From 95ec46beac867e1b7df17ba8a72367bbe0b140a9 Mon Sep 17 00:00:00 2001 From: jessib Date: Thu, 28 Mar 2013 11:23:14 -0700 Subject: Let users select amount for payments. --- billing/app/views/payments/new.html.haml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'billing/app/views/payments') diff --git a/billing/app/views/payments/new.html.haml b/billing/app/views/payments/new.html.haml index d9c41ce..1d958b9 100644 --- a/billing/app/views/payments/new.html.haml +++ b/billing/app/views/payments/new.html.haml @@ -1,10 +1,12 @@ %h1 - Payment: $#{h @amount} + Payment - if @result %div{:style => "color: red;"} = h @result.errors.size error(s) -= form_for :transaction, :params => @result && @result.params[:transaction], :errors => @result && @result.errors.for(:transaction), :builder => BraintreeHelper::BraintreeFormBuilder, :url => Braintree::TransparentRedirect.url, :html => {:autocomplete => "off"} do |f| += form_for :transaction, :params => @result && @result.params[:transaction], :errors => @result && @result.errors.for(:transaction), :builder => BraintreeFormHelper::BraintreeFormBuilder, :url => Braintree::TransparentRedirect.url, :html => {:autocomplete => "off"} do |f| #TODO: add helper + = f.label :amount, "Amount" + = f.text_field :amount - if !@customer = render :partial => 'non_customer_fields', :locals => {:f => f} - else -- cgit v1.2.3