Dynamic scaffold not working


I created a model called “player” using rake db:migration and right
went to try a dynamic scaffold to try it.
So I created a controller called “admin” and the admin_controller.rb
like this:

class AdminController < ApplicationController
scaffold :player

but when I tried http://localhost:3000/admin/, I got this error message:

uninitialized constant Player

Then I created the scaffold statically by doing script\generate scaffold

Now, I can try to access the admin controller and everything goes nice.

I tried to destroy the static scaffold, but then the error came back.

I’m using Ruby on Rails on Windows XP, using Mongrel as server. Is there
configuration I should set to make the dynamic scaffold work? I’m
the RoR book steps, and there’s nothing about this error there.

Thanks in advance

Felipe Sodre S. Silva
Engenharia de Computação - Universidade Estadual de Campinas
+55 11 9604-1118
[email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs