mc-fedex 0.1.0 → 0.2.0
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/VERSION +1 -1
- data/lib/mc-fedex.rb +3 -1
- data/mc-fedex.gemspec +1 -1
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.2.0
|
data/lib/mc-fedex.rb
CHANGED
@@ -127,6 +127,7 @@ module McFedex
|
|
127
127
|
count = options[:count] || 1
|
128
128
|
weight = options[:weight]
|
129
129
|
rma = options[:rma] || ""
|
130
|
+
tracking_number = options[:tracking_number] || 0
|
130
131
|
|
131
132
|
time = options[:time] || Time.now
|
132
133
|
puts time.class
|
@@ -213,7 +214,8 @@ module McFedex
|
|
213
214
|
if successful && msg !~ /There are no valid services available/
|
214
215
|
if @use_smart_post
|
215
216
|
charge = 0
|
216
|
-
|
217
|
+
# trackingIds[0] - this is the 22 digit tracking number, trackingIds[1] is the shorter tracking number
|
218
|
+
tracking_number = result.completedShipmentDetail.completedPackageDetails.trackingIds[tracking_number].trackingNumber
|
217
219
|
else
|
218
220
|
pre = result.completedShipmentDetail.shipmentRating.shipmentRateDetails
|
219
221
|
charge = ((pre.class == Array ? pre[0].totalNetCharge.amount.to_f : pre.totalNetCharge.amount.to_f) * 100).to_i
|
data/mc-fedex.gemspec
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mc-fedex
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
|
-
-
|
8
|
+
- 2
|
9
9
|
- 0
|
10
|
-
version: 0.
|
10
|
+
version: 0.2.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Edwin & Adam & Eric
|