Riding The Breeze

Jump to content

Additional information

Categories


Commands

Feb 2006
24

Module name Friend | Table name friends

Create the module

./script/generate controller Friends [list view new edit]

creates

apps/controllers/friends_controller.rb

apps/helpers/friends_helper.rb

if you specify any actions you will also get

app/view/friends/action.rhtml

To generate the model

./script/generate model Friend

If you wanna use the scaffold for this module just open

apps/controllers/friends_controller.rb

and modify it to

class FriendsController < ApplicationController
scaffold :friend
end

For a short and fast explanation about names in RoR have a look to Rails Tip Sheet


Comments are closed.

Credits

Template designed by praegnanz.de.