gloo 3.10.1 → 3.11.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 +4 -4
- data/lib/VERSION +1 -1
- data/lib/VERSION_NOTES +6 -0
- data/lib/gloo/objs/data/query.rb +1 -0
- data/lib/gloo/objs/data/query_result.rb +1 -0
- data/lib/gloo/objs/data/table.rb +15 -0
- data/lib/gloo/web_svr/table_renderer.rb +4 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1cda013b56c2461ca6215fd49ba94a30fae35dd356c470a6b4e8a3e5f8783ce8
|
4
|
+
data.tar.gz: c2531fc5cfbc93e1c9b6bab60e39cce92bcc09c6408a9eb59abceb6eaf4a693d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 622a50944de102154e63d5cd699f6325f1d0ba5f172353d1692c0e8cb1e1f02a871cb860cabc2c2ca043f6e0c971876a46c263f0785c28dffb2270ae665957b5
|
7
|
+
data.tar.gz: d7fe6d117211d1d143a7a85620f834e434250fde09120c41feea5f65ee9e04fc6e35f19c1e75e36f8f894689c4c7520ec80e335cd3be0f6183e1960a2b242594
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.
|
1
|
+
3.11.0
|
data/lib/VERSION_NOTES
CHANGED
data/lib/gloo/objs/data/query.rb
CHANGED
data/lib/gloo/objs/data/table.rb
CHANGED
@@ -15,6 +15,7 @@ module Gloo
|
|
15
15
|
DATA = 'data'.freeze
|
16
16
|
CELLS = 'cells'.freeze
|
17
17
|
STYLES = 'styles'.freeze
|
18
|
+
ALWAYS_ROWS = 'always_rows'.freeze
|
18
19
|
|
19
20
|
#
|
20
21
|
# The name of the object type.
|
@@ -41,6 +42,16 @@ module Gloo
|
|
41
42
|
return o.children.map( &:value )
|
42
43
|
end
|
43
44
|
|
45
|
+
#
|
46
|
+
# Always show rows, even if only 1 row is found.
|
47
|
+
#
|
48
|
+
def always_rows
|
49
|
+
o = find_child ALWAYS_ROWS
|
50
|
+
|
51
|
+
return false unless o
|
52
|
+
return o.value
|
53
|
+
end
|
54
|
+
|
44
55
|
#
|
45
56
|
# Get the list of column names.
|
46
57
|
# Returns nil if there is none.
|
@@ -193,6 +204,10 @@ module Gloo
|
|
193
204
|
cell_renderers: self.cell_renderers
|
194
205
|
}
|
195
206
|
|
207
|
+
if self.always_rows
|
208
|
+
params[ :always_rows ] = true
|
209
|
+
end
|
210
|
+
|
196
211
|
helper = Gloo::WebSvr::TableRenderer.new( @engine )
|
197
212
|
return helper.data_to_table params
|
198
213
|
rescue => e
|
@@ -44,10 +44,13 @@ module Gloo
|
|
44
44
|
#
|
45
45
|
def data_to_table params
|
46
46
|
data = params[ :rows ]
|
47
|
+
|
48
|
+
single_row = true if ( data.length == 1 )
|
49
|
+
single_row = false if params[ :always_rows ]
|
47
50
|
|
48
51
|
if data.nil? || ( data.length == 0 )
|
49
52
|
return "<p>No data found.</p>"
|
50
|
-
elsif
|
53
|
+
elsif single_row
|
51
54
|
return data_to_single_row_table( params )
|
52
55
|
else
|
53
56
|
return data_to_table_rows( params )
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gloo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.11.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Crane
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-
|
11
|
+
date: 2025-04-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|