Apologies for simple question. I am getting the error... undefined method `of' for Task:Class
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.14.4/lib/active_record/base.rb:1129:in `method_missing' #{RAILS_ROOT}/app/models/task.rb:4 #{RAILS_ROOT}/app/controllers/tasks_controller.rb:12:in `list'
This error occured while loading the following files: task.rb
I cannot see this error mentioned in the mailing list and googling for it fails too.
I have a simple model type... class Task < ActiveRecord::Base validates_presence of :name end
defined in the file task.rb and a database table 'tasks' and a scaffolding generated controller called 'tasks_controller.rb'. The index method of the controller has...
def list @task_pages, @tasks = paginate :tasks, :per_page => 10 end
Thanks for any help/thoughts, Stuart.