phlexi-form 0.5.5 → 0.5.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/phlexi/form/base.rb +2 -2
- data/lib/phlexi/form/structure/namespace_collection.rb +3 -1
- data/lib/phlexi/form/version.rb +1 -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: b9671f4f7fcb1593070bf2544eb6245cdcdf7fda5565a4596a0dd6a6849bc1e7
|
4
|
+
data.tar.gz: 541f135bab202a68032c4c77200fc8a9089db71fef4cab768b172f35bfd440e4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 249664388de34b3295df4a9889088c1faa0ac5ba6a6405561798c40a1473f74e3c73fc61d5db4854d6acb49948064d214fd7a722f8d3d7af2253cf83f98c9717
|
7
|
+
data.tar.gz: 84956947661e1b7f8f69134bd08302a74f7af64544aed0c1d2bee95ddde8ff788015c5e1cb3496acae1c6bc841f273afef2b936de6e1bbb3ccc58dd189c08583
|
data/lib/phlexi/form/base.rb
CHANGED
@@ -105,11 +105,11 @@ module Phlexi
|
|
105
105
|
yield if block_given?
|
106
106
|
end
|
107
107
|
|
108
|
-
def extract_input(params)
|
108
|
+
def extract_input(params, view_context: nil)
|
109
109
|
params = params.to_unsafe_h if params.respond_to?(:to_unsafe_h)
|
110
110
|
params = {} unless params.is_a?(Hash)
|
111
111
|
|
112
|
-
call unless @_rendered
|
112
|
+
call(view_context: view_context) unless @_rendered
|
113
113
|
@namespace.extract_input(params)
|
114
114
|
end
|
115
115
|
|
@@ -10,7 +10,9 @@ module Phlexi
|
|
10
10
|
namespace = build_namespace(0)
|
11
11
|
@block.call(namespace)
|
12
12
|
|
13
|
-
|
13
|
+
params = params[key]
|
14
|
+
params = params.values if params.is_a?(Hash)
|
15
|
+
inputs = params.map { |param| namespace.extract_input([param]) }
|
14
16
|
{key => inputs}
|
15
17
|
end
|
16
18
|
end
|
data/lib/phlexi/form/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: phlexi-form
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stefan Froelich
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-11-
|
11
|
+
date: 2024-11-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: phlex
|