Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ActionView::Template::Error (undefined method `model_name' for Symbol:Class): #1

Closed
markmcdonald51 opened this issue Dec 27, 2010 · 17 comments

Comments

@markmcdonald51
Copy link

Hi,

I am not really sure how to get a stack trace from active_scaffold but here is the logs from an error I am getting while using this plugin.

My controller looks like this:

active_scaffold :category do |conf|
conf.actions << :sortable
conf.sortable.column = :position
conf.columns = [:name, :description, :image, :items]
end

my model looks like such:

class Category < ActiveRecord::Base

attr_accessible :name, :image, :description, :ayce, :take_out

has_many :items, :dependent => :destroy

belongs_to :company
acts_as_list :scope => :company
default_scope :order => 'position'

end

If I turn off the conf.actions << :sortable and the conf.sortable.column = :position everything works again.

Thanks for the putting this together. Let me know if there is anything I can do to provide you with more detail, eg stack traces.

Happy New Year!

Mark McDonald

Here is the logs.
Started GET "/categories?assoc_id=1&association=categories&eid=companies_1_categories&parent_model=company&adapter=_list_inline_adapter" for 127.0.0.1 at 2010-12-27 06:50:37 -0800
Processing by CategoriesController#index as /
Parameters: {"assoc_id"=>"1", "association"=>"categories", "eid"=>"companies_1_categories", "parent_model"=>"company", "adapter"=>"_list_inline_adapter"}
Geokit is using the domain: localhost
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

User Load (4.8ms) SELECT "users".* FROM "users" WHERE ("users"."id" = 1) LIMIT 1
Role Load (0.3ms) SELECT "roles".* FROM "roles" INNER JOIN "roles_users" ON "roles".id = "roles_users".role_id WHERE ("roles_users".user_id = 1 ) AND ("roles"."name" = 'Admin') LIMIT 1
Company Load (0.5ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 1) LIMIT 1
CACHE (0.0ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 1) LIMIT 1
SQL (0.4ms) SELECT COUNT() FROM "categories" WHERE ("categories".company_id = 1)
Category Load (4.2ms) SELECT "categories".
FROM "categories" WHERE ("categories".company_id = 1) ORDER BY position, "categories"."position" ASC
Item Load (8.8ms) SELECT "items".* FROM "items" WHERE ("items".category_id IN (1,2,3,4,5))
Rendered vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb (2.4ms)
Rendered vendor/plugins/active_scaffold/frontends/default/views/list.html.erb (20.8ms)
Completed in 403ms

ActionView::Template::Error (undefined method `model_name' for Symbol:Class):
1: <%= render :super %>
2: <% if ActiveScaffold.js_framework == :prototype %>
3: <%= sortable_element *sort_params %>
4: <% elsif ActiveScaffold.js_framework == :jquery %>

Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_trace.erb (2.2ms)
SQL (1.0ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

Category Load (5.3ms) SELECT "categories".* FROM "categories" ORDER BY position
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (1464.6ms)
Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/template_error.erb within rescues/layout (1486.7ms)

@vhochstein
Copy link
Owner

To get a complete stack trace in rails please go to backtrace initializer and remove comment in front of line:Rails.backtrace_cleaner.remove_silencers!

@markmcdonald51
Copy link
Author

with a stack trace:

Started GET "/categories?assoc_id=1&association=categories&eid=companies_1_categories&parent_model=company&adapter=list_inline_adapter" for 127.0.0.1 at 2010-12-27 07:27:05 -0800
Processing by CategoriesController#index as /
Parameters: {"assoc_id"=>"1", "association"=>"categories", "eid"=>"companies_1_categories", "parent_model"=>"company", "adapter"=>"list_inline_adapter"}
Geokit is using the domain: localhost
User Load (2.7ms) SELECT "users".* FROM "users" WHERE ("users"."id" = 1) LIMIT 1
Role Load (0.3ms) SELECT "roles".* FROM "roles" INNER JOIN "roles_users" ON "roles".id = "roles_users".role_id WHERE ("roles_users".user_id = 1 ) AND ("roles"."name" = 'Admin') LIMIT 1
Company Load (0.5ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 1) LIMIT 1
CACHE (0.0ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 1) LIMIT 1
SQL (0.3ms) SELECT COUNT(
) FROM "categories" WHERE ("categories".company_id = 1)
Category Load (4.4ms) SELECT "categories".
FROM "categories" WHERE ("categories".company_id = 1) ORDER BY position, "categories"."position" ASC
Item Load (13.3ms) SELECT "items".* FROM "items" WHERE ("items".category_id IN (1,2,3,4,5))
Rendered vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb (1.8ms)
Rendered vendor/plugins/active_scaffold/frontends/default/views/list.html.erb (21.6ms)
Completed in 317ms

ActionView::Template::Error (undefined method model_name' for Symbol:Class): 1: <%= render :super %> 2: <% if ActiveScaffold.js_framework == :prototype %> 3: <%= sortable_element *sort_params %> 4: <% elsif ActiveScaffold.js_framework == :jquery %> actionpack (3.0.3) lib/action_view/render/partials.rb:363:inpartial_path'
actionpack (3.0.3) lib/action_view/render/partials.rb:244:in setup' actionpack (3.0.3) lib/action_view/render/partials.rb:373:in_render_partial'
actionpack (3.0.3) lib/action_view/render/rendering.rb:31:in render' haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:inrender_with_haml'
vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb:1:in _vendor_plugins_active_scaffold_sortable_frontends_default_views__list_with_header_html_erb___978962157147979525_63982560__52923412718859159' actionpack (3.0.3) lib/action_view/template.rb:135:inblock in render'
activesupport (3.0.3) lib/active_support/notifications.rb:54:in instrument' actionpack (3.0.3) lib/action_view/template.rb:127:inrender'
actionpack (3.0.3) lib/action_view/render/partials.rb:333:in render_partial' actionpack (3.0.3) lib/action_view/render/partials.rb:262:inblock in render'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in block in instrument' activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:ininstrument'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in instrument' actionpack (3.0.3) lib/action_view/render/partials.rb:260:inrender'
actionpack (3.0.3) lib/action_view/render/partials.rb:378:in _render_partial' actionpack (3.0.3) lib/action_view/render/rendering.rb:22:inrender'
haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:in render_with_haml' vendor/plugins/active_scaffold/frontends/default/views/list.html.erb:1:in_vendor_plugins_active_scaffold_frontends_default_views_list_html_erb___1548107443840048068_64001640__929371149129535748'
actionpack (3.0.3) lib/action_view/template.rb:135:in block in render' activesupport (3.0.3) lib/active_support/notifications.rb:54:ininstrument'
actionpack (3.0.3) lib/action_view/template.rb:127:in render' actionpack (3.0.3) lib/action_view/render/rendering.rb:59:inblock in _render_template'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in block in instrument' activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:ininstrument'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in instrument' actionpack (3.0.3) lib/action_view/render/rendering.rb:56:in_render_template'
actionpack (3.0.3) lib/action_view/render/rendering.rb:26:in render' haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:inrender_with_haml'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:114:in _render_template' actionpack (3.0.3) lib/abstract_controller/rendering.rb:108:inrender_to_body'
actionpack (3.0.3) lib/action_controller/metal/renderers.rb:47:in render_to_body' actionpack (3.0.3) lib/action_controller/metal/compatibility.rb:55:inrender_to_body'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:101:in render_to_string' vendor/plugins/active_scaffold/lib/extensions/action_controller_rendering.rb:9:inrender_with_active_scaffold'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:30:in list_respond_to_html' vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:134:inblock (3 levels) in respond_to_action'
actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:in call' actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:inrespond_to'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:132:in respond_to_action' vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:22:inlist'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:9:in index' actionpack (3.0.3) lib/action_controller/metal/implicit_render.rb:4:insend_action'
actionpack (3.0.3) lib/abstract_controller/base.rb:151:in process_action' actionpack (3.0.3) lib/action_controller/metal/rendering.rb:11:inprocess_action'
actionpack (3.0.3) lib/abstract_controller/callbacks.rb:18:in block in process_action' activesupport (3.0.3) lib/active_support/callbacks.rb:495:in_run__4259836717462146089__process_action__2940351948543900543__callbacks'
activesupport (3.0.3) lib/active_support/callbacks.rb:409:in _run_process_action_callbacks' activesupport (3.0.3) lib/active_support/callbacks.rb:93:inrun_callbacks'
actionpack (3.0.3) lib/abstract_controller/callbacks.rb:17:in process_action' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:30:inblock in process_action'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in block in instrument' activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:ininstrument'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in instrument' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:29:inprocess_action'
actionpack (3.0.3) lib/action_controller/metal/rescue.rb:17:in process_action' actionpack (3.0.3) lib/abstract_controller/base.rb:120:inprocess'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:40:in process' actionpack (3.0.3) lib/action_controller/metal.rb:138:indispatch'
actionpack (3.0.3) lib/action_controller/metal/rack_delegation.rb:14:in dispatch' actionpack (3.0.3) lib/action_controller/metal.rb:178:inblock in action'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:in call' actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:indispatch'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:27:in call' rack-mount (0.6.13) lib/rack/mount/route_set.rb:148:inblock in call'
rack-mount (0.6.13) lib/rack/mount/code_generation.rb:93:in block in recognize' rack-mount (0.6.13) lib/rack/mount/code_generation.rb:96:inoptimized_each'
rack-mount (0.6.13) lib/rack/mount/code_generation.rb:92:in recognize' rack-mount (0.6.13) lib/rack/mount/route_set.rb:139:incall'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:492:in call' oa-core (0.1.6) lib/omniauth/strategy.rb:50:incall_app!'
oa-core (0.1.6) lib/omniauth/strategy.rb:32:in call!' oa-core (0.1.6) lib/omniauth/strategy.rb:19:incall'
oa-core (0.1.6) lib/omniauth/strategy.rb:50:in call_app!' oa-core (0.1.6) lib/omniauth/strategy.rb:32:incall!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in call' oa-core (0.1.6) lib/omniauth/strategy.rb:50:incall_app!'
oa-core (0.1.6) lib/omniauth/strategy.rb:32:in call!' oa-core (0.1.6) lib/omniauth/strategy.rb:19:incall'
oa-core (0.1.6) lib/omniauth/builder.rb:30:in call' haml (3.0.24) lib/sass/plugin/rack.rb:41:incall'
warden (0.10.7) lib/warden/manager.rb:35:in block in call' warden (0.10.7) lib/warden/manager.rb:34:incatch'
warden (0.10.7) lib/warden/manager.rb:34:in call' actionpack (3.0.3) lib/action_dispatch/middleware/best_standards_support.rb:17:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/head.rb:14:in call' rack (1.2.1) lib/rack/methodoverride.rb:24:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/params_parser.rb:21:in call' actionpack (3.0.3) lib/action_dispatch/middleware/flash.rb:182:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/session/abstract_store.rb:149:in call' actionpack (3.0.3) lib/action_dispatch/middleware/cookies.rb:295:incall'
activerecord (3.0.3) lib/active_record/query_cache.rb:32:in block in call' activerecord (3.0.3) lib/active_record/connection_adapters/abstract/query_cache.rb:28:incache'
activerecord (3.0.3) lib/active_record/query_cache.rb:12:in cache' activerecord (3.0.3) lib/active_record/query_cache.rb:31:incall'
activerecord (3.0.3) lib/active_record/connection_adapters/abstract/connection_pool.rb:353:in call' actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:46:inblock in call'
activesupport (3.0.3) lib/active_support/callbacks.rb:415:in _run_call_callbacks' actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:44:incall'
rack (1.2.1) lib/rack/sendfile.rb:107:in call' actionpack (3.0.3) lib/action_dispatch/middleware/remote_ip.rb:48:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/show_exceptions.rb:46:in call' railties (3.0.3) lib/rails/rack/logger.rb:13:incall'
rack (1.2.1) lib/rack/runtime.rb:17:in call' activesupport (3.0.3) lib/active_support/cache/strategy/local_cache.rb:72:incall'
dragonfly (0.8.1) lib/dragonfly/middleware.rb:16:in call' rack-cache (0.5.3) lib/rack/cache/context.rb:129:inforward'
rack-cache (0.5.3) lib/rack/cache/context.rb:235:in fetch' rack-cache (0.5.3) lib/rack/cache/context.rb:178:inlookup'
rack-cache (0.5.3) lib/rack/cache/context.rb:65:in call!' rack-cache (0.5.3) lib/rack/cache/context.rb:50:incall'
rack (1.2.1) lib/rack/lock.rb:11:in block in call' <internal:prelude>:10:insynchronize'
rack (1.2.1) lib/rack/lock.rb:11:in call' actionpack (3.0.3) lib/action_dispatch/middleware/static.rb:30:incall'
railties (3.0.3) lib/rails/application.rb:168:in call' railties (3.0.3) lib/rails/application.rb:77:inmethod_missing'
railties (3.0.3) lib/rails/rack/log_tailer.rb:14:in call' rack (1.2.1) lib/rack/content_length.rb:13:incall'
rack (1.2.1) lib/rack/chunked.rb:15:in call' rack (1.2.1) lib/rack/handler/mongrel.rb:67:inprocess'
mongrel (1.2.0.pre2) lib/mongrel.rb:165:in block in process_client' mongrel (1.2.0.pre2) lib/mongrel.rb:164:ineach'
mongrel (1.2.0.pre2) lib/mongrel.rb:164:in process_client' mongrel (1.2.0.pre2) lib/mongrel.rb:291:inblock (2 levels) in run'

Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_trace.erb (6.7ms)
SQL (1.1ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

Category Load (5.6ms) SELECT "categories".* FROM "categories" ORDER BY position
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (1.2ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (1.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (1744.5ms)
Rendered /home/mark/.rvm/gems/ruby-1.9.2-p0/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/template_error.erb within rescues/layout (1771.6ms)

@markmcdonald51
Copy link
Author

perhaps a little easier on the eyes: http://pastie.org/1408729

@vhochstein
Copy link
Owner

hm. unfortunelty, stack trace does nt seem to be complete, cause latest entry should be the line pointing to the error. :-(, but it isnt.

Next step would be to search your whole project for occurences of 'model_name'
and add debug statments to see where in code the crash is happening.

@markmcdonald51
Copy link
Author

I see. You have this working in your app right? I don't think I am doing anything too unique. I am trying to use it in nested set. I got this working a long time ago, like 4 years ago with the original active scaffold sortable and added some mods for it to work with nested sets. Not sure what to expect as I have not seen this one work. Below is a grep for 'model_name' . Not sure if that is any help or not.

mark@mark-solo:~/rails_apps/rails3/sushi_queue$ grep -r 'model_name' *

log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionController::RoutingError (undefined method model_name=' for #<ActiveScaffold::Config::Sortable:0x000000062aaa48>): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
log/development.log:ActionView::Template::Error (undefined method model_name' for Symbol:Class): log/development.log:ActionView::Template::Error (undefined methodmodel_name' for Symbol:Class):
vendor/plugins/active_scaffold/lib/active_scaffold/helpers/list_column_helpers.rb: format_value("#{value.class.model_name.human}: #{value.to_label}")
vendor/plugins/active_scaffold/lib/active_scaffold/helpers/form_column_helpers.rb: record_select_config.model.model_name.human
vendor/plugins/active_scaffold/lib/active_scaffold/helpers/form_column_helpers.rb: active_scaffold_config.model.model_name.human
vendor/plugins/active_scaffold/lib/active_scaffold/helpers/view_helpers.rb: if object.class.respond_to?(:model_name)
vendor/plugins/active_scaffold/lib/active_scaffold/helpers/view_helpers.rb: options[:object_name] ||= object.class.model_name.human.downcase
vendor/plugins/active_scaffold/lib/active_scaffold/config/core.rb: as_(@Label, options) || model.model_name.human(options.merge(options[:count].to_i == 1 ? {} : {:default => model.name.pluralize}))
vendor/plugins/active_scaffold/lib/active_scaffold/config/core.rb: self.columns[column].options[:options] = self.sti_children.collect do |model_name|
vendor/plugins/active_scaffold/lib/active_scaffold/config/core.rb: [model_name.to_s.camelize.constantize.human_name, model_name.to_s.camelize]
vendor/plugins/active_scaffold/lib/active_scaffold/config/nested.rb: options.reverse_merge! :security_method => :nested_authorized?, :label => column.association.klass.model_name.human({:count => 2, :default => column.association.klass.name.pluralize})
vendor/plugins/active_scaffold/lib/active_scaffold/actions/nested.rb: as_(:nested_of_model, :nested_model => active_scaffold_config.model.model_name.human, :parent_model => nested_parent_record.to_label)
vendor/plugins/active_scaffold/lib/active_scaffold/actions/nested.rb: active_scaffold_config.list.user.nested_default_sorting = {:table_name => active_scaffold_config.model.model_name, :default_sorting => nested.default_sorting}
vendor/plugins/active_scaffold/frontends/default/views/form_association_footer.html.erb: <% add_label = column.plural_association? ? as(:create_another, :model => column.association.klass.model_name.human) : as_(:replace_with_new)
vendor/plugins/active_scaffold/frontends/default/views/_vertical_subform.html.erb: <%= error_messages_for :record, :object_name => @record.class.model_name.human.downcase %>
vendor/plugins/active_scaffold/frontends/default/views/_horizontal_subform.html.erb: <%= error_messages_for :record, :object_name => @record.class.model_name.human.downcase %>
vendor/plugins/active_scaffold/frontends/default/views/_base_form.html.erb: <%= error_messages_for record, :object_name => "#{record.class.model_name.human.downcase}#{record.new_record? ? '' : ": #{record.to_label}"}" %>
vendor/plugins/active_scaffold/frontends/default/views/_create_form_on_list.html.erb: :headline => headline ||= active_scaffold_config.create.label(active_scaffold_config.sti_create_links ? @record.class.model_name.human(:count => 1) : nil)} %>
vendor/plugins/active_scaffold/frontends/default/views/_form_messages.html.erb: <%= error_messages_for :record, :object_name => @record.class.model_name.human.downcase %>
vendor/plugins/active_scaffold/frontends/default/views/_create_form.html.erb: :headline => headline ||= active_scaffold_config.send(form_action).label(active_scaffold_config.sti_create_links ? @record.class.model_name.human(:count => 1) : nil)} %>

@markmcdonald51
Copy link
Author

that grep w/ a pastie http://pastie.org/1408805

@vhochstein
Copy link
Owner

What happens if you open categories controller directly (not via companies nesting)?

@markmcdonald51
Copy link
Author

same thing: (pastie: http://pastie.org/1408885)

actionpack (3.0.3) lib/action_view/render/partials.rb:363:in partial_path' actionpack (3.0.3) lib/action_view/render/partials.rb:244:insetup'
actionpack (3.0.3) lib/action_view/render/partials.rb:373:in _render_partial' actionpack (3.0.3) lib/action_view/render/rendering.rb:31:inrender'
haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:in render_with_haml' vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb:1:in_vendor_plugins_active_scaffold_sortable_frontends_default_views__list_with_header_html_erb__3037050171234075230_47894500_3488313650759412212'
actionpack (3.0.3) lib/action_view/template.rb:135:in block in render' activesupport (3.0.3) lib/active_support/notifications.rb:54:ininstrument'
actionpack (3.0.3) lib/action_view/template.rb:127:in render' actionpack (3.0.3) lib/action_view/render/partials.rb:333:inrender_partial'
actionpack (3.0.3) lib/action_view/render/partials.rb:262:in block in render' activesupport (3.0.3) lib/active_support/notifications.rb:52:inblock in instrument'
activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:in instrument' activesupport (3.0.3) lib/active_support/notifications.rb:52:ininstrument'
actionpack (3.0.3) lib/action_view/render/partials.rb:260:in render' actionpack (3.0.3) lib/action_view/render/partials.rb:378:in_render_partial'
actionpack (3.0.3) lib/action_view/render/rendering.rb:22:in render' haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:inrender_with_haml'
vendor/plugins/active_scaffold/frontends/default/views/list.html.erb:1:in _vendor_plugins_active_scaffold_frontends_default_views_list_html_erb__1954707585546194443_47920300_1197673779266792286' actionpack (3.0.3) lib/action_view/template.rb:135:inblock in render'
activesupport (3.0.3) lib/active_support/notifications.rb:54:in instrument' actionpack (3.0.3) lib/action_view/template.rb:127:inrender'
actionpack (3.0.3) lib/action_view/render/rendering.rb:59:in block in _render_template' activesupport (3.0.3) lib/active_support/notifications.rb:52:inblock in instrument'
activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:in instrument' activesupport (3.0.3) lib/active_support/notifications.rb:52:ininstrument'
actionpack (3.0.3) lib/action_view/render/rendering.rb:56:in _render_template' actionpack (3.0.3) lib/action_view/render/rendering.rb:26:inrender'
haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:in render_with_haml' actionpack (3.0.3) lib/abstract_controller/rendering.rb:114:in_render_template'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:108:in render_to_body' actionpack (3.0.3) lib/action_controller/metal/renderers.rb:47:inrender_to_body'
actionpack (3.0.3) lib/action_controller/metal/compatibility.rb:55:in render_to_body' actionpack (3.0.3) lib/abstract_controller/rendering.rb:101:inrender_to_string'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:92:in render' actionpack (3.0.3) lib/action_controller/metal/rendering.rb:17:inrender'
actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:40:in block (2 levels) in render' activesupport (3.0.3) lib/active_support/core_ext/benchmark.rb:5:inblock in ms'
/home/mark/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/benchmark.rb:309:in realtime' activesupport (3.0.3) lib/active_support/core_ext/benchmark.rb:5:inms'
actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:40:in block in render' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:78:incleanup_view_runtime'
activerecord (3.0.3) lib/active_record/railties/controller_runtime.rb:15:in cleanup_view_runtime' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:39:inrender'
vendor/plugins/active_scaffold/lib/extensions/action_controller_rendering.rb:13:in render_with_active_scaffold' vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:30:inlist_respond_to_html'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:134:in block (3 levels) in respond_to_action' actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:incall'
actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:in respond_to' vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:132:inrespond_to_action'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:22:in list' vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:9:inindex'
actionpack (3.0.3) lib/action_controller/metal/implicit_render.rb:4:in send_action' actionpack (3.0.3) lib/abstract_controller/base.rb:151:inprocess_action'
actionpack (3.0.3) lib/action_controller/metal/rendering.rb:11:in process_action' actionpack (3.0.3) lib/abstract_controller/callbacks.rb:18:inblock in process_action'
activesupport (3.0.3) lib/active_support/callbacks.rb:495:in _run__2646740095429269079__process_action__4470836776023175804__callbacks' activesupport (3.0.3) lib/active_support/callbacks.rb:409:in_run_process_action_callbacks'
activesupport (3.0.3) lib/active_support/callbacks.rb:93:in run_callbacks' actionpack (3.0.3) lib/abstract_controller/callbacks.rb:17:inprocess_action'
actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:30:in block in process_action' activesupport (3.0.3) lib/active_support/notifications.rb:52:inblock in instrument'
activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:in instrument' activesupport (3.0.3) lib/active_support/notifications.rb:52:ininstrument'
actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:29:in process_action' actionpack (3.0.3) lib/action_controller/metal/rescue.rb:17:inprocess_action'
actionpack (3.0.3) lib/abstract_controller/base.rb:120:in process' actionpack (3.0.3) lib/abstract_controller/rendering.rb:40:inprocess'
actionpack (3.0.3) lib/action_controller/metal.rb:138:in dispatch' actionpack (3.0.3) lib/action_controller/metal/rack_delegation.rb:14:indispatch'
actionpack (3.0.3) lib/action_controller/metal.rb:178:in block in action' actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:incall'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:in dispatch' actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:27:incall'
rack-mount (0.6.13) lib/rack/mount/route_set.rb:148:in block in call' rack-mount (0.6.13) lib/rack/mount/code_generation.rb:93:inblock in recognize'
rack-mount (0.6.13) lib/rack/mount/code_generation.rb:96:in optimized_each' rack-mount (0.6.13) lib/rack/mount/code_generation.rb:92:inrecognize'
rack-mount (0.6.13) lib/rack/mount/route_set.rb:139:in call' actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:492:incall'
oa-core (0.1.6) lib/omniauth/strategy.rb:50:in call_app!' oa-core (0.1.6) lib/omniauth/strategy.rb:32:incall!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in call' oa-core (0.1.6) lib/omniauth/strategy.rb:50:incall_app!'
oa-core (0.1.6) lib/omniauth/strategy.rb:32:in call!' oa-core (0.1.6) lib/omniauth/strategy.rb:19:incall'
oa-core (0.1.6) lib/omniauth/strategy.rb:50:in call_app!' oa-core (0.1.6) lib/omniauth/strategy.rb:32:incall!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in call' oa-core (0.1.6) lib/omniauth/builder.rb:30:incall'
haml (3.0.24) lib/sass/plugin/rack.rb:41:in call' warden (0.10.7) lib/warden/manager.rb:35:inblock in call'
warden (0.10.7) lib/warden/manager.rb:34:in catch' warden (0.10.7) lib/warden/manager.rb:34:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/best_standards_support.rb:17:in call' actionpack (3.0.3) lib/action_dispatch/middleware/head.rb:14:incall'
rack (1.2.1) lib/rack/methodoverride.rb:24:in call' actionpack (3.0.3) lib/action_dispatch/middleware/params_parser.rb:21:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/flash.rb:182:in call' actionpack (3.0.3) lib/action_dispatch/middleware/session/abstract_store.rb:149:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/cookies.rb:295:in call' activerecord (3.0.3) lib/active_record/query_cache.rb:32:inblock in call'
activerecord (3.0.3) lib/active_record/connection_adapters/abstract/query_cache.rb:28:in cache' activerecord (3.0.3) lib/active_record/query_cache.rb:12:incache'
activerecord (3.0.3) lib/active_record/query_cache.rb:31:in call' activerecord (3.0.3) lib/active_record/connection_adapters/abstract/connection_pool.rb:353:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:46:in block in call' activesupport (3.0.3) lib/active_support/callbacks.rb:415:in_run_call_callbacks'
actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:44:in call' rack (1.2.1) lib/rack/sendfile.rb:107:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/remote_ip.rb:48:in call' actionpack (3.0.3) lib/action_dispatch/middleware/show_exceptions.rb:46:incall'
railties (3.0.3) lib/rails/rack/logger.rb:13:in call' rack (1.2.1) lib/rack/runtime.rb:17:incall'
activesupport (3.0.3) lib/active_support/cache/strategy/local_cache.rb:72:in call' dragonfly (0.8.1) lib/dragonfly/middleware.rb:16:incall'
rack-cache (0.5.3) lib/rack/cache/context.rb:129:in forward' rack-cache (0.5.3) lib/rack/cache/context.rb:235:infetch'
rack-cache (0.5.3) lib/rack/cache/context.rb:178:in lookup' rack-cache (0.5.3) lib/rack/cache/context.rb:65:incall!'
rack-cache (0.5.3) lib/rack/cache/context.rb:50:in call' rack (1.2.1) lib/rack/lock.rb:11:inblock in call'
internal:prelude:10:in synchronize' rack (1.2.1) lib/rack/lock.rb:11:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/static.rb:30:in call' railties (3.0.3) lib/rails/application.rb:168:incall'
railties (3.0.3) lib/rails/application.rb:77:in method_missing' railties (3.0.3) lib/rails/rack/log_tailer.rb:14:incall'
rack (1.2.1) lib/rack/content_length.rb:13:in call' rack (1.2.1) lib/rack/chunked.rb:15:incall'
rack (1.2.1) lib/rack/handler/mongrel.rb:67:in process' mongrel (1.2.0.pre2) lib/mongrel.rb:165:inblock in process_client'
mongrel (1.2.0.pre2) lib/mongrel.rb:164:in each' mongrel (1.2.0.pre2) lib/mongrel.rb:164:inprocess_client'
mongrel (1.2.0.pre2) lib/mongrel.rb:291:in `block (2 levels) in run'

@markmcdonald51
Copy link
Author

(here is the error from the page when I just load the categories). The stacktrace is above...

NoMethodError in Categories#index

Showing /home/mark/rails_apps/rails3/sushi_queue/vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb where line #1 raised:

undefined method `model_name' for Symbol:Class

Extracted source (around line #1):

1: <%= render :super %>
2: <% if ActiveScaffold.js_framework == :prototype %>
3: <%= sortable_element *sort_params %>
4: <% elsif ActiveScaffold.js_framework == :jquery %>

Trace of template inclusion: vendor/plugins/active_scaffold/frontends/default/views/list.html.erb

@markmcdonald51
Copy link
Author

Lemme know if you want to do a skype session or something. We could pair on this and solve it if you like. Not sure if you are having this problem at present or not.

@vhochstein
Copy link
Owner

Did you find line of code, where crash is actually happening?

@markmcdonald51
Copy link
Author

@vhochstein

Here is a full dump. I'd love to use this plugin but I get this error everytime I include it. I updated ruby to ruby-1.9.2-p136 [ x86_64 ] thinking that this could be a ruby problem however that proved fruitless. I am guessing you have this working. Not sure why I can't get it to work.

Thanks,

Mark

Started GET "/admin/categories?assoc_id=2&association=categories&eid=admin__companies_2_categories&parent_scaffold=admin%2Fcompanies&adapter=list_inline_adapter" for 127.0.0.1 at Tue Jan 18 10:08:29 -0800 2011
Processing by Admin::CategoriesController#index as JS
Parameters: {"parent_scaffold"=>"admin/companies", "eid"=>"admin__companies_2_categories", "association"=>"categories", "adapter"=>"list_inline_adapter", "assoc_id"=>"2"}
Geokit is using the domain: localhost
User Load (0.4ms) SELECT "users".* FROM "users" WHERE ("users"."id" = 1) LIMIT 1
Role Load (0.3ms) SELECT "roles".* FROM "roles" INNER JOIN "roles_users" ON "roles".id = "roles_users".role_id WHERE ("roles_users".user_id = 1 ) AND ("roles"."name" = 'Admin') LIMIT 1
Company Load (0.4ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 2) LIMIT 1
CACHE (0.0ms) SELECT "companies".* FROM "companies" WHERE ("companies"."id" = 2) LIMIT 1
SQL (0.3ms) SELECT COUNT(
) FROM "categories" WHERE ("categories".company_id = 2)
Category Load (0.6ms) SELECT "categories".
FROM "categories" WHERE ("categories".company_id = 2) ORDER BY position, "categories"."position" ASC
Item Load (5.2ms) SELECT "items".* FROM "items" WHERE ("items".category_id IN (6,7,8,9,10)) ORDER BY position
Rendered vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb (1.3ms)
Completed in 126ms

ActionView::Template::Error (undefined method model_name' for Symbol:Class): 1: <%= render :super %> 2: <% if ActiveScaffold.js_framework == :prototype %> 3: <%= sortable_element *sort_params %> 4: <% elsif ActiveScaffold.js_framework == :jquery %> actionpack (3.0.3) lib/action_view/render/partials.rb:363:inpartial_path'
actionpack (3.0.3) lib/action_view/render/partials.rb:244:in setup' actionpack (3.0.3) lib/action_view/render/partials.rb:373:in_render_partial'
actionpack (3.0.3) lib/action_view/render/rendering.rb:31:in render_without_haml' haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:inrender'
vendor/plugins/active_scaffold_sortable/frontends/default/views/_list_with_header.html.erb:1:in _vendor_plugins_active_scaffold_sortable_frontends_default_views__list_with_header_html_erb___898178602_70002320815440_3807230' actionpack (3.0.3) lib/action_view/template.rb:135:insend'
actionpack (3.0.3) lib/action_view/template.rb:135:in render' activesupport (3.0.3) lib/active_support/notifications.rb:54:ininstrument'
actionpack (3.0.3) lib/action_view/template.rb:127:in render' actionpack (3.0.3) lib/action_view/render/partials.rb:333:inrender_partial'
actionpack (3.0.3) lib/action_view/render/partials.rb:262:in render' activesupport (3.0.3) lib/active_support/notifications.rb:52:ininstrument'
activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:in instrument' activesupport (3.0.3) lib/active_support/notifications.rb:52:ininstrument'
actionpack (3.0.3) lib/action_view/render/partials.rb:260:in render' actionpack (3.0.3) lib/action_view/render/partials.rb:378:in_render_partial'
actionpack (3.0.3) lib/action_view/render/rendering.rb:22:in render_without_haml' haml (3.0.24) lib/haml/helpers/action_view_mods.rb:13:inrender'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:114:in _render_template' actionpack (3.0.3) lib/abstract_controller/rendering.rb:108:inrender_to_body'
actionpack (3.0.3) lib/action_controller/metal/renderers.rb:47:in render_to_body' actionpack (3.0.3) lib/action_controller/metal/compatibility.rb:55:inrender_to_body'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:101:in render_to_string' vendor/plugins/active_scaffold/lib/extensions/action_controller_rendering.rb:9:inrender'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:36:in list_respond_to_js' vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:134:insend'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:134:in respond_to_action' actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:incall'
actionpack (3.0.3) lib/action_controller/metal/mime_responds.rb:192:in respond_to' vendor/plugins/active_scaffold/lib/active_scaffold/actions/core.rb:132:inrespond_to_action'
vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:23:in list' vendor/plugins/active_scaffold/lib/active_scaffold/actions/list.rb:9:inindex'
actionpack (3.0.3) lib/action_controller/metal/implicit_render.rb:4:in send_action' actionpack (3.0.3) lib/action_controller/metal/implicit_render.rb:4:insend_action'
actionpack (3.0.3) lib/abstract_controller/base.rb:151:in process_action' actionpack (3.0.3) lib/action_controller/metal/rendering.rb:11:inprocess_action'
actionpack (3.0.3) lib/abstract_controller/callbacks.rb:18:in process_action' activesupport (3.0.3) lib/active_support/callbacks.rb:495:in_run__1205962652__process_action__199225275__callbacks'
activesupport (3.0.3) lib/active_support/callbacks.rb:409:in send' activesupport (3.0.3) lib/active_support/callbacks.rb:409:in_run_process_action_callbacks'
activesupport (3.0.3) lib/active_support/callbacks.rb:93:in send' activesupport (3.0.3) lib/active_support/callbacks.rb:93:inrun_callbacks'
actionpack (3.0.3) lib/abstract_controller/callbacks.rb:17:in process_action' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:30:inprocess_action'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in instrument' activesupport (3.0.3) lib/active_support/notifications/instrumenter.rb:21:ininstrument'
activesupport (3.0.3) lib/active_support/notifications.rb:52:in instrument' actionpack (3.0.3) lib/action_controller/metal/instrumentation.rb:29:inprocess_action'
actionpack (3.0.3) lib/action_controller/metal/rescue.rb:17:in process_action' actionpack (3.0.3) lib/abstract_controller/base.rb:120:inprocess'
actionpack (3.0.3) lib/abstract_controller/rendering.rb:40:in process' actionpack (3.0.3) lib/action_controller/metal.rb:138:indispatch'
actionpack (3.0.3) lib/action_controller/metal/rack_delegation.rb:14:in dispatch' actionpack (3.0.3) lib/action_controller/metal.rb:178:inaction'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:in call' actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:62:indispatch'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:27:in call' rack-mount (0.6.13) lib/rack/mount/route_set.rb:148:incall'
rack-mount (0.6.13) lib/rack/mount/code_generation.rb:93:in recognize' rack-mount (0.6.13) lib/rack/mount/code_generation.rb:131:inoptimized_each'
rack-mount (0.6.13) lib/rack/mount/code_generation.rb:92:in recognize' rack-mount (0.6.13) lib/rack/mount/route_set.rb:139:incall'
actionpack (3.0.3) lib/action_dispatch/routing/route_set.rb:492:in call' oa-core (0.1.6) lib/omniauth/strategy.rb:50:incall_app!'
oa-core (0.1.6) lib/omniauth/strategy.rb:32:in call!' oa-core (0.1.6) lib/omniauth/strategy.rb:19:incall'
oa-core (0.1.6) lib/omniauth/strategy.rb:50:in call_app!' oa-core (0.1.6) lib/omniauth/strategy.rb:32:incall!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in call' oa-core (0.1.6) lib/omniauth/strategy.rb:50:incall_app!'
oa-core (0.1.6) lib/omniauth/strategy.rb:32:in call!' oa-core (0.1.6) lib/omniauth/strategy.rb:19:incall'
oa-core (0.1.6) lib/omniauth/builder.rb:30:in call' haml (3.0.24) lib/sass/plugin/rack.rb:41:incall'
warden (0.10.7) lib/warden/manager.rb:35:in call' warden (0.10.7) lib/warden/manager.rb:34:incatch'
warden (0.10.7) lib/warden/manager.rb:34:in call' actionpack (3.0.3) lib/action_dispatch/middleware/best_standards_support.rb:17:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/head.rb:14:in call' rack (1.2.1) lib/rack/methodoverride.rb:24:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/params_parser.rb:21:in call' actionpack (3.0.3) lib/action_dispatch/middleware/flash.rb:182:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/session/abstract_store.rb:149:in call' actionpack (3.0.3) lib/action_dispatch/middleware/cookies.rb:295:incall'
activerecord (3.0.3) lib/active_record/query_cache.rb:32:in call' activerecord (3.0.3) lib/active_record/connection_adapters/abstract/query_cache.rb:28:incache'
activerecord (3.0.3) lib/active_record/query_cache.rb:12:in cache' activerecord (3.0.3) lib/active_record/query_cache.rb:31:incall'
activerecord (3.0.3) lib/active_record/connection_adapters/abstract/connection_pool.rb:353:in call' actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:46:incall'
activesupport (3.0.3) lib/active_support/callbacks.rb:415:in _run_call_callbacks' actionpack (3.0.3) lib/action_dispatch/middleware/callbacks.rb:44:incall'
rack (1.2.1) lib/rack/sendfile.rb:107:in call' actionpack (3.0.3) lib/action_dispatch/middleware/remote_ip.rb:48:incall'
actionpack (3.0.3) lib/action_dispatch/middleware/show_exceptions.rb:46:in call' railties (3.0.3) lib/rails/rack/logger.rb:13:incall'
rack (1.2.1) lib/rack/runtime.rb:17:in call' activesupport (3.0.3) lib/active_support/cache/strategy/local_cache.rb:72:incall'
rack (1.2.1) lib/rack/lock.rb:11:in call' rack (1.2.1) lib/rack/lock.rb:11:insynchronize'
rack (1.2.1) lib/rack/lock.rb:11:in call' actionpack (3.0.3) lib/action_dispatch/middleware/static.rb:30:incall'
railties (3.0.3) lib/rails/application.rb:168:in call' railties (3.0.3) lib/rails/application.rb:77:insend'
railties (3.0.3) lib/rails/application.rb:77:in method_missing' railties (3.0.3) lib/rails/rack/log_tailer.rb:14:incall'
rack (1.2.1) lib/rack/content_length.rb:13:in call' rack (1.2.1) lib/rack/chunked.rb:15:incall'
rack (1.2.1) lib/rack/handler/mongrel.rb:67:in process' mongrel (1.2.0.pre2) lib/mongrel.rb:165:inprocess_client'
mongrel (1.2.0.pre2) lib/mongrel.rb:164:in each' mongrel (1.2.0.pre2) lib/mongrel.rb:164:inprocess_client'
mongrel (1.2.0.pre2) lib/mongrel.rb:291:in run' mongrel (1.2.0.pre2) lib/mongrel.rb:291:ininitialize'
mongrel (1.2.0.pre2) lib/mongrel.rb:291:in new' mongrel (1.2.0.pre2) lib/mongrel.rb:291:inrun'
mongrel (1.2.0.pre2) lib/mongrel.rb:274:in initialize' mongrel (1.2.0.pre2) lib/mongrel.rb:274:innew'
mongrel (1.2.0.pre2) lib/mongrel.rb:274:in run' rack (1.2.1) lib/rack/handler/mongrel.rb:38:inrun'
rack (1.2.1) lib/rack/server.rb:213:in start' railties (3.0.3) lib/rails/commands/server.rb:65:instart'
railties (3.0.3) lib/rails/commands.rb:30
railties (3.0.3) lib/rails/commands.rb:27:in tap' railties (3.0.3) lib/rails/commands.rb:27 script/rails:6:inrequire'
script/rails:6

Rendered /home/mark/.rvm/gems/ruby-1.9.2-p136/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_trace.erb (1.8ms)
SQL (1.0ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.8ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
Category Load (4.0ms) SELECT "categories".* FROM "categories" ORDER BY position
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (3.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.3ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.6ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.5ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'

SQL (0.4ms) SELECT name
FROM sqlite_master
WHERE type = 'table' AND NOT name = 'sqlite_sequence'
Rendered /home/mark/.rvm/gems/ruby-1.9.2-p136/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (2353.7ms)
Rendered /home/mark/.rvm/gems/ruby-1.9.2-p136/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/template_error.erb within rescues/layout (2380.5ms)

@vhochstein
Copy link
Owner

Because you are using haml can you please take a look at:
https://github.com/vhochstein/active_scaffold/issues/closed#issue/55

If that does nt help.
Next Action, can you please create a github repository with your example app?
all your gems should be moved to vendor dir by bundler command.
That would empower me to take a closer look and try it out on my computer

@markmcdonald51
Copy link
Author

Thanks vhochstein.

I got this to work. Thanks so much for the speedy reply.

Mark

@vhochstein
Copy link
Owner

Well, round about a month to solve this issue ... I would nt call that speedy, but I am really glad that we finally found a solution.

@greggersh
Copy link

Can you detail the solution that you found to this problem? The link to the closed issue above is not working, and I'm experiencing the same problem

@vhochstein
Copy link
Owner

github changed their issue links:
vhochstein/active_scaffold#55

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants