activefacts-metamodel 1.9.18 → 1.9.19
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/activefacts/metamodel/datatypes.rb +11 -1
- data/lib/activefacts/metamodel/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eeb83d74101d461d8cf6f2c2bdf328f0360e9801
|
4
|
+
data.tar.gz: 46578f35a2a40c566794efd96d0ce44b48ee3c1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: df0dd4afd63eb21922ad711eb859cf39e7f79e8c2169563a2ca70b6283ca7340e2c9bf64032868060a88c277cf73a92553df31bfcd4c02cc26a1addf947af3a4
|
7
|
+
data.tar.gz: cd90076037d3854b08623c431c609456bb1d4bbdc8381e0ba3b5ffafa502e711981a185fd239473107f88ff3484bab3b621c1da36e0db31dc4fbe87701b0785e
|
@@ -234,11 +234,21 @@ module ActiveFacts
|
|
234
234
|
value_constraint = narrow_value_constraint(value_constraint, vt.value_constraint)
|
235
235
|
end
|
236
236
|
end while stype = vt.supertype
|
237
|
+
auto_assign =
|
238
|
+
if is_auto_assigned
|
239
|
+
if in_primary_index and !in_foreign_key
|
240
|
+
{auto_assign: is_auto_assigned} # It's auto-assigned here
|
241
|
+
else
|
242
|
+
{auto_assign: nil} # It's auto-assigned elsewhere
|
243
|
+
end
|
244
|
+
else
|
245
|
+
{} # It's not auto-assigned
|
246
|
+
end
|
237
247
|
|
238
248
|
[ vt.name,
|
239
249
|
(length ? {length: length} : {}).
|
240
250
|
merge!(scale ? {scale: scale} : {}).
|
241
|
-
merge!(
|
251
|
+
merge!(auto_assign).
|
242
252
|
merge!({mandatory: path_mandatory}).
|
243
253
|
merge!(value_constraint ? {value_constraint: value_constraint} : {})
|
244
254
|
]
|