2012-04-11 44 views
1

我試圖讓機車CMS設置和本地運行,但我遇到了這個錯誤:機車CMS未定義的方法`計數」的零:NilClass

NoMethodError in Locomotive/pages#index 

Showing /Users/dennismonsewicz/.rvm/gems/ruby-1.9.3-p125/gems/locomotive_cms-2.0.0.rc4/app/views/locomotive/pages/_page.html.haml where line #4 raised: 

undefined method `count' for nil:NilClass 
Extracted source (around line #4): 

1: - if page.not_found? 
2: %li.sep   
3: 
4: %li{ :id => "item-#{page.id}", :class => "page #{css_for_page(page)}" } 
5: 
6: - children = can?(:manage, page) ? page.children : page.children.find_all { |p| !p.templatized? } 
7: 

其他人遇到這個問題與機車?

機車寶石:gem 'locomotive_cms', '~> 2.0.0.rc.4', :require => 'locomotive/engine'

我能得到管理員的用戶設置,但是當你與初始設置完成後,應用程序將您重定向到/機車/頁,然後我得到這個錯誤

回答

2

在機車的文檔,他們的狀態,做以下在寶石文件: gem 'locomotive_cms', '~> 2.0.0.rc4', :require => 'locomotive/engine'

但實際上必須做到以下幾點: gem 'locomotive_cms', :require => 'locomotive/engine', :git => "git://github.com/locomotivecms/engine.git"

相關問題