Skip to content
This repository has been archived by the owner on Apr 14, 2023. It is now read-only.

Add Source View #18

Merged
merged 2 commits into from
Sep 12, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions app/models/solidus_paypal_braintree/gateway.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ class Gateway < ::Spree::PaymentMethod
preference(:public_key, :string, default: nil)
preference(:private_key, :string, default: nil)

def method_type
"paypal_braintree"
end

def payment_source_class
Source
end
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<fieldset data-hook="credit_card">
<div class="row">
<div class="alpha six columns">
<dl>
<dt><%= Spree.t(:identifier) %>:</dt>
<dd><%= payment.number %></dd>

<dt><%= t('solidus_paypal_braintree.nonce') %>:</dt>
<dd><%= payment.source.nonce %></dd>

<dt><%= Spree.t(:response_code) %>:</dt>
<dd><%= payment.response_code %></dd>
</dl>
</div>
</div>
</fieldset>
6 changes: 2 additions & 4 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# Sample localization file for English. Add more files in this directory for other locales.
# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.

en:
hello: Hello world
solidus_paypal_braintree:
nonce: Nonce