Newbie scaffold question


#1

I’ve got a database with several tables. I’d like to create scaffolding
for separate CRUD interfaces for several of these tables. I’m hoping
that the scaffold generator can create the CRUD code for all these
tables in ONE controller, but I don’t know how to tell it to do that, if
it can.

Can anyone verify if this is possible?

Thanks,
David


#2

On 3/2/06, Gaudi Mi removed_email_address@domain.invalid wrote:

I’ve got a database with several tables. I’d like to create scaffolding
for separate CRUD interfaces for several of these tables. I’m hoping
that the scaffold generator can create the CRUD code for all these
tables in ONE controller, but I don’t know how to tell it to do that, if
it can.

Can anyone verify if this is possible?

I’m not sure if you can do it with the generator (I don’t think so),
but you can use the scaffold method with the :suffix option if you
don’t need to modify the dynamically generated scaffold. BTW, you
might want to look into the Scaffolding Extensions plugin [1].

[1]
http://wiki.rubyonrails.com/rails/pages/Scaffolding+Extensions+Plugin


#3

Thanks, Jeremy. I didn’t know about the scaffold method. Very helpful.
I imagine I’ll dump scaffolding later on, but it sure helps in the
learning curve days.

Jeremy E. wrote:

On 3/2/06, Gaudi Mi removed_email_address@domain.invalid wrote:

I’ve got a database with several tables. I’d like to create scaffolding
for separate CRUD interfaces for several of these tables. I’m hoping
that the scaffold generator can create the CRUD code for all these
tables in ONE controller, but I don’t know how to tell it to do that, if
it can.

Can anyone verify if this is possible?

I’m not sure if you can do it with the generator (I don’t think so),
but you can use the scaffold method with the :suffix option if you
don’t need to modify the dynamically generated scaffold. BTW, you
might want to look into the Scaffolding Extensions plugin [1].

[1]
http://wiki.rubyonrails.com/rails/pages/Scaffolding+Extensions+Plugin