active_type 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/gemfiles/Gemfile.3.2.lock +1 -1
- data/gemfiles/Gemfile.4.0.lock +1 -1
- data/gemfiles/Gemfile.4.1.lock +1 -1
- data/gemfiles/Gemfile.4.2.lock +1 -1
- data/lib/active_type/extended_record.rb +1 -0
- data/lib/active_type/version.rb +1 -1
- data/spec/active_type/nested_attributes_spec.rb +18 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d34e93d8bb376b7afcf631c41e4656b34346488e
|
4
|
+
data.tar.gz: 4cfe64618490965f0c4bc1a4dcf6771aca4e6ed8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 85a874cbe804ed0b878d03f085bbaf81a48de22ee94425d4dbc7e01d0d118bbd6affd9f9f39ab4108eb1f25ab980f043e4f7eb0ba348b248b5abc567a5d0c3ea
|
7
|
+
data.tar.gz: b43cc5c7ae0382efc4c9c4de62c68d10078f486d8596f7fc2709ff5eb938536f18a8f4519c7a884028d49ad9671866e6668389ddc71c3c277f8ea30e10b76ded
|
data/README.md
CHANGED
@@ -213,7 +213,7 @@ end
|
|
213
213
|
}
|
214
214
|
```
|
215
215
|
|
216
|
-
To use it with single records, use `nests_one`. It works like `accept_nested_attributes` does for `has_one`.
|
216
|
+
To use it with single records, use `nests_one`. It works like `accept_nested_attributes` does for `has_one`. Use `.record_attributes =` to build the child record.
|
217
217
|
|
218
218
|
Supported options for `nests_many` / `nests_one` are:
|
219
219
|
- `build_scope`
|
data/gemfiles/Gemfile.3.2.lock
CHANGED
data/gemfiles/Gemfile.4.0.lock
CHANGED
data/gemfiles/Gemfile.4.1.lock
CHANGED
data/gemfiles/Gemfile.4.2.lock
CHANGED
data/lib/active_type/version.rb
CHANGED
@@ -680,3 +680,21 @@ describe "ActiveType::Object" do
|
|
680
680
|
end
|
681
681
|
|
682
682
|
end
|
683
|
+
|
684
|
+
describe "ActiveType::Record" do
|
685
|
+
|
686
|
+
it 'supports nested attributes' do
|
687
|
+
ActiveType::Record.should respond_to(:nests_one)
|
688
|
+
ActiveType::Record.should respond_to(:nests_many)
|
689
|
+
end
|
690
|
+
|
691
|
+
end
|
692
|
+
|
693
|
+
describe "ActiveType::Record" do
|
694
|
+
|
695
|
+
it 'supports nested attributes' do
|
696
|
+
ActiveType::Record[NestedAttributesSpec::Record].should respond_to(:nests_one)
|
697
|
+
ActiveType::Record[NestedAttributesSpec::Record].should respond_to(:nests_many)
|
698
|
+
end
|
699
|
+
|
700
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_type
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tobias Kraze
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-
|
12
|
+
date: 2014-11-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|