tkh_illustrations 0.0.4 → 0.0.5
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/CHANGELOG.md +7 -0
- data/README.md +2 -2
- data/app/controllers/illustrations_controller.rb +5 -4
- data/lib/tkh_illustrations/version.rb +1 -1
- metadata +4 -4
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,13 @@
|
|
1
1
|
# TKH Illustrations
|
2
2
|
|
3
3
|
|
4
|
+
|
5
|
+
## 0.0.5
|
6
|
+
|
7
|
+
* Added authenticate_with_admin before_filter in illustrations controller
|
8
|
+
* Added a switch_to_admin_layout call in all relevant illustration controller methods
|
9
|
+
|
10
|
+
|
4
11
|
## 0.0.4
|
5
12
|
|
6
13
|
* Only logged in users can access this section
|
data/README.md
CHANGED
@@ -34,9 +34,9 @@ And then of course restart your server! Typically:
|
|
34
34
|
|
35
35
|
The following things are needed:
|
36
36
|
|
37
|
-
* an
|
37
|
+
* an application controller switch_to_admin_layout method - optional use of the tkh_admin_panel gem
|
38
38
|
* the imagemagick library must be installed on your dev machine and production server
|
39
|
-
* current_user and
|
39
|
+
* current_user, authenticate, and authenticate_with_admin methods should be provided by your authentication system. You can use the tkh_authentication gem to that effect
|
40
40
|
|
41
41
|
That's all
|
42
42
|
|
@@ -1,25 +1,26 @@
|
|
1
1
|
class IllustrationsController < ApplicationController
|
2
2
|
|
3
3
|
before_filter :authenticate
|
4
|
+
before_filter :authenticate_with_admin
|
4
5
|
|
5
6
|
def index
|
6
7
|
@illustrations = Illustration.by_recent
|
7
|
-
|
8
|
+
switch_to_admin_layout
|
8
9
|
end
|
9
10
|
|
10
11
|
def show
|
11
12
|
@illustration = Illustration.find(params[:id])
|
12
|
-
|
13
|
+
switch_to_admin_layout
|
13
14
|
end
|
14
15
|
|
15
16
|
def new
|
16
17
|
@illustration = Illustration.new
|
17
|
-
|
18
|
+
switch_to_admin_layout
|
18
19
|
end
|
19
20
|
|
20
21
|
def edit
|
21
22
|
@illustration = Illustration.find(params[:id])
|
22
|
-
|
23
|
+
switch_to_admin_layout
|
23
24
|
end
|
24
25
|
|
25
26
|
def create
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tkh_illustrations
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
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: 2012-07-
|
12
|
+
date: 2012-07-31 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -176,7 +176,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
176
176
|
version: '0'
|
177
177
|
segments:
|
178
178
|
- 0
|
179
|
-
hash:
|
179
|
+
hash: -3745194236740910045
|
180
180
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
181
181
|
none: false
|
182
182
|
requirements:
|
@@ -185,7 +185,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
185
|
version: '0'
|
186
186
|
segments:
|
187
187
|
- 0
|
188
|
-
hash:
|
188
|
+
hash: -3745194236740910045
|
189
189
|
requirements: []
|
190
190
|
rubyforge_project:
|
191
191
|
rubygems_version: 1.8.23
|