blastramp 0.0.10 → 0.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.
@@ -18,16 +18,16 @@ module Blastramp
18
18
  soap.body = {
19
19
  'VendorCode' => session.vendor_code,
20
20
  'VendorAccessKey' => session.vendor_access_key,
21
- 'Batch' => orders.collect {|o| {:order => o.soap_data}}
21
+ 'Batch' => {'Order' => orders[0].soap_data}
22
22
  }
23
23
  end
24
- if (response.to_hash[:result] == 'SUCCESS')
24
+ if (response.to_hash[:result] == 'SUCCESS' && response.to_hash[:orderids])
25
25
  response.to_hash[:orderids][:string]
26
26
  elsif (response.to_hash[:error] == 'Failed to Authenticate.')
27
27
  raise(AuthenticationFailure.new)
28
28
  else
29
29
  raise "Blastramp: An unknown error occured"
30
30
  end
31
- end
31
+ end
32
32
  end
33
33
  end
@@ -1,4 +1,4 @@
1
1
  module Blastramp
2
- VERSION = "0.0.10"
2
+ VERSION = "0.0.11"
3
3
  end
4
4
 
@@ -17,7 +17,7 @@ describe Blastramp::OrderUpload do
17
17
  savon.expects('OrderUpload').with(
18
18
  'VendorCode' => 'ABC',
19
19
  'VendorAccessKey' => 'TWX45IX2R9G35394',
20
- 'Batch' => [{:order => order.soap_data}]).returns(:success)
20
+ 'Batch' => {'Order' => order.soap_data}).returns(:success)
21
21
  subject.submit
22
22
  end
23
23
 
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 10
9
- version: 0.0.10
8
+ - 11
9
+ version: 0.0.11
10
10
  platform: ruby
11
11
  authors:
12
12
  - cnantais