ecm_cms_core 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,7 +3,8 @@ module Ecm
3
3
  class PageController < ::FrontendController
4
4
  include Ecm::CmsCoreHelper
5
5
 
6
- append_view_path Template::Resolver.instance
6
+ # append_view_path Template::Resolver.instance
7
+ append_view_path Ecm::CmsCore::Template::Resolver.instance unless view_paths.include?(Ecm::CmsCore::Template::Resolver.instance)
7
8
 
8
9
  def render_404
9
10
  respond_to do |format|
@@ -27,7 +28,7 @@ module Ecm
27
28
  render :template => page, :layout => template.layout
28
29
  else
29
30
  render :template => page
30
- end
31
+ end
31
32
  rescue ActionView::MissingTemplate
32
33
  render_404
33
34
  end
@@ -41,12 +42,14 @@ module Ecm
41
42
 
42
43
  subpath = page.split("/").reverse.drop(1).reverse.join("/").sub(/(\/)+$/,'')
43
44
  if subpath.length > 0
45
+ pathname << '/' unless subpath.start_with?('/')
44
46
  pathname << "#{subpath}"
45
47
  end
46
48
  pathname << '/' unless pathname.end_with?('/')
47
49
  basename = page.split("/").last
48
- logger.debug("pathname: #{pathname}")
49
- logger.debug("basename: #{basename}")
50
+ logger.debug("pathname in page#respond: #{pathname}")
51
+ logger.debug("basename in page#respond: #{basename}")
52
+ logger.debug("page in page#respond: #{page}")
50
53
  return page, pathname, basename
51
54
  end
52
55
  end
@@ -3,13 +3,13 @@ module Ecm
3
3
  class Engine < Rails::Engine
4
4
  paths["config/locales"] << File.dirname(__FILE__) + '/../../../config/locales'
5
5
 
6
- # Enabling assets precompiling under rails 3.1 or greater
7
- if Rails.version >= '3.1'
8
- initializer "ecm_pictures.asset_pipeline" do |app|
9
- app.config.assets.precompile << 'ecm_cms_core.js'
10
- app.config.assets.precompile << 'ecm_cms_core.css'
11
- end
12
- end
6
+ # # Enabling assets precompiling under rails 3.1 or greater
7
+ # if Rails.version >= '3.1'
8
+ # initializer "ecm_pictures.asset_pipeline" do |app|
9
+ # app.config.assets.precompile << 'ecm_cms_core.js'
10
+ # app.config.assets.precompile << 'ecm_cms_core.css'
11
+ # end
12
+ # end
13
13
 
14
14
  config.to_prepare do
15
15
  ApplicationController.helper(Ecm::CmsCoreHelper)
@@ -1,5 +1,5 @@
1
1
  module Ecm
2
2
  module CmsCore
3
- VERSION = "0.0.2"
3
+ VERSION = "0.0.3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: ecm_cms_core
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.2
5
+ version: 0.0.3
6
6
  platform: ruby
7
7
  authors:
8
8
  - Roberto Vasquez Angel
@@ -162,7 +162,6 @@ files:
162
162
  - Rakefile
163
163
  - README.rdoc
164
164
  - test/test_helper.rb
165
- - test/dummy/tmp/pids/server.pid
166
165
  - test/dummy/tmp/cache/sass/a6e19f0ba7c994b5cd1f8fcd2ef7cb5a62017be7/_bourbon.scssc
167
166
  - test/dummy/tmp/cache/sass/521b993c9acd187272527f2007471941399e49e7/_clearfix.scssc
168
167
  - test/dummy/tmp/cache/sass/521b993c9acd187272527f2007471941399e49e7/_html5-input-types.scssc
@@ -429,7 +428,6 @@ specification_version: 3
429
428
  summary: Database backed templates and partials.
430
429
  test_files:
431
430
  - test/test_helper.rb
432
- - test/dummy/tmp/pids/server.pid
433
431
  - test/dummy/tmp/cache/sass/a6e19f0ba7c994b5cd1f8fcd2ef7cb5a62017be7/_bourbon.scssc
434
432
  - test/dummy/tmp/cache/sass/521b993c9acd187272527f2007471941399e49e7/_clearfix.scssc
435
433
  - test/dummy/tmp/cache/sass/521b993c9acd187272527f2007471941399e49e7/_html5-input-types.scssc
@@ -1 +0,0 @@
1
- 12250