Forum: Ruby on Rails Weird problem related I am having with scaffold

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Bc2d744317a91399791e5800bdaf873f?d=identicon&s=25 Raine Virta (rane)
on 2006-06-12 19:42
i,

I have this in expense_controller.rb:

class ExpenseController < ApplicationController
  scaffold :expense
end

It works fine, but let's say I want to override scaffold's list.
For some reason, just making list.rhtml in views\expense is enough, and
there's no need to add

def list
end

in expense_controller.rb. However, that's not my real problem.

Now when I have this custom list action, and I want remove it, just
removing the list.rhtml won't do it. Now there's blank page, so
obviously it's still using the list.rhtml although it can't find it.
Only way to resume scaffold's list is to restart Mongrel.

I am quite sure that this can't be normal. Any ideas?

ps. I have the same problem with Instant Rails WEBrick.
Bc2d744317a91399791e5800bdaf873f?d=identicon&s=25 Raine Virta (rane)
on 2006-06-12 19:43
Please don't mind that small typo in the subject :)
2b891e820c238ded365d035771603f21?d=identicon&s=25 Bill Walton (Guest)
on 2006-06-12 20:32
(Received via mailing list)
Raine Virta wrote:

> I have this in expense_controller.rb:
>
> class ExpenseController < ApplicationController
>  scaffold :expense
> end

I personally recommend against newbies using the inline scaffolding.
It's
handy in the hands of folks who understand what RoR is doing behind the
scenes but is/was, for me, too damn magical for folks trying to learn
the
basics.  Instead, I recommend you use ruby script\generate Model_name
Controller_name.  All will be revealed and the problem you're having
will go
away.

hth,
Bill
29237231571cf4eefd412948688386da?d=identicon&s=25 Guest (Guest)
on 2006-06-13 02:51
Curt does an excellent job at jump starting Ruby with Rails.
Please refer to:
http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html

Also, if you refer the the bottom part of the last page, you will
encounter others who have had similar problems getting started.
This topic is locked and can not be replied to.