rooler 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/app/controllers/rooler/templates_controller.rb +3 -0
- data/app/helpers/rooler/application_helper.rb +6 -5
- data/app/models/rooler/liquid_inspector.rb +3 -3
- data/app/models/rooler/template.rb +0 -2
- data/app/views/rooler/templates/_form.html.erb +2 -0
- data/lib/rooler.rb +1 -0
- data/lib/rooler/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZmIxMGNkZDhjMjQ5MGYzMGE3ODkxMmViZTE2OGRjNWE5YjM2MzY5Mw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YWQzNGVlNDY1NTFiOTY4YTFlYTBiM2U0MDQ4ZTY4YzYxM2IzZWIyYw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MmVhZDljODc1ZmViZWY5ZTgyN2FlOTVjMDNmMjI0ZmFjODEyZmMzNTVkNzY3
|
10
|
+
OWQxNWU3NGNjMzY4MTY2MjcwN2M2MWE1OWFhMTdlYzQ1OWUyNjUyMWY0MDNj
|
11
|
+
YzhlYWIyNjIyY2EzZDAwNmRkMTQzYTc1MzQ3YWQzMTNmOTgyZGM=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
MWIwZmUxYWIyNzVmNTA2NWJjMzcwYTE0MDBiZWU0NTBhNzVhODExMTZkNzM4
|
14
|
+
ZGNiNGNjZTE3ODJlMzcyYzk2MjVmMGEwZjE4MDgxNzYxN2Q0NDdlOTg1YWEx
|
15
|
+
NjBiNWFlYmIxYzE0NjIyY2E0MjMyMjM5MmZmNmExMjc4NWE0ZGY=
|
@@ -2,6 +2,9 @@ require_dependency "rooler/application_controller"
|
|
2
2
|
|
3
3
|
module Rooler
|
4
4
|
class TemplatesController < ApplicationController
|
5
|
+
helper ApplicationHelper
|
6
|
+
include ApplicationHelper
|
7
|
+
|
5
8
|
before_action :set_template, only: [:test, :show, :edit, :update, :destroy]
|
6
9
|
|
7
10
|
def test
|
@@ -5,11 +5,12 @@ module Rooler
|
|
5
5
|
Liquid::Template.parse(content).render(arguments, :filters => [Rooler::LiquidFilters]).html_safe
|
6
6
|
end
|
7
7
|
|
8
|
-
def
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
8
|
+
def render_tree(tree)
|
9
|
+
res = "<ul>"
|
10
|
+
res << "<li>#{tree.name}"
|
11
|
+
tree.children.each {|child| res << render_tree(child)}
|
12
|
+
res << "</li></ul>"
|
13
|
+
res
|
13
14
|
end
|
14
15
|
|
15
16
|
end
|
@@ -1,5 +1,3 @@
|
|
1
|
-
require 'rubytree'
|
2
|
-
|
3
1
|
module Rooler
|
4
2
|
class LiquidInspector
|
5
3
|
|
@@ -38,7 +36,9 @@ module Rooler
|
|
38
36
|
|
39
37
|
|
40
38
|
def liquid_methods(klass)
|
41
|
-
klass
|
39
|
+
if klass.const_defined?(LiquidDropClass)
|
40
|
+
return klass::LiquidDropClass.public_instance_methods.map(&:to_sym) - ::Liquid::Drop.public_instance_methods.map(&:to_sym)
|
41
|
+
end
|
42
42
|
end
|
43
43
|
|
44
44
|
end
|
data/lib/rooler.rb
CHANGED
data/lib/rooler/version.rb
CHANGED