associationist 0.1.5 → 0.1.6
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 71ae82541e7c023fb388765d041d9f7e9cf3f13084a4299b7f6c2c954197cbf2
|
4
|
+
data.tar.gz: f49611ceb83887ed9fb24a41611259c3087f715fe612485f9240751613f0ef6a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 58b53ffc2067262d0f20682ac3eb26bd0f7cf1d23d3aeb7de1f490b6c8540d0923b0616ded48271f198aa46263a90d2f2dbdd8807cc29885e3a10108628e465e
|
7
|
+
data.tar.gz: a98b9f10263294b01ea57430fff3004da4ceb26a7395a3ee073071c124235cff37350ba98d0bc034599302d735edd302d5d29877aaff40f7e9420606f9da4702
|
@@ -34,6 +34,14 @@ module Associationist
|
|
34
34
|
Reflection::SingularReflection.new(name, scope, options, model)
|
35
35
|
end
|
36
36
|
|
37
|
+
def self.define_writers(mixin, name)
|
38
|
+
mixin.class_eval <<-CODE, __FILE__, __LINE__ + 1
|
39
|
+
def #{name}=(value)
|
40
|
+
association(:#{name}).target = value
|
41
|
+
end
|
42
|
+
CODE
|
43
|
+
end
|
44
|
+
|
37
45
|
end
|
38
46
|
end
|
39
47
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: associationist
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- CicholGricenchos
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-08-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -123,7 +123,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: '0'
|
125
125
|
requirements: []
|
126
|
-
rubygems_version: 3.
|
126
|
+
rubygems_version: 3.1.2
|
127
127
|
signing_key:
|
128
128
|
specification_version: 4
|
129
129
|
summary: ''
|