我正在使用命名空间路由来创建管理部分。
问题是,当我将非命名空间和工作控制器移动到/ admin命名空间时,我突然得到未定义的方法错误。
Showing
/media/_portable_/appname/vendor/plugins/active_scaffold/frontends/default/views/_form_messages.html.erb where line #4 raised:
undefined method `errors' for :record:Symbol
Extracted source (around line #4):
1: <%= render :partial => 'messages' %>
2:
3: <% unless @record.nil? %>
4: <%= error_messages_for :record, :object_name => @record.class.model_name.human.downcase %>
5: <% end %>
routes.rb
namespace :admin do
root :controller => 'dashboard', :action => "index"
resources :dashboard, :users, :apps do
as_routes
end
resources :admin_sessions, :only => [:new, :create, :destroy]
end
有关我如何解决此问题的任何帮助?