killbill-paypal-express 1.0.10 → 1.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.md CHANGED
@@ -29,7 +29,7 @@ curl -v \
29
29
  "http://$HOST:8080/plugins/killbill-paypal-express/1.0/setup-checkout"
30
30
  ```
31
31
 
32
- Kill Bill will return a 303 See Other on success. The customer should be redirected to the url specified in the Location header, e.g. https://www.paypal.com/cgi-bin/webscr?cmd=_express-checkout&token=EC-20G53990M6953444J.
32
+ Kill Bill will return a 302 Found on success. The customer should be redirected to the url specified in the Location header, e.g. https://www.paypal.com/cgi-bin/webscr?cmd=_express-checkout&token=EC-20G53990M6953444J.
33
33
 
34
34
  Once the customer comes back from the PayPal flow, save the BAID in Kill Bill:
35
35
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.10
1
+ 1.0.11
@@ -4,15 +4,15 @@ Gem::Specification.new do |s|
4
4
  s.name = 'killbill-paypal-express'
5
5
  s.version = version
6
6
  s.summary = 'Plugin to use Express Checkout as a gateway.'
7
- s.description = 'Killbill payment plugin for Paypal Express Checkout.'
7
+ s.description = 'Kill Bill payment plugin for Paypal Express Checkout.'
8
8
 
9
9
  s.required_ruby_version = '>= 1.9.3'
10
10
 
11
11
  s.license = 'Apache License (2.0)'
12
12
 
13
- s.author = 'Killbill core team'
13
+ s.author = 'Kill Bill core team'
14
14
  s.email = 'killbilling-users@googlegroups.com'
15
- s.homepage = 'http://www.killbilling.org'
15
+ s.homepage = 'http://kill-bill.org'
16
16
 
17
17
  s.files = `git ls-files`.split("\n")
18
18
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
@@ -22,7 +22,7 @@ Gem::Specification.new do |s|
22
22
 
23
23
  s.rdoc_options << '--exclude' << '.'
24
24
 
25
- s.add_dependency 'killbill', '~> 1.0.17'
25
+ s.add_dependency 'killbill', '~> 1.0.18'
26
26
  s.add_dependency 'activemerchant', '~> 2.0.0'
27
27
  s.add_dependency 'activerecord', '~> 3.2.1'
28
28
  s.add_dependency 'sinatra', '~> 1.3.4'
@@ -125,7 +125,7 @@ module Killbill::PaypalExpress
125
125
  end
126
126
 
127
127
  def get_payment_methods(kb_account_id, refresh_from_gateway, call_context, options = {})
128
- PaypalExpressPaymentMethod.from_kb_account_id(kb_account_id.to_s).collect { |pm| pm.to_payment_method_response }
128
+ PaypalExpressPaymentMethod.from_kb_account_id(kb_account_id.to_s).collect { |pm| pm.to_payment_method_info_response }
129
129
  end
130
130
 
131
131
  def reset_payment_methods(kb_account_id, payment_methods)
@@ -35,10 +35,21 @@ module Killbill::PaypalExpress
35
35
  external_payment_method_id = paypal_express_baid
36
36
  # No concept of default payment method in Paypal Express
37
37
  is_default = false
38
- # We don't store extra information in Paypal Express
38
+
39
39
  properties = []
40
+ properties << Killbill::Plugin::Model::PaymentMethodKVInfo.new(false, "payerId", paypal_express_payer_id)
41
+ properties << Killbill::Plugin::Model::PaymentMethodKVInfo.new(false, "baid", paypal_express_baid)
42
+ properties << Killbill::Plugin::Model::PaymentMethodKVInfo.new(false, "token", paypal_express_token)
40
43
 
41
44
  Killbill::Plugin::Model::PaymentMethodPlugin.new(external_payment_method_id, is_default, properties, "PayPal", nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil)
42
45
  end
46
+
47
+ def to_payment_method_info_response
48
+ external_payment_method_id = paypal_express_baid
49
+ # No concept of default payment method in Paypal Express
50
+ is_default = false
51
+
52
+ Killbill::Plugin::Model::PaymentMethodInfoPlugin.new(kb_account_id, kb_payment_method_id, is_default, external_payment_method_id)
53
+ end
43
54
  end
44
55
  end
data/pom.xml CHANGED
@@ -25,7 +25,7 @@
25
25
  <groupId>com.ning.killbill.ruby</groupId>
26
26
  <artifactId>paypal-express-plugin</artifactId>
27
27
  <packaging>pom</packaging>
28
- <version>1.0.10</version>
28
+ <version>1.0.11</version>
29
29
  <name>paypal-express-plugin</name>
30
30
  <url>http://github.com/killbill/killbill-paypal-express-plugin</url>
31
31
  <description>Plugin for accessing paypal as a payment gateway</description>
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: killbill-paypal-express
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.10
4
+ version: 1.0.11
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
8
- - Killbill core team
8
+ - Kill Bill core team
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-05-24 00:00:00.000000000 Z
12
+ date: 2013-05-30 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: killbill
@@ -17,13 +17,13 @@ dependencies:
17
17
  requirements:
18
18
  - - "~>"
19
19
  - !ruby/object:Gem::Version
20
- version: 1.0.17
20
+ version: 1.0.18
21
21
  none: false
22
22
  requirement: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 1.0.17
26
+ version: 1.0.18
27
27
  none: false
28
28
  prerelease: false
29
29
  type: :runtime
@@ -155,7 +155,7 @@ dependencies:
155
155
  none: false
156
156
  prerelease: false
157
157
  type: :development
158
- description: Killbill payment plugin for Paypal Express Checkout.
158
+ description: Kill Bill payment plugin for Paypal Express Checkout.
159
159
  email: killbilling-users@googlegroups.com
160
160
  executables: []
161
161
  extensions: []
@@ -189,7 +189,7 @@ files:
189
189
  - spec/paypal_express/base_plugin_spec.rb
190
190
  - spec/paypal_express/remote/integration_spec.rb
191
191
  - spec/spec_helper.rb
192
- homepage: http://www.killbilling.org
192
+ homepage: http://kill-bill.org
193
193
  licenses:
194
194
  - Apache License (2.0)
195
195
  post_install_message: