merrymenu 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/merrymenu/config.rb +2 -1
- data/lib/merrymenu/logger.rb +9 -0
- data/lib/merrymenu/railtie.rb +1 -0
- data/lib/merrymenu/version.rb +1 -1
- data/lib/merrymenu/view_helper.rb +6 -3
- metadata +13 -12
data/lib/merrymenu/config.rb
CHANGED
@@ -15,10 +15,11 @@ module Merrymenu
|
|
15
15
|
|
16
16
|
class Configuration #:nodoc:
|
17
17
|
include ActiveSupport::Configurable
|
18
|
-
config_accessor :use_I18n_translation
|
18
|
+
config_accessor :use_I18n_translation, :debug
|
19
19
|
end
|
20
20
|
|
21
21
|
configure do |config|
|
22
22
|
config.use_I18n_translation = false
|
23
|
+
config.debug = false
|
23
24
|
end
|
24
25
|
end
|
data/lib/merrymenu/railtie.rb
CHANGED
data/lib/merrymenu/version.rb
CHANGED
@@ -36,11 +36,14 @@ module Merrymenu
|
|
36
36
|
end
|
37
37
|
|
38
38
|
def current_controller?(tab)
|
39
|
-
pattern = tab.url
|
39
|
+
pattern = tab.url
|
40
|
+
LOG.debug("[MM] PATTERN : #{pattern}")
|
41
|
+
LOG.debug("[MM] CONTROLLER PATH : #{pattern}")
|
42
|
+
|
40
43
|
if tab.exact_match
|
41
|
-
result = controller.
|
44
|
+
result = controller.request.path =~ /^#{pattern}$/
|
42
45
|
else
|
43
|
-
result = controller.
|
46
|
+
result = controller.request.path =~ /^#{pattern}/
|
44
47
|
end
|
45
48
|
return true unless result.nil?
|
46
49
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: merrymenu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2011-11-
|
12
|
+
date: 2011-11-23 00:00:00.000000000Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
16
|
-
requirement: &
|
16
|
+
requirement: &70323341654040 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ~>
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 3.1.1
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *70323341654040
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: rspec-rails
|
27
|
-
requirement: &
|
27
|
+
requirement: &70323341652760 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ~>
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '2.5'
|
33
33
|
type: :development
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *70323341652760
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: sqlite3
|
38
|
-
requirement: &
|
38
|
+
requirement: &70323341651960 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: '0'
|
44
44
|
type: :development
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *70323341651960
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: factory_girl_rails
|
49
|
-
requirement: &
|
49
|
+
requirement: &70323341649140 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ~>
|
@@ -54,7 +54,7 @@ dependencies:
|
|
54
54
|
version: '1.2'
|
55
55
|
type: :development
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *70323341649140
|
58
58
|
description: Rails plugin to build a configurable html menu
|
59
59
|
email:
|
60
60
|
- franck.dagostini@gmail.com
|
@@ -67,6 +67,7 @@ files:
|
|
67
67
|
- lib/generators/merrymenu/templates/merrymenu_config.rb
|
68
68
|
- lib/merrymenu/builder.rb
|
69
69
|
- lib/merrymenu/config.rb
|
70
|
+
- lib/merrymenu/logger.rb
|
70
71
|
- lib/merrymenu/railtie.rb
|
71
72
|
- lib/merrymenu/version.rb
|
72
73
|
- lib/merrymenu/view_helper.rb
|
@@ -89,7 +90,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
89
90
|
version: '0'
|
90
91
|
segments:
|
91
92
|
- 0
|
92
|
-
hash:
|
93
|
+
hash: -1385742055713331012
|
93
94
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
94
95
|
none: false
|
95
96
|
requirements:
|
@@ -98,7 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
98
99
|
version: '0'
|
99
100
|
segments:
|
100
101
|
- 0
|
101
|
-
hash:
|
102
|
+
hash: -1385742055713331012
|
102
103
|
requirements: []
|
103
104
|
rubyforge_project:
|
104
105
|
rubygems_version: 1.8.11
|