Cleanup stripe stuff
This commit is contained in:
parent
00c8903968
commit
9355114960
2 changed files with 9 additions and 11 deletions
|
|
@ -20,15 +20,13 @@
|
||||||
= humanized_money_with_symbol ticket.quantity * ticket.price
|
= humanized_money_with_symbol ticket.quantity * ticket.price
|
||||||
|
|
||||||
= form_tag conference_payments_path do
|
= form_tag conference_payments_path do
|
||||||
%script.stripe-button{ src: "https://checkout.stripe.com/checkout.js",
|
%script.stripe-button{'src': "https://checkout.stripe.com/checkout.js",
|
||||||
data: {
|
'data': {amount: @total_amount_to_pay.cents,
|
||||||
amount: @total_amount_to_pay.cents,
|
label: "Pay #{humanized_money_with_symbol @total_amount_to_pay}",
|
||||||
label: "Pay #{humanized_money_with_symbol @total_amount_to_pay}",
|
email: current_user.email,
|
||||||
email: current_user.email,
|
currency: @total_amount_to_pay.currency,
|
||||||
currency: @total_amount_to_pay.currency,
|
name: ENV['OSEM_NAME'] || 'OSEM',
|
||||||
name: ENV['OSEM_NAME'] || 'OSEM',
|
description: "#{ENV['OSEM_NAME']} tickets",
|
||||||
description: "#{OSEM_NAME} tickets",
|
key: ENV['STRIPE_PUBLISHABLE_KEY'] || Rails.application.secrets.stripe_publishable_key, locale: "auto"}}
|
||||||
key: ENV['STRIPE_PUBLISHABLE_KEY'] || Rails.application.secrets.stripe_publishable_key, locale: "auto"
|
|
||||||
}}
|
|
||||||
= link_to('Edit Purchase', conference_tickets_path(@conference.short_title),
|
= link_to('Edit Purchase', conference_tickets_path(@conference.short_title),
|
||||||
class: 'btn btn-default')
|
class: 'btn btn-default')
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
Stripe.api_key = Rails.application.secrets.stripe_secret_key
|
Stripe.api_key = ENV['STRIPE_SECRET_KEY'] || Rails.application.secrets.stripe_secret_key
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue