mongoid_embedded_helper 0.2.5 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
data/README.markdown CHANGED
@@ -3,6 +3,10 @@
3
3
  The Mongoid EmbeddedHelper helps overcome the limitation that you can't perform direct queries on an embedded collection without accessing it from the root.
4
4
  It simply introduces a generic function that performs the "local" query by accessing it from the nearest root ;)
5
5
 
6
+ ## Update
7
+
8
+ In the latest release (0.3.0) the #assimilate method has been removed in order to work with Mongoid 2.0.0.rc1
9
+
6
10
  ## Installation ##
7
11
 
8
12
  <code>gem install mongoid_embedded_helper</code>
data/Rakefile CHANGED
@@ -10,11 +10,11 @@ begin
10
10
  gem.email = "kmandrup@gmail.com"
11
11
  gem.homepage = "http://github.com/kristianmandrup/mongoid_embedded_helper"
12
12
  gem.authors = ["Kristian Mandrup"]
13
- gem.add_dependency "mongoid", ">= 2.0.0.beta.14"
13
+ gem.add_dependency "mongoid", ">= 2.0.0.beta.18"
14
14
  gem.add_dependency "mongoid_adjust", ">= 0.1.1"
15
- gem.add_dependency "bson_ext", ">= 1.0.3"
15
+ gem.add_dependency "bson_ext", ">= 1.0.8"
16
16
 
17
- gem.add_development_dependency "rspec", ">=2.0.0.beta.15"
17
+ gem.add_development_dependency "rspec", ">=2.0.1"
18
18
  end
19
19
  Jeweler::GemcutterTasks.new
20
20
  rescue LoadError
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.5
1
+ 0.3.0
@@ -4,14 +4,7 @@ module Mongoid
4
4
  module EmbeddedHelper
5
5
  def self.included(model)
6
6
  model.class_eval do
7
-
8
- alias_method :old_assimilate, :assimilate
9
- def assimilate(parent, options)
10
- old_assimilate parent, options
11
- send(:after_assimilate) if respond_to?(:after_assimilate)
12
- # run_callbacks(:after_assimilate)
13
- end
14
-
7
+
15
8
  alias_method :old_parentize, :parentize
16
9
  def parentize(object, association_name)
17
10
  old_parentize object, association_name
@@ -1,50 +1,47 @@
1
1
  # Generated by jeweler
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{mongoid_embedded_helper}
8
- s.version = "0.2.5"
8
+ s.version = "0.3.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Kristian Mandrup"]
12
- s.date = %q{2010-08-08}
12
+ s.date = %q{2011-01-10}
13
13
  s.description = %q{Facilitates performing queries on collections in embedded Mongoid documents by performing query from the root node}
14
14
  s.email = %q{kmandrup@gmail.com}
15
15
  s.extra_rdoc_files = [
16
16
  "README.markdown"
17
17
  ]
18
18
  s.files = [
19
- ".gitignore",
20
- "Gemfile",
21
- "Gemfile.lock",
22
- "MITLICENSE",
23
- "README.markdown",
24
- "Rakefile",
25
- "VERSION",
26
- "autotest/discover.rb",
27
- "lib/mongoid/embedded_helper.rb",
28
- "lib/mongoid_embedded_helper.rb",
29
- "mongoid_embedded_helper.gemspec",
30
- "rspec.options",
31
- "spec/model/list.rb",
32
- "spec/model/person_list.rb",
33
- "spec/mongoid/embedded_helper_spec.rb",
34
- "spec/mongoid/more_embedded_helper_spec.rb",
35
- "spec/spec_helper.rb"
19
+ "Gemfile",
20
+ "MITLICENSE",
21
+ "README.markdown",
22
+ "Rakefile",
23
+ "VERSION",
24
+ "autotest/discover.rb",
25
+ "lib/mongoid/embedded_helper.rb",
26
+ "lib/mongoid_embedded_helper.rb",
27
+ "mongoid_embedded_helper.gemspec",
28
+ "rspec.options",
29
+ "spec/model/list.rb",
30
+ "spec/model/person_list.rb",
31
+ "spec/mongoid/embedded_helper_spec.rb",
32
+ "spec/mongoid/more_embedded_helper_spec.rb",
33
+ "spec/spec_helper.rb"
36
34
  ]
37
35
  s.homepage = %q{http://github.com/kristianmandrup/mongoid_embedded_helper}
38
- s.rdoc_options = ["--charset=UTF-8"]
39
36
  s.require_paths = ["lib"]
40
37
  s.rubygems_version = %q{1.3.7}
41
38
  s.summary = %q{Facilitates performing queries on collections in embedded Mongoid documents}
42
39
  s.test_files = [
43
40
  "spec/model/list.rb",
44
- "spec/model/person_list.rb",
45
- "spec/mongoid/embedded_helper_spec.rb",
46
- "spec/mongoid/more_embedded_helper_spec.rb",
47
- "spec/spec_helper.rb"
41
+ "spec/model/person_list.rb",
42
+ "spec/mongoid/embedded_helper_spec.rb",
43
+ "spec/mongoid/more_embedded_helper_spec.rb",
44
+ "spec/spec_helper.rb"
48
45
  ]
49
46
 
50
47
  if s.respond_to? :specification_version then
@@ -54,19 +51,28 @@ Gem::Specification.new do |s|
54
51
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
55
52
  s.add_runtime_dependency(%q<mongoid>, [">= 2.0.0.beta.14"])
56
53
  s.add_runtime_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
57
- s.add_runtime_dependency(%q<bson_ext>, [">= 1.0.3"])
58
- s.add_development_dependency(%q<rspec>, [">= 2.0.0.beta.15"])
54
+ s.add_runtime_dependency(%q<bson_ext>, [">= 1.0.1"])
55
+ s.add_runtime_dependency(%q<mongoid>, [">= 2.0.0.beta.18"])
56
+ s.add_runtime_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
57
+ s.add_runtime_dependency(%q<bson_ext>, [">= 1.0.8"])
58
+ s.add_development_dependency(%q<rspec>, [">= 2.0.1"])
59
59
  else
60
60
  s.add_dependency(%q<mongoid>, [">= 2.0.0.beta.14"])
61
61
  s.add_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
62
- s.add_dependency(%q<bson_ext>, [">= 1.0.3"])
63
- s.add_dependency(%q<rspec>, [">= 2.0.0.beta.15"])
62
+ s.add_dependency(%q<bson_ext>, [">= 1.0.1"])
63
+ s.add_dependency(%q<mongoid>, [">= 2.0.0.beta.18"])
64
+ s.add_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
65
+ s.add_dependency(%q<bson_ext>, [">= 1.0.8"])
66
+ s.add_dependency(%q<rspec>, [">= 2.0.1"])
64
67
  end
65
68
  else
66
69
  s.add_dependency(%q<mongoid>, [">= 2.0.0.beta.14"])
67
70
  s.add_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
68
- s.add_dependency(%q<bson_ext>, [">= 1.0.3"])
69
- s.add_dependency(%q<rspec>, [">= 2.0.0.beta.15"])
71
+ s.add_dependency(%q<bson_ext>, [">= 1.0.1"])
72
+ s.add_dependency(%q<mongoid>, [">= 2.0.0.beta.18"])
73
+ s.add_dependency(%q<mongoid_adjust>, [">= 0.1.1"])
74
+ s.add_dependency(%q<bson_ext>, [">= 1.0.8"])
75
+ s.add_dependency(%q<rspec>, [">= 2.0.1"])
70
76
  end
71
77
  end
72
78
 
metadata CHANGED
@@ -4,9 +4,9 @@ version: !ruby/object:Gem::Version
4
4
  prerelease: false
5
5
  segments:
6
6
  - 0
7
- - 2
8
- - 5
9
- version: 0.2.5
7
+ - 3
8
+ - 0
9
+ version: 0.3.0
10
10
  platform: ruby
11
11
  authors:
12
12
  - Kristian Mandrup
@@ -14,12 +14,11 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-08-08 00:00:00 +02:00
17
+ date: 2011-01-10 00:00:00 +01:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: mongoid
22
- prerelease: false
23
22
  requirement: &id001 !ruby/object:Gem::Requirement
24
23
  none: false
25
24
  requirements:
@@ -33,10 +32,10 @@ dependencies:
33
32
  - 14
34
33
  version: 2.0.0.beta.14
35
34
  type: :runtime
35
+ prerelease: false
36
36
  version_requirements: *id001
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: mongoid_adjust
39
- prerelease: false
40
39
  requirement: &id002 !ruby/object:Gem::Requirement
41
40
  none: false
42
41
  requirements:
@@ -48,10 +47,10 @@ dependencies:
48
47
  - 1
49
48
  version: 0.1.1
50
49
  type: :runtime
50
+ prerelease: false
51
51
  version_requirements: *id002
52
52
  - !ruby/object:Gem::Dependency
53
53
  name: bson_ext
54
- prerelease: false
55
54
  requirement: &id003 !ruby/object:Gem::Requirement
56
55
  none: false
57
56
  requirements:
@@ -60,13 +59,13 @@ dependencies:
60
59
  segments:
61
60
  - 1
62
61
  - 0
63
- - 3
64
- version: 1.0.3
62
+ - 1
63
+ version: 1.0.1
65
64
  type: :runtime
65
+ prerelease: false
66
66
  version_requirements: *id003
67
67
  - !ruby/object:Gem::Dependency
68
- name: rspec
69
- prerelease: false
68
+ name: mongoid
70
69
  requirement: &id004 !ruby/object:Gem::Requirement
71
70
  none: false
72
71
  requirements:
@@ -77,10 +76,56 @@ dependencies:
77
76
  - 0
78
77
  - 0
79
78
  - beta
80
- - 15
81
- version: 2.0.0.beta.15
82
- type: :development
79
+ - 18
80
+ version: 2.0.0.beta.18
81
+ type: :runtime
82
+ prerelease: false
83
83
  version_requirements: *id004
84
+ - !ruby/object:Gem::Dependency
85
+ name: mongoid_adjust
86
+ requirement: &id005 !ruby/object:Gem::Requirement
87
+ none: false
88
+ requirements:
89
+ - - ">="
90
+ - !ruby/object:Gem::Version
91
+ segments:
92
+ - 0
93
+ - 1
94
+ - 1
95
+ version: 0.1.1
96
+ type: :runtime
97
+ prerelease: false
98
+ version_requirements: *id005
99
+ - !ruby/object:Gem::Dependency
100
+ name: bson_ext
101
+ requirement: &id006 !ruby/object:Gem::Requirement
102
+ none: false
103
+ requirements:
104
+ - - ">="
105
+ - !ruby/object:Gem::Version
106
+ segments:
107
+ - 1
108
+ - 0
109
+ - 8
110
+ version: 1.0.8
111
+ type: :runtime
112
+ prerelease: false
113
+ version_requirements: *id006
114
+ - !ruby/object:Gem::Dependency
115
+ name: rspec
116
+ requirement: &id007 !ruby/object:Gem::Requirement
117
+ none: false
118
+ requirements:
119
+ - - ">="
120
+ - !ruby/object:Gem::Version
121
+ segments:
122
+ - 2
123
+ - 0
124
+ - 1
125
+ version: 2.0.1
126
+ type: :development
127
+ prerelease: false
128
+ version_requirements: *id007
84
129
  description: Facilitates performing queries on collections in embedded Mongoid documents by performing query from the root node
85
130
  email: kmandrup@gmail.com
86
131
  executables: []
@@ -90,9 +135,7 @@ extensions: []
90
135
  extra_rdoc_files:
91
136
  - README.markdown
92
137
  files:
93
- - .gitignore
94
138
  - Gemfile
95
- - Gemfile.lock
96
139
  - MITLICENSE
97
140
  - README.markdown
98
141
  - Rakefile
@@ -112,8 +155,8 @@ homepage: http://github.com/kristianmandrup/mongoid_embedded_helper
112
155
  licenses: []
113
156
 
114
157
  post_install_message:
115
- rdoc_options:
116
- - --charset=UTF-8
158
+ rdoc_options: []
159
+
117
160
  require_paths:
118
161
  - lib
119
162
  required_ruby_version: !ruby/object:Gem::Requirement
data/.gitignore DELETED
@@ -1,14 +0,0 @@
1
- .DS_STORE
2
-
3
- # yard generated
4
- doc
5
- .yardoc
6
-
7
- # jeweler generated
8
- pkg
9
- vendor
10
- .bundle
11
-
12
-
13
-
14
-
data/Gemfile.lock DELETED
@@ -1,47 +0,0 @@
1
- GEM
2
- remote: http://rubygems.org/
3
- specs:
4
- activemodel (3.0.0.rc)
5
- activesupport (= 3.0.0.rc)
6
- builder (~> 2.1.2)
7
- i18n (~> 0.4.1)
8
- activesupport (3.0.0.rc)
9
- bson (1.0.4)
10
- bson_ext (1.0.4)
11
- builder (2.1.2)
12
- diff-lcs (1.1.2)
13
- i18n (0.4.1)
14
- mocha (0.9.8)
15
- rake
16
- mongo (1.0.6)
17
- bson (>= 1.0.4)
18
- mongoid (2.0.0.beta.15)
19
- activemodel (= 3.0.0.rc)
20
- bson (= 1.0.4)
21
- mongo (= 1.0.6)
22
- tzinfo (= 0.3.22)
23
- will_paginate (~> 3.0.pre)
24
- mongoid_adjust (0.1.1)
25
- bson (>= 1.0.3)
26
- mongoid (>= 2.0.0.beta.14)
27
- rake (0.8.7)
28
- rspec (2.0.0.beta.19)
29
- rspec-core (= 2.0.0.beta.19)
30
- rspec-expectations (= 2.0.0.beta.19)
31
- rspec-mocks (= 2.0.0.beta.19)
32
- rspec-core (2.0.0.beta.19)
33
- rspec-expectations (2.0.0.beta.19)
34
- diff-lcs (>= 1.1.2)
35
- rspec-mocks (2.0.0.beta.19)
36
- tzinfo (0.3.22)
37
- will_paginate (3.0.pre2)
38
-
39
- PLATFORMS
40
- ruby
41
-
42
- DEPENDENCIES
43
- bson_ext (>= 1.0.1)
44
- mocha
45
- mongoid (>= 2.0.0.beta.14)
46
- mongoid_adjust (>= 0.1.1)
47
- rspec (>= 2.0.0.beta.15)