active_dynamic 0.5.0 → 0.5.1

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: 561ff35f6f9d9ccfd7925b6717bc139ab9d6ac10
4
- data.tar.gz: c846f231edd33786e866070ca378f2734a4c80b4
3
+ metadata.gz: 10e9eb6462e773741bf5e044a2666194c71c4d5b
4
+ data.tar.gz: 5a33fdec8c771396710b6f05dfe2d1280fb80739
5
5
  SHA512:
6
- metadata.gz: 789f970d6b430f58ba8898c40897c7a38f94ff4acb1346348451777a282f685555551efa608f022162f2058ad3083dabf2123246dcc83378d1dff4688746f068
7
- data.tar.gz: e8132be0560081f460f658c9e08d52d1a1bc55e43c401e62bf17b07492d0117e709ac3b47e666cfd0b79e3f8ed11f1e36bdeb5345a766aa4de144286e15d4e32
6
+ metadata.gz: ffff1d181a7c1267537c96e565fd4db80935c087c1aef58569ece821befc0d2ac102fd374fc0ca409d243a91b50cead1de5d0737cd3fbd0c8213cb16ef953e7b
7
+ data.tar.gz: 564b73bfcbd47e0a499e8ee3182a82fd8c421caa46bf0c710f480ea2367fef29e4adf21f15ed3aa2233432b696473221557a93e452ae2e9b58631e08fdc42a23
data/README.md CHANGED
@@ -30,7 +30,7 @@ attributses. For example, if you have `Profile` model:
30
30
 
31
31
  ```ruby
32
32
  class Profile < ActiveRecord::Base
33
- include ActiveDynamic::HasDynamicAttributes
33
+ has_dynamic_attributes
34
34
 
35
35
  # ...
36
36
  end
@@ -0,0 +1,11 @@
1
+ module ActiveDynamic
2
+ module ActiveRecord
3
+
4
+ def has_dynamic_attributes
5
+ include ActiveDynamic::HasDynamicAttributes
6
+ end
7
+
8
+ end
9
+ end
10
+
11
+ ActiveRecord::Base.extend ActiveDynamic::ActiveRecord
@@ -1,3 +1,3 @@
1
1
  module ActiveDynamic
2
- VERSION = '0.5.0'
2
+ VERSION = '0.5.1'
3
3
  end
@@ -4,6 +4,7 @@ require 'active_dynamic/data_type'
4
4
  require 'active_dynamic/attribute_definition'
5
5
  require 'active_dynamic/attribute'
6
6
  require 'active_dynamic/has_dynamic_attributes'
7
+ require 'active_dynamic/active_record'
7
8
  require 'active_dynamic/configuration'
8
9
  require 'active_dynamic/null_provider'
9
10
  require 'active_dynamic/version'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_dynamic
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Constantine Lebedev
@@ -103,6 +103,7 @@ files:
103
103
  - bin/console
104
104
  - bin/setup
105
105
  - lib/active_dynamic.rb
106
+ - lib/active_dynamic/active_record.rb
106
107
  - lib/active_dynamic/attribute.rb
107
108
  - lib/active_dynamic/attribute_definition.rb
108
109
  - lib/active_dynamic/configuration.rb