app_frame 0.5.5 → 0.5.6
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.
- data/Gemfile +3 -3
- data/Gemfile.lock +109 -78
- data/VERSION +1 -1
- data/app/helpers/app_frame/bootstrap_helper.rb +1 -2
- data/app/helpers/app_frame/resources_helper.rb +0 -6
- data/app/views/application/_page_header.html.haml +1 -0
- data/app/views/application/edit.html.haml +4 -2
- data/app/views/application/index.html.haml +4 -1
- data/app/views/application/new.html.haml +3 -1
- data/app/views/application/show.html.haml +3 -1
- data/app/views/layouts/app_frame/default.html.haml +4 -0
- data/app_frame.gemspec +12 -11
- data/lib/app_frame/controller_methods.rb +15 -5
- metadata +10 -9
data/Gemfile
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
source "http://rubygems.org"
|
|
2
2
|
|
|
3
|
-
gem 'bootstrap-sass', '~> 2.3.1
|
|
3
|
+
gem 'bootstrap-sass', '~> 2.3.2.1'
|
|
4
4
|
gem 'devise'
|
|
5
5
|
gem 'display_for', '0.1.12'
|
|
6
6
|
gem 'haml-rails'
|
|
@@ -17,10 +17,10 @@ gem 'squeel'
|
|
|
17
17
|
# Add dependencies to develop your gem here.
|
|
18
18
|
# Include everything needed to run rake, tests, features, etc.
|
|
19
19
|
group :test, :development do
|
|
20
|
-
gem "rails", "~> 3.2.
|
|
20
|
+
gem "rails", "~> 3.2.14"
|
|
21
21
|
gem "rspec-rails"
|
|
22
22
|
gem "bundler", '~> 1.3.4'
|
|
23
|
-
gem "jeweler", "~> 1.8.
|
|
23
|
+
gem "jeweler", "~> 1.8.7"
|
|
24
24
|
gem "simplecov"
|
|
25
25
|
gem 'log_buddy'
|
|
26
26
|
end
|
data/Gemfile.lock
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
GIT
|
|
2
2
|
remote: git://github.com/ryanb/nested_form.git
|
|
3
|
-
revision:
|
|
3
|
+
revision: 42028bc06e72a848d297edc1467a969a7c9def57
|
|
4
4
|
specs:
|
|
5
|
-
nested_form (0.3.
|
|
5
|
+
nested_form (0.3.2)
|
|
6
6
|
|
|
7
7
|
GEM
|
|
8
8
|
remote: http://rubygems.org/
|
|
9
9
|
specs:
|
|
10
|
-
actionmailer (3.2.
|
|
11
|
-
actionpack (= 3.2.
|
|
12
|
-
mail (~> 2.5.
|
|
13
|
-
actionpack (3.2.
|
|
14
|
-
activemodel (= 3.2.
|
|
15
|
-
activesupport (= 3.2.
|
|
10
|
+
actionmailer (3.2.14)
|
|
11
|
+
actionpack (= 3.2.14)
|
|
12
|
+
mail (~> 2.5.4)
|
|
13
|
+
actionpack (3.2.14)
|
|
14
|
+
activemodel (= 3.2.14)
|
|
15
|
+
activesupport (= 3.2.14)
|
|
16
16
|
builder (~> 3.0.0)
|
|
17
17
|
erubis (~> 2.7.0)
|
|
18
18
|
journey (~> 1.0.4)
|
|
@@ -20,69 +20,100 @@ GEM
|
|
|
20
20
|
rack-cache (~> 1.2)
|
|
21
21
|
rack-test (~> 0.6.1)
|
|
22
22
|
sprockets (~> 2.2.1)
|
|
23
|
-
activemodel (3.2.
|
|
24
|
-
activesupport (= 3.2.
|
|
23
|
+
activemodel (3.2.14)
|
|
24
|
+
activesupport (= 3.2.14)
|
|
25
25
|
builder (~> 3.0.0)
|
|
26
|
-
activerecord (3.2.
|
|
27
|
-
activemodel (= 3.2.
|
|
28
|
-
activesupport (= 3.2.
|
|
26
|
+
activerecord (3.2.14)
|
|
27
|
+
activemodel (= 3.2.14)
|
|
28
|
+
activesupport (= 3.2.14)
|
|
29
29
|
arel (~> 3.0.2)
|
|
30
30
|
tzinfo (~> 0.3.29)
|
|
31
|
-
activeresource (3.2.
|
|
32
|
-
activemodel (= 3.2.
|
|
33
|
-
activesupport (= 3.2.
|
|
34
|
-
activesupport (3.2.
|
|
35
|
-
i18n (
|
|
31
|
+
activeresource (3.2.14)
|
|
32
|
+
activemodel (= 3.2.14)
|
|
33
|
+
activesupport (= 3.2.14)
|
|
34
|
+
activesupport (3.2.14)
|
|
35
|
+
i18n (~> 0.6, >= 0.6.4)
|
|
36
36
|
multi_json (~> 1.0)
|
|
37
|
+
addressable (2.3.5)
|
|
37
38
|
arel (3.0.2)
|
|
38
|
-
bcrypt-ruby (3.
|
|
39
|
-
bootstrap-sass (2.3.1
|
|
39
|
+
bcrypt-ruby (3.1.1)
|
|
40
|
+
bootstrap-sass (2.3.2.1)
|
|
40
41
|
sass (~> 3.2)
|
|
41
42
|
builder (3.0.4)
|
|
42
|
-
devise (
|
|
43
|
+
devise (3.0.3)
|
|
43
44
|
bcrypt-ruby (~> 3.0)
|
|
44
45
|
orm_adapter (~> 0.1)
|
|
45
|
-
railties (
|
|
46
|
-
warden (~> 1.2.
|
|
47
|
-
diff-lcs (1.
|
|
46
|
+
railties (>= 3.2.6, < 5)
|
|
47
|
+
warden (~> 1.2.3)
|
|
48
|
+
diff-lcs (1.2.4)
|
|
48
49
|
display_for (0.1.12)
|
|
49
50
|
erubis (2.7.0)
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
51
|
+
faraday (0.8.8)
|
|
52
|
+
multipart-post (~> 1.2.0)
|
|
53
|
+
git (1.2.6)
|
|
54
|
+
github_api (0.10.1)
|
|
55
|
+
addressable
|
|
56
|
+
faraday (~> 0.8.1)
|
|
57
|
+
hashie (>= 1.2)
|
|
58
|
+
multi_json (~> 1.4)
|
|
59
|
+
nokogiri (~> 1.5.2)
|
|
60
|
+
oauth2
|
|
61
|
+
haml (4.0.3)
|
|
62
|
+
tilt
|
|
63
|
+
haml-rails (0.4)
|
|
53
64
|
actionpack (>= 3.1, < 4.1)
|
|
54
65
|
activesupport (>= 3.1, < 4.1)
|
|
55
|
-
haml (
|
|
66
|
+
haml (>= 3.1, < 4.1)
|
|
56
67
|
railties (>= 3.1, < 4.1)
|
|
57
|
-
has_scope (0.
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
68
|
+
has_scope (0.6.0.rc)
|
|
69
|
+
actionpack (>= 3.2, < 5)
|
|
70
|
+
activesupport (>= 3.2, < 5)
|
|
71
|
+
hashie (2.0.5)
|
|
72
|
+
highline (1.6.19)
|
|
73
|
+
hike (1.2.3)
|
|
74
|
+
httpauth (0.2.0)
|
|
75
|
+
i18n (0.6.5)
|
|
76
|
+
inherited_resources (1.4.1)
|
|
77
|
+
has_scope (~> 0.6.0.rc)
|
|
78
|
+
responders (~> 1.0.0.rc)
|
|
79
|
+
jeweler (1.8.7)
|
|
80
|
+
builder
|
|
64
81
|
bundler (~> 1.0)
|
|
65
82
|
git (>= 1.2.5)
|
|
83
|
+
github_api (= 0.10.1)
|
|
84
|
+
highline (>= 1.6.15)
|
|
85
|
+
nokogiri (= 1.5.10)
|
|
66
86
|
rake
|
|
67
87
|
rdoc
|
|
68
88
|
journey (1.0.4)
|
|
69
|
-
json (1.
|
|
89
|
+
json (1.8.0)
|
|
90
|
+
jwt (0.1.8)
|
|
91
|
+
multi_json (>= 1.5)
|
|
70
92
|
kaminari (0.14.1)
|
|
71
93
|
actionpack (>= 3.0.0)
|
|
72
94
|
activesupport (>= 3.0.0)
|
|
73
95
|
log_buddy (0.7.0)
|
|
74
|
-
mail (2.5.
|
|
75
|
-
i18n (>= 0.4.0)
|
|
96
|
+
mail (2.5.4)
|
|
76
97
|
mime-types (~> 1.16)
|
|
77
98
|
treetop (~> 1.4.8)
|
|
78
|
-
mime-types (1.
|
|
79
|
-
multi_json (1.7.
|
|
99
|
+
mime-types (1.24)
|
|
100
|
+
multi_json (1.7.9)
|
|
101
|
+
multi_xml (0.5.5)
|
|
102
|
+
multipart-post (1.2.0)
|
|
80
103
|
nested_set (1.7.1)
|
|
81
104
|
activerecord (>= 3.0.0)
|
|
82
105
|
railties (>= 3.0.0)
|
|
106
|
+
nokogiri (1.5.10)
|
|
107
|
+
oauth2 (0.9.2)
|
|
108
|
+
faraday (~> 0.8)
|
|
109
|
+
httpauth (~> 0.2)
|
|
110
|
+
jwt (~> 0.1.4)
|
|
111
|
+
multi_json (~> 1.0)
|
|
112
|
+
multi_xml (~> 0.5)
|
|
113
|
+
rack (~> 1.2)
|
|
83
114
|
orm_adapter (0.4.0)
|
|
84
|
-
polyamorous (0.
|
|
85
|
-
activerecord (
|
|
115
|
+
polyamorous (0.6.3)
|
|
116
|
+
activerecord (>= 3.0)
|
|
86
117
|
polyglot (0.3.3)
|
|
87
118
|
rack (1.4.5)
|
|
88
119
|
rack-cache (1.2)
|
|
@@ -91,47 +122,47 @@ GEM
|
|
|
91
122
|
rack
|
|
92
123
|
rack-test (0.6.2)
|
|
93
124
|
rack (>= 1.0)
|
|
94
|
-
rails (3.2.
|
|
95
|
-
actionmailer (= 3.2.
|
|
96
|
-
actionpack (= 3.2.
|
|
97
|
-
activerecord (= 3.2.
|
|
98
|
-
activeresource (= 3.2.
|
|
99
|
-
activesupport (= 3.2.
|
|
125
|
+
rails (3.2.14)
|
|
126
|
+
actionmailer (= 3.2.14)
|
|
127
|
+
actionpack (= 3.2.14)
|
|
128
|
+
activerecord (= 3.2.14)
|
|
129
|
+
activeresource (= 3.2.14)
|
|
130
|
+
activesupport (= 3.2.14)
|
|
100
131
|
bundler (~> 1.0)
|
|
101
|
-
railties (= 3.2.
|
|
102
|
-
railties (3.2.
|
|
103
|
-
actionpack (= 3.2.
|
|
104
|
-
activesupport (= 3.2.
|
|
132
|
+
railties (= 3.2.14)
|
|
133
|
+
railties (3.2.14)
|
|
134
|
+
actionpack (= 3.2.14)
|
|
135
|
+
activesupport (= 3.2.14)
|
|
105
136
|
rack-ssl (~> 1.3.2)
|
|
106
137
|
rake (>= 0.8.7)
|
|
107
138
|
rdoc (~> 3.4)
|
|
108
139
|
thor (>= 0.14.6, < 2.0)
|
|
109
|
-
rake (10.0
|
|
140
|
+
rake (10.1.0)
|
|
110
141
|
rdoc (3.12.2)
|
|
111
142
|
json (~> 1.4)
|
|
112
|
-
responders (0.
|
|
113
|
-
railties (
|
|
114
|
-
rspec-core (2.
|
|
115
|
-
rspec-expectations (2.
|
|
116
|
-
diff-lcs (
|
|
117
|
-
rspec-mocks (2.
|
|
118
|
-
rspec-rails (2.
|
|
143
|
+
responders (1.0.0.rc)
|
|
144
|
+
railties (>= 3.2, < 5)
|
|
145
|
+
rspec-core (2.14.5)
|
|
146
|
+
rspec-expectations (2.14.2)
|
|
147
|
+
diff-lcs (>= 1.1.3, < 2.0)
|
|
148
|
+
rspec-mocks (2.14.3)
|
|
149
|
+
rspec-rails (2.14.0)
|
|
119
150
|
actionpack (>= 3.0)
|
|
120
151
|
activesupport (>= 3.0)
|
|
121
152
|
railties (>= 3.0)
|
|
122
|
-
rspec-core (~> 2.
|
|
123
|
-
rspec-expectations (~> 2.
|
|
124
|
-
rspec-mocks (~> 2.
|
|
125
|
-
sass (3.2.
|
|
153
|
+
rspec-core (~> 2.14.0)
|
|
154
|
+
rspec-expectations (~> 2.14.0)
|
|
155
|
+
rspec-mocks (~> 2.14.0)
|
|
156
|
+
sass (3.2.10)
|
|
126
157
|
sass-rails (3.2.6)
|
|
127
158
|
railties (~> 3.2.0)
|
|
128
159
|
sass (>= 3.1.10)
|
|
129
160
|
tilt (~> 1.3)
|
|
130
|
-
select2-rails (3.
|
|
131
|
-
sass-rails
|
|
161
|
+
select2-rails (3.4.8)
|
|
162
|
+
sass-rails
|
|
132
163
|
thor (~> 0.14)
|
|
133
164
|
settingslogic (2.0.9)
|
|
134
|
-
simple_form (2.0
|
|
165
|
+
simple_form (2.1.0)
|
|
135
166
|
actionpack (~> 3.0)
|
|
136
167
|
activemodel (~> 3.0)
|
|
137
168
|
simplecov (0.7.1)
|
|
@@ -143,35 +174,35 @@ GEM
|
|
|
143
174
|
multi_json (~> 1.0)
|
|
144
175
|
rack (~> 1.0)
|
|
145
176
|
tilt (~> 1.1, != 1.3.0)
|
|
146
|
-
squeel (1.0
|
|
147
|
-
activerecord (
|
|
148
|
-
activesupport (
|
|
149
|
-
polyamorous (~> 0.
|
|
150
|
-
thor (0.
|
|
151
|
-
tilt (1.
|
|
152
|
-
treetop (1.4.
|
|
177
|
+
squeel (1.1.0)
|
|
178
|
+
activerecord (>= 3.0)
|
|
179
|
+
activesupport (>= 3.0)
|
|
180
|
+
polyamorous (~> 0.6.0)
|
|
181
|
+
thor (0.18.1)
|
|
182
|
+
tilt (1.4.1)
|
|
183
|
+
treetop (1.4.15)
|
|
153
184
|
polyglot
|
|
154
185
|
polyglot (>= 0.3.1)
|
|
155
186
|
tzinfo (0.3.37)
|
|
156
|
-
warden (1.2.
|
|
187
|
+
warden (1.2.3)
|
|
157
188
|
rack (>= 1.0)
|
|
158
189
|
|
|
159
190
|
PLATFORMS
|
|
160
191
|
ruby
|
|
161
192
|
|
|
162
193
|
DEPENDENCIES
|
|
163
|
-
bootstrap-sass (~> 2.3.1
|
|
194
|
+
bootstrap-sass (~> 2.3.2.1)
|
|
164
195
|
bundler (~> 1.3.4)
|
|
165
196
|
devise
|
|
166
197
|
display_for (= 0.1.12)
|
|
167
198
|
haml-rails
|
|
168
199
|
inherited_resources
|
|
169
|
-
jeweler (~> 1.8.
|
|
200
|
+
jeweler (~> 1.8.7)
|
|
170
201
|
kaminari
|
|
171
202
|
log_buddy
|
|
172
203
|
nested_form!
|
|
173
204
|
nested_set
|
|
174
|
-
rails (~> 3.2.
|
|
205
|
+
rails (~> 3.2.14)
|
|
175
206
|
rspec-rails
|
|
176
207
|
sass-rails
|
|
177
208
|
select2-rails
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.5.
|
|
1
|
+
0.5.6
|
|
@@ -31,12 +31,6 @@ module AppFrame::ResourcesHelper
|
|
|
31
31
|
def parent_resource_name
|
|
32
32
|
parent_resource_class.model_name.human
|
|
33
33
|
end
|
|
34
|
-
|
|
35
|
-
def controller_namespaces
|
|
36
|
-
result = controller.class.to_s.split('::')
|
|
37
|
-
result.pop
|
|
38
|
-
result.map(&:underscore)
|
|
39
|
-
end
|
|
40
34
|
|
|
41
35
|
def namespaced(string)
|
|
42
36
|
if controller_namespaces.any?
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
= yield :page_header
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
=
|
|
1
|
+
- content_for :page_header do
|
|
2
|
+
= page_header resource.to_s do
|
|
3
|
+
= content_locale_switch(resource)
|
|
4
|
+
|
|
3
5
|
= simple_nested_form_for resource_path_array, :html => {:class => 'form-inline' } do |f|
|
|
4
6
|
= hidden_field_tag :content_locale, params[:content_locale] if params[:content_locale]
|
|
5
7
|
= render 'form', :f => f
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
- content_for :page_header do
|
|
2
|
+
= page_header "New #{resource_name}"
|
|
3
|
+
|
|
2
4
|
= simple_nested_form_for resource_path_array, :html => {:class => 'form-inline' } do |f|
|
|
3
5
|
= hidden_field_tag :content_locale, params[:content_locale] if params[:content_locale]
|
|
4
6
|
= render 'form', :f => f
|
|
@@ -21,12 +21,16 @@
|
|
|
21
21
|
#main.container-fluid
|
|
22
22
|
- if sidebar.present?
|
|
23
23
|
.content
|
|
24
|
+
.page-header
|
|
25
|
+
= render 'page_header'
|
|
24
26
|
= render 'sub_menu'
|
|
25
27
|
= render 'flashes'
|
|
26
28
|
= yield
|
|
27
29
|
.sidebar
|
|
28
30
|
= sidebar
|
|
29
31
|
- else
|
|
32
|
+
.page-header
|
|
33
|
+
= render 'page_header'
|
|
30
34
|
= render 'sub_menu'
|
|
31
35
|
= render 'flashes'
|
|
32
36
|
= yield
|
data/app_frame.gemspec
CHANGED
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
|
|
6
6
|
Gem::Specification.new do |s|
|
|
7
7
|
s.name = "app_frame"
|
|
8
|
-
s.version = "0.5.
|
|
8
|
+
s.version = "0.5.6"
|
|
9
9
|
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
|
11
11
|
s.authors = ["Mateo Murphy"]
|
|
12
|
-
s.date = "2013-08-
|
|
12
|
+
s.date = "2013-08-25"
|
|
13
13
|
s.description = "An app framework"
|
|
14
14
|
s.email = "mateo.murphy@gmail.com"
|
|
15
15
|
s.extra_rdoc_files = [
|
|
@@ -56,6 +56,7 @@ Gem::Specification.new do |s|
|
|
|
56
56
|
"app/views/application/_flashes.html.haml",
|
|
57
57
|
"app/views/application/_form.html.haml",
|
|
58
58
|
"app/views/application/_head.html.haml",
|
|
59
|
+
"app/views/application/_page_header.html.haml",
|
|
59
60
|
"app/views/application/_secondary_menu.html.haml",
|
|
60
61
|
"app/views/application/_show.html.haml",
|
|
61
62
|
"app/views/application/_sidebar.html.haml",
|
|
@@ -97,7 +98,7 @@ Gem::Specification.new do |s|
|
|
|
97
98
|
s.specification_version = 3
|
|
98
99
|
|
|
99
100
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
|
100
|
-
s.add_runtime_dependency(%q<bootstrap-sass>, ["~> 2.3.1
|
|
101
|
+
s.add_runtime_dependency(%q<bootstrap-sass>, ["~> 2.3.2.1"])
|
|
101
102
|
s.add_runtime_dependency(%q<devise>, [">= 0"])
|
|
102
103
|
s.add_runtime_dependency(%q<display_for>, ["= 0.1.12"])
|
|
103
104
|
s.add_runtime_dependency(%q<haml-rails>, [">= 0"])
|
|
@@ -110,14 +111,14 @@ Gem::Specification.new do |s|
|
|
|
110
111
|
s.add_runtime_dependency(%q<simple_form>, [">= 0"])
|
|
111
112
|
s.add_runtime_dependency(%q<select2-rails>, [">= 0"])
|
|
112
113
|
s.add_runtime_dependency(%q<squeel>, [">= 0"])
|
|
113
|
-
s.add_development_dependency(%q<rails>, ["~> 3.2.
|
|
114
|
+
s.add_development_dependency(%q<rails>, ["~> 3.2.14"])
|
|
114
115
|
s.add_development_dependency(%q<rspec-rails>, [">= 0"])
|
|
115
116
|
s.add_development_dependency(%q<bundler>, ["~> 1.3.4"])
|
|
116
|
-
s.add_development_dependency(%q<jeweler>, ["~> 1.8.
|
|
117
|
+
s.add_development_dependency(%q<jeweler>, ["~> 1.8.7"])
|
|
117
118
|
s.add_development_dependency(%q<simplecov>, [">= 0"])
|
|
118
119
|
s.add_development_dependency(%q<log_buddy>, [">= 0"])
|
|
119
120
|
else
|
|
120
|
-
s.add_dependency(%q<bootstrap-sass>, ["~> 2.3.1
|
|
121
|
+
s.add_dependency(%q<bootstrap-sass>, ["~> 2.3.2.1"])
|
|
121
122
|
s.add_dependency(%q<devise>, [">= 0"])
|
|
122
123
|
s.add_dependency(%q<display_for>, ["= 0.1.12"])
|
|
123
124
|
s.add_dependency(%q<haml-rails>, [">= 0"])
|
|
@@ -130,15 +131,15 @@ Gem::Specification.new do |s|
|
|
|
130
131
|
s.add_dependency(%q<simple_form>, [">= 0"])
|
|
131
132
|
s.add_dependency(%q<select2-rails>, [">= 0"])
|
|
132
133
|
s.add_dependency(%q<squeel>, [">= 0"])
|
|
133
|
-
s.add_dependency(%q<rails>, ["~> 3.2.
|
|
134
|
+
s.add_dependency(%q<rails>, ["~> 3.2.14"])
|
|
134
135
|
s.add_dependency(%q<rspec-rails>, [">= 0"])
|
|
135
136
|
s.add_dependency(%q<bundler>, ["~> 1.3.4"])
|
|
136
|
-
s.add_dependency(%q<jeweler>, ["~> 1.8.
|
|
137
|
+
s.add_dependency(%q<jeweler>, ["~> 1.8.7"])
|
|
137
138
|
s.add_dependency(%q<simplecov>, [">= 0"])
|
|
138
139
|
s.add_dependency(%q<log_buddy>, [">= 0"])
|
|
139
140
|
end
|
|
140
141
|
else
|
|
141
|
-
s.add_dependency(%q<bootstrap-sass>, ["~> 2.3.1
|
|
142
|
+
s.add_dependency(%q<bootstrap-sass>, ["~> 2.3.2.1"])
|
|
142
143
|
s.add_dependency(%q<devise>, [">= 0"])
|
|
143
144
|
s.add_dependency(%q<display_for>, ["= 0.1.12"])
|
|
144
145
|
s.add_dependency(%q<haml-rails>, [">= 0"])
|
|
@@ -151,10 +152,10 @@ Gem::Specification.new do |s|
|
|
|
151
152
|
s.add_dependency(%q<simple_form>, [">= 0"])
|
|
152
153
|
s.add_dependency(%q<select2-rails>, [">= 0"])
|
|
153
154
|
s.add_dependency(%q<squeel>, [">= 0"])
|
|
154
|
-
s.add_dependency(%q<rails>, ["~> 3.2.
|
|
155
|
+
s.add_dependency(%q<rails>, ["~> 3.2.14"])
|
|
155
156
|
s.add_dependency(%q<rspec-rails>, [">= 0"])
|
|
156
157
|
s.add_dependency(%q<bundler>, ["~> 1.3.4"])
|
|
157
|
-
s.add_dependency(%q<jeweler>, ["~> 1.8.
|
|
158
|
+
s.add_dependency(%q<jeweler>, ["~> 1.8.7"])
|
|
158
159
|
s.add_dependency(%q<simplecov>, [">= 0"])
|
|
159
160
|
s.add_dependency(%q<log_buddy>, [">= 0"])
|
|
160
161
|
end
|
|
@@ -3,16 +3,12 @@ module AppFrame
|
|
|
3
3
|
module ControllerMethods
|
|
4
4
|
extend ActiveSupport::Concern
|
|
5
5
|
|
|
6
|
-
def controller
|
|
7
|
-
self
|
|
8
|
-
end
|
|
9
|
-
|
|
10
6
|
module ClassMethods
|
|
11
7
|
def app_frame(options = {})
|
|
12
8
|
layout "#{AppFrame::theme}/#{options[:layout] || 'default'}"
|
|
13
9
|
unless options[:resource] == false
|
|
14
10
|
inherit_resources
|
|
15
|
-
include
|
|
11
|
+
include ResourceSupport
|
|
16
12
|
include PaginationSupport
|
|
17
13
|
include HasManySupport
|
|
18
14
|
include SearchSupport
|
|
@@ -20,6 +16,20 @@ module AppFrame
|
|
|
20
16
|
end
|
|
21
17
|
end
|
|
22
18
|
|
|
19
|
+
module ResourceSupport
|
|
20
|
+
extend ActiveSupport::Concern
|
|
21
|
+
|
|
22
|
+
included do
|
|
23
|
+
helper_method :controller_namespaces
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def controller_namespaces
|
|
27
|
+
result = self.class.to_s.split('::')
|
|
28
|
+
result.pop
|
|
29
|
+
result.map(&:underscore)
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
|
|
23
33
|
module SearchSupport
|
|
24
34
|
extend ActiveSupport::Concern
|
|
25
35
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: app_frame
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.5.
|
|
4
|
+
version: 0.5.6
|
|
5
5
|
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2013-08-
|
|
12
|
+
date: 2013-08-25 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: bootstrap-sass
|
|
@@ -18,7 +18,7 @@ dependencies:
|
|
|
18
18
|
requirements:
|
|
19
19
|
- - ~>
|
|
20
20
|
- !ruby/object:Gem::Version
|
|
21
|
-
version: 2.3.1
|
|
21
|
+
version: 2.3.2.1
|
|
22
22
|
type: :runtime
|
|
23
23
|
prerelease: false
|
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
|
@@ -26,7 +26,7 @@ dependencies:
|
|
|
26
26
|
requirements:
|
|
27
27
|
- - ~>
|
|
28
28
|
- !ruby/object:Gem::Version
|
|
29
|
-
version: 2.3.1
|
|
29
|
+
version: 2.3.2.1
|
|
30
30
|
- !ruby/object:Gem::Dependency
|
|
31
31
|
name: devise
|
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -226,7 +226,7 @@ dependencies:
|
|
|
226
226
|
requirements:
|
|
227
227
|
- - ~>
|
|
228
228
|
- !ruby/object:Gem::Version
|
|
229
|
-
version: 3.2.
|
|
229
|
+
version: 3.2.14
|
|
230
230
|
type: :development
|
|
231
231
|
prerelease: false
|
|
232
232
|
version_requirements: !ruby/object:Gem::Requirement
|
|
@@ -234,7 +234,7 @@ dependencies:
|
|
|
234
234
|
requirements:
|
|
235
235
|
- - ~>
|
|
236
236
|
- !ruby/object:Gem::Version
|
|
237
|
-
version: 3.2.
|
|
237
|
+
version: 3.2.14
|
|
238
238
|
- !ruby/object:Gem::Dependency
|
|
239
239
|
name: rspec-rails
|
|
240
240
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -274,7 +274,7 @@ dependencies:
|
|
|
274
274
|
requirements:
|
|
275
275
|
- - ~>
|
|
276
276
|
- !ruby/object:Gem::Version
|
|
277
|
-
version: 1.8.
|
|
277
|
+
version: 1.8.7
|
|
278
278
|
type: :development
|
|
279
279
|
prerelease: false
|
|
280
280
|
version_requirements: !ruby/object:Gem::Requirement
|
|
@@ -282,7 +282,7 @@ dependencies:
|
|
|
282
282
|
requirements:
|
|
283
283
|
- - ~>
|
|
284
284
|
- !ruby/object:Gem::Version
|
|
285
|
-
version: 1.8.
|
|
285
|
+
version: 1.8.7
|
|
286
286
|
- !ruby/object:Gem::Dependency
|
|
287
287
|
name: simplecov
|
|
288
288
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -362,6 +362,7 @@ files:
|
|
|
362
362
|
- app/views/application/_flashes.html.haml
|
|
363
363
|
- app/views/application/_form.html.haml
|
|
364
364
|
- app/views/application/_head.html.haml
|
|
365
|
+
- app/views/application/_page_header.html.haml
|
|
365
366
|
- app/views/application/_secondary_menu.html.haml
|
|
366
367
|
- app/views/application/_show.html.haml
|
|
367
368
|
- app/views/application/_sidebar.html.haml
|
|
@@ -407,7 +408,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
407
408
|
version: '0'
|
|
408
409
|
segments:
|
|
409
410
|
- 0
|
|
410
|
-
hash:
|
|
411
|
+
hash: -1054025559741133892
|
|
411
412
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
412
413
|
none: false
|
|
413
414
|
requirements:
|