browsercms 3.5.5 → 3.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.
@@ -56,6 +56,10 @@ module Cms
56
56
  end
57
57
  end
58
58
 
59
+ def determine_page_layout
60
+ @page.layout
61
+ end
62
+
59
63
  module ClassMethods
60
64
 
61
65
  # Requires that some or all of the actions on this controller require the same permissions as a specific section of the website.
@@ -28,6 +28,12 @@ module Cms
28
28
  handle_error_with_cms_page(Cms::ErrorPages::SERVER_ERROR_PATH, exception, :internal_server_error)
29
29
  end
30
30
 
31
+ # Basic implementation for looking up the template based on the page layout.
32
+ # This will be overwritten by Cms::MobileAware to show mobile aware templates.
33
+ def determine_page_layout
34
+ @page.layout
35
+ end
36
+
31
37
  private
32
38
 
33
39
  # This is the method all error handlers delegate to
@@ -62,7 +68,7 @@ module Cms
62
68
 
63
69
  # The error pages are ALWAYS html since they are managed by the CMS as normal pages.
64
70
  # So .gif or .jpg requests that throw errors will return html rather than a format warning.
65
- render :layout => @page.layout, :template => 'cms/content/show', :status => status, :formats=>[:html]
71
+ render :layout => determine_page_layout, :template => 'cms/content/show', :status => status, :formats=>[:html]
66
72
  else
67
73
  handle_server_error(exception)
68
74
  end
@@ -2,7 +2,7 @@
2
2
  # Allows the precise version of BrowserCMS to be determined programatically.
3
3
  #
4
4
  module Cms
5
- VERSION = "3.5.5"
5
+ VERSION = "3.5.6"
6
6
 
7
7
  # Return the current version of the CMS.
8
8
  def self.version
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: browsercms
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.5.5
4
+ version: 3.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-02-12 00:00:00.000000000 Z
12
+ date: 2013-04-15 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -776,7 +776,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
776
776
  version: '0'
777
777
  segments:
778
778
  - 0
779
- hash: -1146009963062196291
779
+ hash: 1280094750277936312
780
780
  requirements: []
781
781
  rubyforge_project:
782
782
  rubygems_version: 1.8.24