forest_admin_agent 1.44.5 → 1.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b82038f1c254bc91295ded423735b4f481a3c0b997d4c246d606396ad476acec
|
|
4
|
+
data.tar.gz: 8bae29e2cbb6d1af5b9ebf4228a918eaace4b5489e26aa1ba7a098856da3bb38
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 336ea0d4c27df5a65ed30f6d5e64fd2a4645ae229a9fb874ea21b2c5501cef641c3a18bd91736cb52ed3b0b085dffbe9aa2f17f59471efcf62ab0fcd3ca3dfb4
|
|
7
|
+
data.tar.gz: 637d76398dc40a32ec459bb3ae3bdd783c82665a272988185efa1229823639f2cc64b564dbc7be6f1248f31a39f23af241d29bf636d1f48c4b0a7e0306826a55
|
|
@@ -68,6 +68,12 @@ module ForestAdminAgent
|
|
|
68
68
|
}
|
|
69
69
|
end
|
|
70
70
|
|
|
71
|
+
def relation_filterable?(relation, foreign_collection)
|
|
72
|
+
return false if relation.respond_to?(:is_filterable) && relation.is_filterable == false
|
|
73
|
+
|
|
74
|
+
foreign_collection_filterable?(foreign_collection)
|
|
75
|
+
end
|
|
76
|
+
|
|
71
77
|
def foreign_collection_filterable?(foreign_collection)
|
|
72
78
|
foreign_collection.schema[:fields].values.any? do |field|
|
|
73
79
|
field.type == 'Column' && FrontendFilterable.filterable?(field.filter_operators)
|
|
@@ -124,7 +130,7 @@ module ForestAdminAgent
|
|
|
124
130
|
{
|
|
125
131
|
type: key_field.column_type,
|
|
126
132
|
defaultValue: nil,
|
|
127
|
-
isFilterable:
|
|
133
|
+
isFilterable: relation_filterable?(relation, foreign_collection),
|
|
128
134
|
isPrimaryKey: false,
|
|
129
135
|
isRequired: false,
|
|
130
136
|
isReadOnly: relation.is_read_only || key_field.is_read_only,
|
|
@@ -142,7 +148,7 @@ module ForestAdminAgent
|
|
|
142
148
|
{
|
|
143
149
|
type: key_field.column_type,
|
|
144
150
|
defaultValue: key_field.default_value,
|
|
145
|
-
isFilterable:
|
|
151
|
+
isFilterable: relation_filterable?(relation, foreign_collection),
|
|
146
152
|
isPrimaryKey: false,
|
|
147
153
|
isRequired: key_field.validation.any? { |v| v[:operator] == 'Present' },
|
|
148
154
|
isReadOnly: key_field.is_read_only,
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: forest_admin_agent
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.45.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matthieu
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: exe
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2026-10-
|
|
12
|
+
date: 2026-10-07 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: activesupport
|