Forum: Ruby on Rails newbie scaffold question

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.
Gaudi M. (Guest)
on 2006-03-03 02:21
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
Jeremy E. (Guest)
on 2006-03-03 02:39
(Received via mailing list)
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/Scaffoldin...
Gaudi M. (Guest)
on 2006-03-03 04:53
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/Scaffoldin...
This topic is locked and can not be replied to.