model_updates 0.0.3 → 0.0.4

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: 2a59f8ea4192d5bed3b04a65b1f7bfc2250dc9b1
4
- data.tar.gz: b430d99789a7ef8c10587148239e8d2f37f6e8d7
3
+ metadata.gz: 55cad4d123a29cc4f099ce8b0072fe692d783298
4
+ data.tar.gz: 04a73706c8ef3f66440ab0ebff2683b702f4d26b
5
5
  SHA512:
6
- metadata.gz: c9e4f946c86f807566a156130fab749921c995ca2cecabaf456abad224edacebe41df5503e656b36b7bd81b7b186dd174141b56e7f1f3a064aef1bbbf961aea4
7
- data.tar.gz: dad910965e6feb9fea5503d3688db3976eb52bc1920085a65f6f550da29263ff377fcf5eab53578c57c52680e4e512cb505ddb8f785c4db495a95709365246e4
6
+ metadata.gz: 71bd72da83c44936f8475851356045d20ff0cc2ba26c893c14278e0163ebdabd23b4397e702481310b3809cfd2fc3052a9b39fa872541485590494c015b2f601
7
+ data.tar.gz: 03b5e3e89ef4ef141205cd5552e081e4285842a91a89d36cb75d3712f43e3b8b4ef993333470ae0592168498630e61905434be75937b102f0e78cc4b3cd0d3f5
@@ -31,6 +31,20 @@ module ModelUpdates::ModelExtensions
31
31
  end
32
32
  end
33
33
 
34
+ def model_updates_attrs(key, more = {})
35
+ attrs = {
36
+ model_updates_id: id,
37
+ model_updates_model: self.class.name,
38
+ model_updates_key: key
39
+ }
40
+
41
+ more.each do |hash_key, hash_value|
42
+ attrs["model_updates_#{hash_key}"] = hash_value
43
+ end
44
+
45
+ attrs
46
+ end
47
+
34
48
  def model_updates_data_attrs(key, more = {})
35
49
  {
36
50
  id: id,
@@ -1,3 +1,3 @@
1
1
  module ModelUpdates
2
- VERSION = "0.0.3".freeze
2
+ VERSION = "0.0.4".freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: model_updates
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - kaspernj