mongoid-active_merchant 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 91eb6bac01cd717d42d0ad309b8631f78f6625dc
4
- data.tar.gz: f3fadc7ca6a13ca139bdcf88e9813c17a1b0de3c
3
+ metadata.gz: de769026ef1bf94a9adac6638ae8e23fba3eee6d
4
+ data.tar.gz: 865ae7774a5a26ea08d1e76151c6a0a41d046cee
5
5
  SHA512:
6
- metadata.gz: f694dedb104917b047845b3397f78d8c0a10bf2c0ef13f63ac4a2b69a6f69e502437c8bd7cc56be73ee8b7d64fcd10b0c0d2994fcd44e820e81ad6d105f807b9
7
- data.tar.gz: 54d141d7cade1fdcba50de7918f488bf724f0c025d62ac788fe400c555a43696fe65b1ef419c968c789437807c735e025556edc7ae241ede313fcd10659fb346
6
+ metadata.gz: 389b13c436d904625775d3cc82d0a1a7e2d0f163c5e93cc72bdf06447af5bfa25b3a4148fb15f739571d8cd1c342133b7452fa2488cdd59e08023a60e546284b
7
+ data.tar.gz: 982449e2dab3180bcd7e34d7cbf826eb1f695bff6fa084abff8bab609993853dc4e88731a447ec36342b50368044d07c446ec330b4447b0a104100ca12cc8989
data/README.md CHANGED
@@ -42,6 +42,10 @@ payment.response = response
42
42
  payment.save!
43
43
  ```
44
44
 
45
+ ### Note
46
+
47
+ Querying by an ActiveMerchant::Billing::Response is not supported at this time.
48
+
45
49
  ## Development
46
50
 
47
51
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -10,7 +10,7 @@ module ActiveMerchant
10
10
  :avs_result
11
11
  ]
12
12
 
13
- def mongoize
13
+ def as_json
14
14
  options = ATTRIBUTES_FOR_MONGOID_OPTIONS_SERIALIZATION.reduce({}) do |result, attr|
15
15
  value = instance_variable_get(:"@#{attr}")
16
16
  result[attr.to_s] = value unless value.nil?
@@ -28,6 +28,11 @@ module ActiveMerchant
28
28
  'options' => options
29
29
  }
30
30
  end
31
+ alias_method :mongoize, :as_json
32
+
33
+ def to_json
34
+ as_json.to_json
35
+ end
31
36
 
32
37
  class << self
33
38
  def demongoize(object)
@@ -1,5 +1,5 @@
1
1
  module Mongoid
2
2
  module ActiveMerchant
3
- VERSION = '0.1.1'
3
+ VERSION = '0.2.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongoid-active_merchant
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Crouse
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-08-26 00:00:00.000000000 Z
11
+ date: 2015-09-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mongoid