activefacts 1.2.0 → 1.2.1
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9375bff433eb3d5ca379bb09c75cf61dbf06d0f9
|
4
|
+
data.tar.gz: 0eb5ae1999ee3022eb304366dcff00d0416e5562
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ea7c95187824dcbceb58d036483f63611d1ed079deea269b53b1f52b0a1db53f62fe525c65561bd79aea4592902671dc69d607b84739392eab776bf785c460e6
|
7
|
+
data.tar.gz: ebc6351f9ef09824dd11629be72734cc55f99092c6f4b7e90405ae5aeb062ede4eea0ea7376c1ef8b714bdd36d3f75061f3d046e808c1b9dff987dc992d8fa67
|
@@ -131,7 +131,7 @@ module ActiveFacts
|
|
131
131
|
|
132
132
|
# Subset constraint using "A only if B" syntax
|
133
133
|
rule a_only_if_b
|
134
|
-
s clauses s only s if s r2:
|
134
|
+
s clauses:query_clauses s only s if s r2:query_clauses s c:context_note? enforcement ';'
|
135
135
|
end
|
136
136
|
|
137
137
|
rule only_if
|
@@ -122,12 +122,14 @@ module ActiveFacts
|
|
122
122
|
table.foreign_keys.map do |fk|
|
123
123
|
association_name = fk.rails_from_association_name
|
124
124
|
|
125
|
-
foreign_key = ""
|
126
125
|
if association_name != fk.to.rails_singular_name
|
127
126
|
# A different class_name is implied, emit an explicit one:
|
128
127
|
class_name = ", :class_name => '#{fk.to.rails_class_name}'"
|
129
|
-
|
130
|
-
|
128
|
+
end
|
129
|
+
foreign_key = ", :foreign_key => :#{fk.from_columns[0].rails_name}"
|
130
|
+
if foreign_key == fk.to.rails_singular_name+'_id'
|
131
|
+
# See lib/active_record/reflection.rb, method #derive_foreign_key
|
132
|
+
foreign_key = ''
|
131
133
|
end
|
132
134
|
|
133
135
|
%Q{
|
data/lib/activefacts/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activefacts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Clifford Heath
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activefacts-api
|