mongoid 2.3.5 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.md +34 -176
- data/LICENSE +1 -1
- data/lib/config/locales/bg.yml +6 -0
- data/lib/config/locales/de.yml +6 -0
- data/lib/config/locales/en-GB.yml +8 -0
- data/lib/config/locales/en.yml +8 -0
- data/lib/config/locales/es.yml +9 -3
- data/lib/config/locales/fr.yml +6 -0
- data/lib/config/locales/hi.yml +6 -0
- data/lib/config/locales/hu.yml +6 -0
- data/lib/config/locales/id.yml +6 -0
- data/lib/config/locales/it.yml +6 -0
- data/lib/config/locales/ja.yml +6 -0
- data/lib/config/locales/kr.yml +6 -0
- data/lib/config/locales/nl.yml +8 -0
- data/lib/config/locales/pl.yml +6 -0
- data/lib/config/locales/pt-BR.yml +6 -0
- data/lib/config/locales/pt.yml +8 -2
- data/lib/config/locales/ro.yml +6 -0
- data/lib/config/locales/ru.yml +6 -0
- data/lib/config/locales/sv.yml +6 -0
- data/lib/config/locales/vi.yml +14 -8
- data/lib/config/locales/zh-CN.yml +6 -0
- data/lib/mongoid/atomic.rb +62 -13
- data/lib/mongoid/atomic/modifiers.rb +33 -1
- data/lib/mongoid/attributes.rb +5 -19
- data/lib/mongoid/callbacks.rb +2 -1
- data/lib/mongoid/collection.rb +2 -2
- data/lib/mongoid/collections/retry.rb +18 -6
- data/lib/mongoid/components.rb +2 -0
- data/lib/mongoid/config.rb +8 -63
- data/lib/mongoid/config/environment.rb +41 -0
- data/lib/mongoid/config/options.rb +74 -0
- data/lib/mongoid/contexts/enumerable.rb +0 -24
- data/lib/mongoid/contexts/mongo.rb +33 -3
- data/lib/mongoid/copyable.rb +1 -1
- data/lib/mongoid/criteria.rb +4 -2
- data/lib/mongoid/criterion/inclusion.rb +1 -16
- data/lib/mongoid/criterion/optional.rb +37 -10
- data/lib/mongoid/criterion/scoping.rb +83 -0
- data/lib/mongoid/criterion/selector.rb +9 -6
- data/lib/mongoid/default_scope.rb +1 -1
- data/lib/mongoid/dirty.rb +163 -29
- data/lib/mongoid/document.rb +58 -7
- data/lib/mongoid/errors.rb +2 -0
- data/lib/mongoid/errors/no_environment.rb +19 -0
- data/lib/mongoid/errors/scope_overwrite.rb +21 -0
- data/lib/mongoid/extensions.rb +6 -0
- data/lib/mongoid/extensions/array/deep_copy.rb +25 -0
- data/lib/mongoid/extensions/hash/deep_copy.rb +25 -0
- data/lib/mongoid/extensions/hash/scoping.rb +1 -1
- data/lib/mongoid/extensions/object/deep_copy.rb +21 -0
- data/lib/mongoid/extensions/proc/scoping.rb +2 -2
- data/lib/mongoid/extensions/symbol/inflections.rb +1 -0
- data/lib/mongoid/fields.rb +171 -104
- data/lib/mongoid/fields/{serializable → internal}/array.rb +33 -1
- data/lib/mongoid/fields/{serializable → internal}/big_decimal.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/bignum.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/binary.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/boolean.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/date.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/date_time.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/fixnum.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/float.rb +16 -1
- data/lib/mongoid/fields/internal/foreign_keys/array.rb +74 -0
- data/lib/mongoid/fields/{serializable → internal}/foreign_keys/object.rb +11 -2
- data/lib/mongoid/fields/{serializable → internal}/hash.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/integer.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/localized.rb +23 -2
- data/lib/mongoid/fields/{serializable → internal}/nil_class.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/object.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/object_id.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/range.rb +21 -2
- data/lib/mongoid/fields/{serializable → internal}/set.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/string.rb +16 -1
- data/lib/mongoid/fields/{serializable → internal}/symbol.rb +17 -1
- data/lib/mongoid/fields/{serializable → internal}/time.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/time_with_zone.rb +1 -1
- data/lib/mongoid/fields/{serializable → internal}/timekeeping.rb +16 -1
- data/lib/mongoid/fields/mappings.rb +8 -3
- data/lib/mongoid/fields/serializable.rb +34 -3
- data/lib/mongoid/hierarchy.rb +14 -14
- data/lib/mongoid/identity_map.rb +3 -2
- data/lib/mongoid/logger.rb +1 -7
- data/lib/mongoid/named_scope.rb +16 -12
- data/lib/mongoid/observer.rb +5 -1
- data/lib/mongoid/paranoia.rb +1 -0
- data/lib/mongoid/persistence.rb +11 -4
- data/lib/mongoid/persistence/atomic.rb +4 -1
- data/lib/mongoid/persistence/atomic/add_to_set.rb +17 -1
- data/lib/mongoid/persistence/atomic/sets.rb +1 -1
- data/lib/mongoid/railties/database.rake +1 -1
- data/lib/mongoid/relations.rb +1 -3
- data/lib/mongoid/relations/auto_save.rb +1 -1
- data/lib/mongoid/relations/builders.rb +1 -1
- data/lib/mongoid/relations/builders/embedded/many.rb +2 -6
- data/lib/mongoid/relations/builders/nested_attributes/many.rb +1 -1
- data/lib/mongoid/relations/builders/nested_attributes/one.rb +1 -1
- data/lib/mongoid/relations/builders/referenced/many_to_many.rb +1 -1
- data/lib/mongoid/relations/cascading/delete.rb +1 -1
- data/lib/mongoid/relations/cyclic.rb +10 -6
- data/lib/mongoid/relations/embedded/atomic.rb +3 -3
- data/lib/mongoid/relations/embedded/many.rb +98 -20
- data/lib/mongoid/relations/macros.rb +2 -0
- data/lib/mongoid/relations/many.rb +13 -0
- data/lib/mongoid/relations/metadata.rb +3 -3
- data/lib/mongoid/relations/nested_builder.rb +4 -3
- data/lib/mongoid/relations/proxy.rb +0 -1
- data/lib/mongoid/relations/referenced/batch.rb +3 -2
- data/lib/mongoid/relations/referenced/in.rb +3 -3
- data/lib/mongoid/relations/referenced/many.rb +89 -10
- data/lib/mongoid/relations/referenced/many_to_many.rb +34 -43
- data/lib/mongoid/relations/referenced/one.rb +8 -4
- data/lib/mongoid/relations/synchronization.rb +22 -5
- data/lib/mongoid/threaded.rb +38 -276
- data/lib/mongoid/threaded/lifecycle.rb +18 -18
- data/lib/mongoid/timestamps/updated.rb +13 -3
- data/lib/mongoid/validations.rb +22 -1
- data/lib/mongoid/validations/presence.rb +40 -0
- data/lib/mongoid/validations/uniqueness.rb +14 -3
- data/lib/mongoid/version.rb +1 -1
- data/lib/mongoid/versioning.rb +6 -2
- data/lib/rails/mongoid.rb +7 -1
- metadata +64 -45
- data/lib/mongoid/fields/serializable/foreign_keys/array.rb +0 -42
- data/lib/mongoid/relations/embedded/sort.rb +0 -31
data/CHANGELOG.md
CHANGED
@@ -3,173 +3,7 @@
|
|
3
3
|
For instructions on upgrading to newer versions, visit
|
4
4
|
[mongoid.org](http://mongoid.org/docs/upgrading.html).
|
5
5
|
|
6
|
-
## 2.4.
|
7
|
-
|
8
|
-
### Resolved Issues
|
9
|
-
|
10
|
-
* \#1751 Mongoid's logger now responds to level for Ruby logging API
|
11
|
-
compatibility.
|
12
|
-
|
13
|
-
* \#1744/#1750 Sorting works now for localized fields in embedded documents
|
14
|
-
using the criteria API. (Hans Hasselberg)
|
15
|
-
|
16
|
-
* \#1746 Presence validation now shows which locales were empty for
|
17
|
-
localized fields. (Cyril Mougel)
|
18
|
-
|
19
|
-
* \#1727 Allow dot notation in embedded criteria to work on both embeds one
|
20
|
-
and embeds many. (Lyle Underwood)
|
21
|
-
|
22
|
-
* \#1723 Initialize callbacks should cascade through children without needing
|
23
|
-
to determine if the child is changed.
|
24
|
-
|
25
|
-
* \#1715 Serializable hashes are now consistent on inclusion of embedded
|
26
|
-
documents per or post save.
|
27
|
-
|
28
|
-
* \#1713 Fixing === checks when comparing a class with an instance of a
|
29
|
-
subclass.
|
30
|
-
|
31
|
-
* \#1495 Callbacks no longer get the 'super called outside of method` errors on
|
32
|
-
busted 1.8.7 rubies.
|
33
|
-
|
34
|
-
## 2.4.4
|
35
|
-
|
36
|
-
### Resolved Issues
|
37
|
-
|
38
|
-
* \#1705 Allow changing the order of many to many foreign keys.
|
39
|
-
|
40
|
-
* \#1703 Updated at is now versioned again. (Lucas Souza)
|
41
|
-
|
42
|
-
* \#1686 Set the base metadata on unbind as well as bind for belongs to
|
43
|
-
relations.
|
44
|
-
|
45
|
-
* \#1681 Attempt to create indexes for models without namespacing if the
|
46
|
-
namespace does not exist for the subdirectory.
|
47
|
-
|
48
|
-
* \#1676 Allow eager loading to work as a default scope.
|
49
|
-
|
50
|
-
* \#1665/#1672 Expand complex criteria in nested criteria selectors, like
|
51
|
-
#matches. (Hans Hasselberg)
|
52
|
-
|
53
|
-
* \#1668 Ensure Mongoid logger exists before calling warn. (Rémy Coutable)
|
54
|
-
|
55
|
-
* \#1661 Ensure uniqueness validation works on cloned documents.
|
56
|
-
|
57
|
-
* \#1659 Clear delayed atomic sets when resetting the same embedded relation.
|
58
|
-
|
59
|
-
* \#1656/#1657 Don't hit database for uniqueness validation if BOTH scope
|
60
|
-
and attribute hasn't changed. (priyaaank)
|
61
|
-
|
62
|
-
* \#1205/#1642 When limiting fields returned from the database via
|
63
|
-
`Criteria#only` and `Criteria#without` and then subsequently saving
|
64
|
-
the document. Default values no longer override excluded fields.
|
65
|
-
|
66
|
-
## 2.4.3
|
67
|
-
|
68
|
-
### Resolved Issues
|
69
|
-
|
70
|
-
* \#1647 DateTime serialization when already in UTC does not convert to
|
71
|
-
local time.
|
72
|
-
|
73
|
-
* \#1640 Update consumers should be tied to the name of the collection
|
74
|
-
they persist to, not the name of the class.
|
75
|
-
|
76
|
-
* \#1636 Scopes no longer modify parent class scopes when subclassing.
|
77
|
-
(Hans Hasselberg)
|
78
|
-
|
79
|
-
* \#1629 $all and $in criteria on embedded many relations now properly
|
80
|
-
handles regex searches and elements of varying length. (Douwe Maan)
|
81
|
-
|
82
|
-
* \#1623 Default scopes no longer break Mongoid::Versioning.
|
83
|
-
(Hans Hasselberg)
|
84
|
-
|
85
|
-
* \#1605 Fix regression of rescue responses, Rails 3.2
|
86
|
-
|
87
|
-
## 2.4.2
|
88
|
-
|
89
|
-
### Resolved Issues
|
90
|
-
|
91
|
-
* \#1627 Validating format now works properly with localized fields.
|
92
|
-
(Douwe Maan)
|
93
|
-
|
94
|
-
* \#1617 Relation proxy methods now show up in Mongoid's list of
|
95
|
-
prohibited fields.
|
96
|
-
|
97
|
-
* \#1615 Allow a single configuration of host and port for all spec runs,
|
98
|
-
overridden by setting MONGOID_SPEC_HOST and MONGOID_SPEC_PORT env vars.
|
99
|
-
|
100
|
-
* \#1610 When versioning paranoid documents and max version is set, hard
|
101
|
-
delete old versions from the embedded relation.
|
102
|
-
|
103
|
-
* \#1609 Allow connection retry during cursor iteration as well as all other
|
104
|
-
operations.
|
105
|
-
|
106
|
-
* \#1608 Guard against no method errors when passing ids in nested attributes
|
107
|
-
and the documents do not exist.
|
108
|
-
|
109
|
-
* \#1605 Remove deprecation warning on rescue responses, Rails 3.2
|
110
|
-
|
111
|
-
* \#1602 Preserve structure of $and and $or queries when typecasting.
|
112
|
-
|
113
|
-
* \#1600 Uniqueness validation no longer errors when provided a relation.
|
114
|
-
|
115
|
-
* \#1599 Make sure enumerable targets yield to what is in memory first when
|
116
|
-
performing #each, not always the unloaded first.
|
117
|
-
|
118
|
-
* \#1597 Fix the ability to change the order of array fields with the same
|
119
|
-
elements.
|
120
|
-
|
121
|
-
* \#1590 Allow proper serialization of boolean values in criteria where the
|
122
|
-
field is nested inside an array.
|
123
|
-
|
124
|
-
## 2.4.1
|
125
|
-
|
126
|
-
### Resolved Issues
|
127
|
-
|
128
|
-
* \#1593 Arrays on embedded documents now properly atomically update when
|
129
|
-
modified from original version.
|
130
|
-
|
131
|
-
* \#1592 Don't swallow exceptions from index generation in the create_indexes
|
132
|
-
rake task.
|
133
|
-
|
134
|
-
* \#1589 Allow assignment of empty array to HABTM when no documents are yet
|
135
|
-
loaded into memory.
|
136
|
-
|
137
|
-
* \#1587 When a previous value for an array field was an explicit nil, it can
|
138
|
-
now be reset atomically with new values.
|
139
|
-
|
140
|
-
* \#1585 `Model#respond_to?` returns true now for the setter when allowing
|
141
|
-
dynamic fields.
|
142
|
-
|
143
|
-
* \#1582 Allow nil values to be set in arrays.
|
144
|
-
|
145
|
-
* \#1580 Allow arrays to be set to nil post save, and not just empty.
|
146
|
-
|
147
|
-
* \#1579 Don't call #to_a on individual set field elements in criterion.
|
148
|
-
|
149
|
-
* \#1576 Don't hit database on uniqueness validation if the field getting
|
150
|
-
validated has not changed.
|
151
|
-
|
152
|
-
* \#1571 Aliased fields get all the dirty attribute methods and all getters and
|
153
|
-
setters for both the original name and the alias. (Hans Hasselberg)
|
154
|
-
|
155
|
-
* \#1568 Fallback to development environment with warning when no env configured.
|
156
|
-
|
157
|
-
* \#1565 For fields and foreign keys with non-standard Ruby or database names,
|
158
|
-
use define_method instead of class_eval for creating the accessors and
|
159
|
-
dirty methods.
|
160
|
-
|
161
|
-
* \#1557 Internal strategy class no longer conflicts with models.
|
162
|
-
|
163
|
-
* \#1551 Parent documents now return `true` for `Model#changed?` if only child
|
164
|
-
(embedded) documents have changed.
|
165
|
-
|
166
|
-
* \#1547 Resetting persisted children from a parent save when new waits until post
|
167
|
-
callbacks, mirroring update functionality.
|
168
|
-
|
169
|
-
* \#1536 Eager loading now happens when calling `first` or `last` on a
|
170
|
-
criteria if inclusions are specified.
|
171
|
-
|
172
|
-
## 2.4.0
|
6
|
+
## 2.4.0 \[ In Development \] \[ Branch: master \]
|
173
7
|
|
174
8
|
### New Features
|
175
9
|
|
@@ -345,13 +179,6 @@ For instructions on upgrading to newer versions, visit
|
|
345
179
|
|
346
180
|
* \#1255 Ensure embedded documents respect the defined default scope.
|
347
181
|
|
348
|
-
## 2.3.5
|
349
|
-
|
350
|
-
### Resolved Issues
|
351
|
-
|
352
|
-
* \#1751 Mongoid's logger now responds to level for Ruby logging API
|
353
|
-
compatibility.
|
354
|
-
|
355
182
|
## 2.3.4
|
356
183
|
|
357
184
|
* \#1445 Prevent duplicate documents in the loaded array on the target
|
@@ -400,7 +227,6 @@ For instructions on upgrading to newer versions, visit
|
|
400
227
|
* \#791 Root document updates its timestamps when only embedded documents have
|
401
228
|
changed.
|
402
229
|
|
403
|
-
>>>>>>> 5f236a7... Mongoid's logger must respond to level. Fixes #1751.
|
404
230
|
## 2.3.3
|
405
231
|
|
406
232
|
### Resolved Issues
|
@@ -596,7 +422,39 @@ For instructions on upgrading to newer versions, visit
|
|
596
422
|
* Deleting versions created with `Mongoid::Versioning` no longer fires off
|
597
423
|
dependent cascading on relations.
|
598
424
|
|
599
|
-
## 2.2.
|
425
|
+
## 2.2.5
|
426
|
+
|
427
|
+
* This was a small patch release to address 2.2.x Heroku errors during asset
|
428
|
+
compilation.
|
429
|
+
|
430
|
+
## 2.2.4
|
431
|
+
|
432
|
+
* \#1377 Fix aggregation functions to properly handle nil or indefined values.
|
433
|
+
(Maxime Garcia)
|
434
|
+
|
435
|
+
* \#1373 Warn if a scope overrides another scope.
|
436
|
+
|
437
|
+
* \#1372 Never persist when binding inside of a read attribute for validation.
|
438
|
+
|
439
|
+
* \#1358 Fixed type error on many to many synchronization when inverse_of is
|
440
|
+
set to nil.
|
441
|
+
|
442
|
+
* \#1356 $in criteria can now be chained to non-complex criteria on the same
|
443
|
+
key without error.
|
444
|
+
|
445
|
+
* \#1350, \#1351 Fixed errors in the string conversions of double quotes and
|
446
|
+
tilde when paramterizing keys.
|
447
|
+
|
448
|
+
* \#1349 Mongoid documents should not blow up when including Enumerable.
|
449
|
+
(Jonas Nicklas)
|
450
|
+
|
451
|
+
## 2.2.3
|
452
|
+
|
453
|
+
* \#1295 Fixed having multiple includes only execute the eager loading of the first.
|
454
|
+
|
455
|
+
* \#1225 Fixed delayed persistence of embedded documents via $set.
|
456
|
+
|
457
|
+
* \#1002 Fix BSON object id conversion to check if legal first.
|
600
458
|
|
601
459
|
## 2.2.2
|
602
460
|
|
data/LICENSE
CHANGED
@@ -17,4 +17,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
17
17
|
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
18
|
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
19
|
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
-
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/lib/config/locales/bg.yml
CHANGED
@@ -52,3 +52,9 @@ bg:
|
|
52
52
|
mixed_relations:
|
53
53
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
54
54
|
relational association is not allowed since the %{embedded} is embedded.
|
55
|
+
no_environment:
|
56
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
57
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
58
|
+
scope_overwrite:
|
59
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
60
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/de.yml
CHANGED
@@ -52,3 +52,9 @@ de:
|
|
52
52
|
mixed_relations:
|
53
53
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
54
54
|
relational association is not allowed since the %{embedded} is embedded.
|
55
|
+
no_environment:
|
56
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
57
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
58
|
+
scope_overwrite:
|
59
|
+
"Scope :%{scope_name} kann nicht erzeugt werden, da bereits eine Methode
|
60
|
+
%{model_name}.%{scope_name} existiert."
|
@@ -2,6 +2,8 @@ en-GB:
|
|
2
2
|
mongoid:
|
3
3
|
errors:
|
4
4
|
messages:
|
5
|
+
blank:
|
6
|
+
can't be blank
|
5
7
|
taken:
|
6
8
|
is already taken
|
7
9
|
callbacks:
|
@@ -53,3 +55,9 @@ en-GB:
|
|
53
55
|
mixed_relations:
|
54
56
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
55
57
|
relational association is not allowed since the %{embedded} is embedded.
|
58
|
+
no_environment:
|
59
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
60
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
61
|
+
scope_overwrite:
|
62
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
63
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/en.yml
CHANGED
@@ -2,6 +2,8 @@ en:
|
|
2
2
|
mongoid:
|
3
3
|
errors:
|
4
4
|
messages:
|
5
|
+
blank:
|
6
|
+
can't be blank
|
5
7
|
taken:
|
6
8
|
is already taken
|
7
9
|
callbacks:
|
@@ -53,3 +55,9 @@ en:
|
|
53
55
|
mixed_relations:
|
54
56
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
55
57
|
relational association is not allowed since the %{embedded} is embedded.
|
58
|
+
no_environment:
|
59
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
60
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
61
|
+
scope_overwrite:
|
62
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
63
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/es.yml
CHANGED
@@ -29,12 +29,12 @@ es:
|
|
29
29
|
es un documento incrustado, por favor acceda a la colección
|
30
30
|
desde el documento raíz.
|
31
31
|
invalid_field:
|
32
|
-
No está permitido definir un campo con el nombre %{name}. No
|
32
|
+
No está permitido definir un campo con el nombre %{name}. No
|
33
33
|
defina campos que entren en conflicto con los atributos internos o
|
34
34
|
nombres de métodos de Mongoid. Utilice Document#instance_methods para
|
35
35
|
consultar los nombres ya incluidos.
|
36
36
|
too_many_nested_attribute_records:
|
37
|
-
La aceptación de atributos anidados para %{association} está limitada
|
37
|
+
La aceptación de atributos anidados para %{association} está limitada
|
38
38
|
a %{limit} registros.
|
39
39
|
embedded_in_must_have_inverse_of:
|
40
40
|
Las opciones de una asociación embedded_in deben incluir inverse_of.
|
@@ -42,7 +42,7 @@ es:
|
|
42
42
|
La opción dependent => destroy|delete proporcionada
|
43
43
|
sólo es válida en asociaciones references_one o references_many.
|
44
44
|
association_cant_have_inverse_of:
|
45
|
-
No está permitido definir inverse_of en esta asociación. Utilice
|
45
|
+
No está permitido definir inverse_of en esta asociación. Utilice
|
46
46
|
esta opción sólo en embedded_in o en references_many as array.
|
47
47
|
unsaved_document:
|
48
48
|
You cannot call create or create! through a relational association
|
@@ -50,3 +50,9 @@ es:
|
|
50
50
|
mixed_relations:
|
51
51
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
52
52
|
relational association is not allowed since the %{embedded} is embedded.
|
53
|
+
no_environment:
|
54
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
55
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
56
|
+
scope_overwrite:
|
57
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
58
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/fr.yml
CHANGED
@@ -53,3 +53,9 @@ fr:
|
|
53
53
|
mixed_relations:
|
54
54
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
55
55
|
relational association is not allowed since the %{embedded} is embedded.
|
56
|
+
no_environment:
|
57
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
58
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
59
|
+
scope_overwrite:
|
60
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
61
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/hi.yml
CHANGED
@@ -44,3 +44,9 @@ en:
|
|
44
44
|
mixed_relations:
|
45
45
|
"Referencing a(n) %{embedded} document from the %{root} document via a
|
46
46
|
relational association is not allowed since the %{embedded} is embedded."
|
47
|
+
no_environment:
|
48
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
49
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
50
|
+
scope_overwrite:
|
51
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
52
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/hu.yml
CHANGED
@@ -55,3 +55,9 @@ hu:
|
|
55
55
|
mixed_relations:
|
56
56
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
57
57
|
relational association is not allowed since the %{embedded} is embedded.
|
58
|
+
no_environment:
|
59
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
60
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
61
|
+
scope_overwrite:
|
62
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
63
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/id.yml
CHANGED
@@ -53,3 +53,9 @@ id:
|
|
53
53
|
Mereferensi sebuah %{embedded} document dari %{root} dokumen melalui
|
54
54
|
asosiasi relasional tidak diperbolehkan karena %{embedded}
|
55
55
|
adalah dokumen embedded.
|
56
|
+
no_environment:
|
57
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
58
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
59
|
+
scope_overwrite:
|
60
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
61
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/it.yml
CHANGED
@@ -50,3 +50,9 @@ it:
|
|
50
50
|
mixed_relations:
|
51
51
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
52
52
|
relational association is not allowed since the %{embedded} is embedded.
|
53
|
+
no_environment:
|
54
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
55
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
56
|
+
scope_overwrite:
|
57
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
58
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/ja.yml
CHANGED
@@ -48,3 +48,9 @@ ja:
|
|
48
48
|
%{document} の 親ドキュメント (%{base}) は保存されていません。
|
49
49
|
mixed_relations:
|
50
50
|
"%{embedded} ドキュメント に対して %{root} ドキュメントからリレーション関係を用いて、参照することはできません。"
|
51
|
+
no_environment:
|
52
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
53
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
54
|
+
scope_overwrite:
|
55
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
56
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/kr.yml
CHANGED
@@ -45,3 +45,9 @@ kr:
|
|
45
45
|
mixed_relations:
|
46
46
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
47
47
|
relational association is not allowed since the %{embedded} is embedded.
|
48
|
+
no_environment:
|
49
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
50
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
51
|
+
scope_overwrite:
|
52
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
53
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/nl.yml
CHANGED
@@ -2,6 +2,8 @@ nl:
|
|
2
2
|
mongoid:
|
3
3
|
errors:
|
4
4
|
messages:
|
5
|
+
blank:
|
6
|
+
mag niet leeg zijn
|
5
7
|
taken:
|
6
8
|
al in gebruik
|
7
9
|
callbacks:
|
@@ -50,3 +52,9 @@ nl:
|
|
50
52
|
mixed_relations:
|
51
53
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
52
54
|
relational association is not allowed since the %{embedded} is embedded.
|
55
|
+
no_environment:
|
56
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
57
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
58
|
+
scope_overwrite:
|
59
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
60
|
+
%{model_name}.%{scope_name}."
|
data/lib/config/locales/pl.yml
CHANGED
@@ -50,3 +50,9 @@ pl:
|
|
50
50
|
mixed_relations:
|
51
51
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
52
52
|
relational association is not allowed since the %{embedded} is embedded.
|
53
|
+
no_environment:
|
54
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
55
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
56
|
+
scope_overwrite:
|
57
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
58
|
+
%{model_name}.%{scope_name}."
|
@@ -51,3 +51,9 @@ pt-BR:
|
|
51
51
|
mixed_relations:
|
52
52
|
Referencing a(n) %{embedded} document from the %{root} document via a
|
53
53
|
relational association is not allowed since the %{embedded} is embedded.
|
54
|
+
no_environment:
|
55
|
+
"Mongoid attempted to find the appropriate environment but no Rails.env,
|
56
|
+
Sinatra::Base.environment, or RACK_ENV could be found."
|
57
|
+
scope_overwrite:
|
58
|
+
"Cannot create scope :%{scope_name}, because of existing method
|
59
|
+
%{model_name}.%{scope_name}."
|