criteria_operator-ui_component 0.2.1 → 0.2.2
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
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5df43b494f1d8c12c418c8bf7de70991f67e8b7c
|
|
4
|
+
data.tar.gz: 759434c28b1944a01d3184c21f9a105499693b56
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 97e8c0ac85db87d23dfc218605d7c698c5031186f02ab1cf9071bc76044c4385a8e25cd77cc4c9c48772c6af242b81fe4b516865cfa3c95b47ae1e1902371bda
|
|
7
|
+
data.tar.gz: 2eece0daaacbf20b16aa771aa224c35d57b3117fa9a3cf2df6bf429cf3886bc01bb189fee25ecdf8392a4639a6327a1fa73990d0ad055311da104ac26da76b1a
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<div class="criteria_editor">
|
|
2
2
|
<span class="criteria_editor_header">This is the header</span>
|
|
3
3
|
<%= cell('criteria_operator/ui_component/group', model).(:show, allow_delete: false) %>
|
|
4
|
-
<input type="hidden" class="criteria_editor_root_operator" value="<%= serialized_operator %>" />
|
|
4
|
+
<input type="hidden" id="<%= input_id %>" name="<%= input_name %>" class="criteria_editor_root_operator" value="<%= serialized_operator %>" />
|
|
5
5
|
</div>
|
|
@@ -4,7 +4,10 @@ module CriteriaOperator
|
|
|
4
4
|
module UiComponent
|
|
5
5
|
class CriteriaEditorCell < BaseCell
|
|
6
6
|
|
|
7
|
-
def show
|
|
7
|
+
def show(options = {})
|
|
8
|
+
@input_id = options[:id] if options.has_key? :id
|
|
9
|
+
@input_name = options[:name] if options.has_key? :name
|
|
10
|
+
# TODO: provide support for read_only
|
|
8
11
|
render
|
|
9
12
|
end
|
|
10
13
|
|
|
@@ -18,6 +21,14 @@ module CriteriaOperator
|
|
|
18
21
|
|
|
19
22
|
private
|
|
20
23
|
|
|
24
|
+
def input_id
|
|
25
|
+
@input_id
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
def input_name
|
|
29
|
+
@input_name
|
|
30
|
+
end
|
|
31
|
+
|
|
21
32
|
def serialized_operator
|
|
22
33
|
YAML.dump(model) if model.is_a? BaseOperator
|
|
23
34
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: criteria_operator-ui_component
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Florian Koch
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-07-
|
|
11
|
+
date: 2017-07-21 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|