datory 1.0.0.rc6 → 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: 36c9c3d73db41d95c3d5bafd98df4bb5002ea1f36cacc7fafa808ccb9f8af8d7
4
- data.tar.gz: 56304b66db42d82a4b143711f1192df86f3139979711a0a9c4d6bf6be7f95d85
3
+ metadata.gz: 3b052892a1fc08acc5ffb825f3dc14eaca5d28f715850e7f8e54b9c594a419d9
4
+ data.tar.gz: 6d87e60a4bd9ce2a4972091950010bb4908b921f7489ce2d728515c45666a98c
5
5
  SHA512:
6
- metadata.gz: 7a741dd5da9f0ad4782c101ce76c1063668fe5c77074ff650edb23e16216dffe3bceb7b049b13301a06a6ac4de37156da84b3ebc3754297bf2509ef9cb09195e
7
- data.tar.gz: ec355c7bb2073c0236d4556e6005c874987b3c513389f2efb5c64adb25de3b35f16077579c5468661e53b60a6933217be561d246031d261d8c1e5ab11be0758a
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,26 +55,6 @@ module Datory
60
55
  attribute(name, **options)
61
56
  end
62
57
 
63
- def duration(name, **options)
64
- options = options.merge(from: ActiveSupport::Duration)
65
- attribute(name, **options)
66
- end
67
-
68
- def date(name, **options)
69
- options = options.merge(from: Date)
70
- attribute(name, **options)
71
- end
72
-
73
- def time(name, **options)
74
- options = options.merge(from: Time)
75
- attribute(name, **options)
76
- end
77
-
78
- def datetime(name, **options)
79
- options = options.merge(from: DateTime)
80
- attribute(name, **options)
81
- end
82
-
83
58
  ########################################################################
84
59
 
85
60
  def collection_of_attributes
@@ -21,6 +21,8 @@ module Datory
21
21
  output_option_helpers [
22
22
  Servactory::ToolKit::DynamicOptions::Format.use
23
23
  ]
24
+
25
+ predicate_methods_enabled false
24
26
  end
25
27
  end
26
28
  end
@@ -5,7 +5,7 @@ module Datory
5
5
  MAJOR = 1
6
6
  MINOR = 0
7
7
  PATCH = 0
8
- PRE = "rc6"
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.rc6
4
+ version: 1.0.0.rc8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anton Sokolov
@@ -50,14 +50,14 @@ dependencies:
50
50
  requirements:
51
51
  - - '='
52
52
  - !ruby/object:Gem::Version
53
- version: 2.5.0.rc5
53
+ version: 2.5.0.rc6
54
54
  type: :runtime
55
55
  prerelease: false
56
56
  version_requirements: !ruby/object:Gem::Requirement
57
57
  requirements:
58
58
  - - '='
59
59
  - !ruby/object:Gem::Version
60
- version: 2.5.0.rc5
60
+ version: 2.5.0.rc6
61
61
  - !ruby/object:Gem::Dependency
62
62
  name: zeitwerk
63
63
  requirement: !ruby/object:Gem::Requirement