postmen 1.0.1 → 1.0.2

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: 8ad6ad295b262d6c51e17eae0742c3dfc97ea0fe
4
- data.tar.gz: '0487c46ddffadbf35c670fcb1acbe3ac4bb07172'
3
+ metadata.gz: 4dcf572cb04e3a9659c5b849b41857a82c4869cb
4
+ data.tar.gz: fdea775c828c21e11ac77ba66fff02221dbd3b18
5
5
  SHA512:
6
- metadata.gz: eacc06fc16b9950fadbbd2ad7319c80a2d352591e4b1067e9e78e602cccf3ac104c4093cb94a397b5d75f87c479ed164625551a0b214feea21808c1f88c69752
7
- data.tar.gz: 619b65d837e064cb336968b9fa749b027bd3ec0e11579e0389844f20130eb32c5b00018ef8e7afeebf51317a7c80d55f447e805d4aea707eb9a1424eb052ba6f
6
+ metadata.gz: 31e2b5546945a3e68f27669629fe4f4de1a99e30924acaf0ddffd55ac841abbc0b548a312e84413217f5600a6c39688b471f3d399e48e5dd7b30a67b514660ec
7
+ data.tar.gz: de98f2e8561a520d63f8cfb48f2f18e4645d2abd5aa137c167f6add3cd4e7e430d4dfac95cfb38223844f81f01d5f3a03874db39c1eb8d0b261e4ae73b92b004
data/lib/postmen/label.rb CHANGED
@@ -8,7 +8,8 @@ class Postmen
8
8
  attribute :tracking_numbers, Types::Array.member(Types::String)
9
9
  attribute :files, Types::Strict::Nil | Types::Array.member(Types::Hash)
10
10
  attribute :rate, Types::Strict::Nil | Types::Hash
11
-
11
+ attribute :created_at, Types::Strict::Nil | Types::DateTime
12
+ attribute :updated_at, Types::Strict::Nil | Types::DateTime
12
13
  # Returns all labels
13
14
  #
14
15
  # @see LabelCollection#all
data/lib/postmen/types.rb CHANGED
@@ -2,6 +2,16 @@
2
2
  Dry::Types.load_extensions(:maybe)
3
3
 
4
4
  class Postmen
5
+
6
+ PAPER_SIZES = [
7
+ '4x4',
8
+ '4x6',
9
+ '4x6.75',
10
+ '4x8',
11
+ '6x4',
12
+ 'a4',
13
+ 'default'
14
+ ].freeze
5
15
  # This module holds all definitions of simple types used in the API
6
16
  module Types
7
17
  include Dry::Types.module
@@ -59,15 +69,7 @@ class Postmen
59
69
  Country = Types::String
60
70
 
61
71
  # Paper size
62
- PaperSize = Types::String.enum(
63
- '4x4',
64
- '4x6',
65
- '4x6.75',
66
- '4x8',
67
- '6x4',
68
- 'a4',
69
- 'default'
70
- )
72
+ PaperSize = Types::String.enum(PAPER_SIZES)
71
73
 
72
74
  # Purpose used in customs object
73
75
  #
@@ -1,4 +1,4 @@
1
1
  class Postmen
2
2
  # SDK Version
3
- VERSION = '1.0.1'.freeze
3
+ VERSION = '1.0.2'.freeze
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: postmen
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - postmen.com
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-27 00:00:00.000000000 Z
11
+ date: 2017-03-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: http