【问题标题】:Netzke controller generation errorNetzke 控制器生成错误
【发布时间】:2013-03-13 04:41:07
【问题描述】:

我是 Ruby 和 Rails 的新手,在生成简单控制器时询问错误 http://writelesscode.com/blog/2012/10/20/extjs-rails-crud-application-in-7-minutes/

$ rails g controller welcome index

/Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke/core/railz.rb:2:in require': /Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke/core/railz/routes.rb:18: syntax error, unexpected ':', expecting kEND (SyntaxError) ...refix}/:action(.:format)", to: controller.to_s, as: 'netzke' ^ /Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke/core/railz/routes.rb:18: syntax error, unexpected ':', expecting '=' ...at)", to: controller.to_s, as: 'netzke' ^ from /Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke/core/railz.rb:2 from /Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke-core.rb:10:inrequire' 来自 /Library/Ruby/Gems/1.8/gems/netzke-core-0.8.2/lib/netzke-core.rb:10 来自 /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:in require' from /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:inrequire' 来自 /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:in each' from /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:inrequire' 来自 /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:in each' from /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:inrequire' 来自 /Library/Ruby/Gems/1.8/gems/bundler-1.2.3/lib/bundler.rb:128:in require' from /Users/sparta/Work/rails/erp/config/application.rb:7 from /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:24:inrequire' 来自 /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:24 来自脚本/rails:6:in `require' 来自脚本/rails:6

路线可能有问题?我错过了什么?

【问题讨论】:

    标签: ruby-on-rails extjs4 netzke


    【解决方案1】:

    看来您使用的是 Ruby 1.8.7。 Netzke 需要 1.9.x。

    【讨论】:

      猜你喜欢
      • 2012-06-29
      • 1970-01-01
      • 1970-01-01
      • 2013-06-17
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多