ups-ruby 0.11.8 → 0.12.8

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ce31214234663e90d8d7ce00b51e518ce19e65cd6accc3b340b63f77b57c00a4
4
- data.tar.gz: 0aaca2ab7195698e301cdfd5090de7eac7bde4da97121e7a862b18b44093da78
3
+ metadata.gz: f372e3eb264707d123728a426b04029180324840248f8a793f72016cd1c45ee3
4
+ data.tar.gz: 4ff60293378bb1a91e097e17f15956f98e93ba1c1220e2f244dbefc4f6870551
5
5
  SHA512:
6
- metadata.gz: 499730f5860fd137c4bc58e34b4411e0b07573262532acdd8abf20b1495490a05aa1eebe74192b021550fb2094aabcade89664e1e50d98ff4a0480e74c5873c0
7
- data.tar.gz: 53f17acb18c5476a36b83a799b3599501ed1c56aa12178d9ec477ee448b948dd6fe833cec37258be4072b336a44f2a0fd3451ebfc93543f4826c7bc6454569d1
6
+ metadata.gz: f0011485798853e3a0432b96858d95c536ef85ea6dccdc7423d1788123382c06eb2588b817d78a2095e248855ee43f0932aa5be35ca7e36df633fc5bf9f4ddca
7
+ data.tar.gz: da34e7cee607f619dfc711563fd3c9ae267bac0f209be4f6cc7aafdca1ae378db960167f1b079a0297c951c4ce8526b637759be3f8444a3b65a96f226c1ce04d
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ups-ruby (0.11.8)
4
+ ups-ruby (0.12.8)
5
5
  excon (~> 0.45, >= 0.45.3)
6
6
  insensitive_hash (~> 0.3.3)
7
7
  levenshtein-ffi (~> 1.1)
@@ -38,6 +38,14 @@ module UPS
38
38
  element_with_value('CurrencyCode', opts[:currency_code])
39
39
  end
40
40
 
41
+ def freight_charge
42
+ multi_valued('FreightCharges', MonetaryValue: opts[:freight_charge])
43
+ end
44
+
45
+ def discount
46
+ multi_valued('Discount', MonetaryValue: opts[:discount])
47
+ end
48
+
41
49
  def product_details
42
50
  opts[:products].map do |product_opts|
43
51
  product_container(product_opts)
@@ -58,6 +66,8 @@ module UPS
58
66
  international_form << invoice_date
59
67
  international_form << reason_for_export
60
68
  international_form << currency_code
69
+ international_form << freight_charge
70
+ international_form << discount
61
71
 
62
72
  product_details.each do |product_detail|
63
73
  international_form << product_detail
@@ -1,7 +1,7 @@
1
1
  module UPS
2
2
  module Version
3
3
  MAJOR = 0
4
- MINOR = 11
4
+ MINOR = 12
5
5
  PATCH = 8
6
6
  BUILD = nil
7
7
 
@@ -65,6 +65,8 @@ module ShippingOptions
65
65
  invoice_date: '20170816',
66
66
  reason_for_export: '',
67
67
  currency_code: 'USD',
68
+ discount: '1',
69
+ freight_charge: '1',
68
70
  products: [
69
71
  {
70
72
  description: 'White coffee mug',
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ups-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.8
4
+ version: 0.12.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Veeqo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-01 00:00:00.000000000 Z
11
+ date: 2019-11-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ox