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

Commit

Permalink
Merge pull request #18 from solidusio/add/source_view
Browse files Browse the repository at this point in the history
Add Source View
  • Loading branch information
cbrunsdon authored Sep 12, 2016
2 parents 36e7955 + 6df33b5 commit aa3920d
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 4 deletions.
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

0 comments on commit aa3920d

Please sign in to comment.