datory 1.0.0.rc7 → 1.0.0.rc8

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
  SHA256:
3
- metadata.gz: 992667eaefb8dcff761e0825d44819b40bd11c899c951cdca0fca3ae6d3723cc
4
- data.tar.gz: dd68e1829262596d46501c04d2a3e70099bd304a531c1d5a36fd6cd6f4c70633
3
+ metadata.gz: 3b052892a1fc08acc5ffb825f3dc14eaca5d28f715850e7f8e54b9c594a419d9
4
+ data.tar.gz: 6d87e60a4bd9ce2a4972091950010bb4908b921f7489ce2d728515c45666a98c
5
5
  SHA512:
6
- metadata.gz: 0e57b1a386bf1d2ef566f385499e4daf7b14ee34c74295c6f3cba6a6b8fc75e95956005f33af86d4a407bc2e613a0130a2b9ffe4ceb9c115c5230143db9a62bb
7
- data.tar.gz: eb2f8b9a873852919c5a8f6fa1f644a293f05cf62398028a37315053bf793fefc1297f956bf851fba3bf29dcef4b77c784e1d4068f352b341fd2cb0f336cdb4d
6
+ metadata.gz: 675cd69f300045e6bcdd58ea9c24b402fd0c652a30c0fff78dbc73b45635d405f9c5598a45696bb967cc890c94c97a1f7e6e50bcaf8b7275a6bf518656ccfe63
7
+ data.tar.gz: b40b64a011b064e3222612d36d13c2309d975078dcfcdc20c903cb5e3d407b048b25ef54361e83bcd602ac5fdd5a67cc6353dae0bf36a5e542d70afec2b3b0fb
data/README.md CHANGED
@@ -36,30 +36,34 @@ UserDto.deserialize(json)
36
36
  ```ruby
37
37
  class UserDto < Datory::Base
38
38
  uuid :id
39
+
39
40
  string :firstname, to: :first_name
40
41
  string :lastname, to: :last_name
42
+
41
43
  string :email
44
+ string :phone
45
+ string :website
46
+
42
47
  string :birthDate, to: :birth_date, as: Date
43
48
 
44
49
  one :login, include: UserLoginDto
50
+ one :company, include: UserCompanyDto
45
51
 
46
52
  many :addresses, include: UserAddressDto
47
-
48
- string :phone
49
- string :website
50
-
51
- one :company, include: UserCompanyDto
52
53
  end
53
54
  ```
54
55
 
55
56
  ```ruby
56
57
  class UserLoginDto < Datory::Base
57
- string :uuid
58
+ uuid :id
59
+
58
60
  string :username
59
61
  string :password
62
+
60
63
  string :md5
61
64
  string :sha1
62
- string :registered, to: :registered_at, as: DateTime
65
+
66
+ string :registered_at, as: DateTime
63
67
  end
64
68
  ```
65
69
 
@@ -40,11 +40,6 @@ module Datory
40
40
 
41
41
  ########################################################################
42
42
 
43
- def symbol(name, **options)
44
- options = options.merge(from: Symbol)
45
- attribute(name, **options)
46
- end
47
-
48
43
  def string(name, **options)
49
44
  options = options.merge(from: String)
50
45
  attribute(name, **options)
@@ -60,21 +55,6 @@ module Datory
60
55
  attribute(name, **options)
61
56
  end
62
57
 
63
- def date(name, **options)
64
- options = options.merge(from: Date)
65
- attribute(name, **options)
66
- end
67
-
68
- def time(name, **options)
69
- options = options.merge(from: Time)
70
- attribute(name, **options)
71
- end
72
-
73
- def datetime(name, **options)
74
- options = options.merge(from: DateTime)
75
- attribute(name, **options)
76
- end
77
-
78
58
  ########################################################################
79
59
 
80
60
  def collection_of_attributes
@@ -5,7 +5,7 @@ module Datory
5
5
  MAJOR = 1
6
6
  MINOR = 0
7
7
  PATCH = 0
8
- PRE = "rc7"
8
+ PRE = "rc8"
9
9
 
10
10
  STRING = [MAJOR, MINOR, PATCH, PRE].compact.join(".")
11
11
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: datory
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.rc7
4
+ version: 1.0.0.rc8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anton Sokolov